firmware discussion

https://github.com/mist-devel/mist-board/wiki

Moderators: Mug UK, Zorro 2, Greenious, spiny, Moderator Team

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

firmware discussion

Postby Newsdee » Tue Jun 14, 2016 7:54 am

I'm creating a new thread so we keep the sticky for version changes only.

Sorgelig wrote:Auto-fire is obviously for fire buttons ;)
I don't remember where, but i've read there is auto-file on/off button for emulation through keypad buttons. So, i've thought about similar auto-fire for emulation on reduced keyboards.


To be honest I never got the joystick emulation working on any keyboard. What are the firr buttons? I thought it was ctrl, alt, shift, etc. In which case the autofire should work for both numpad and arrow modes, no?

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Tue Jun 14, 2016 8:00 am

kolla wrote:

Oh, sorry for not specifying, I mean modify to another key.

I have brought this up earlier at some point - most current keyboards do not have any "right GUI key", and only come with "left GUI key" (a windows key) and "menu". For using Amiga OS, both GUI keys are important, and with the menu key typically being located where "right GUI key" normally is, and "locked" to bring up the OSD menu, there is no way to access "right Amiga key". It would be of great help if one could easily map the "menu" key to send "right GUI key".

Personally, I want to mimic the Amiga keyboard layout as much as possible, meaning I want to remap in a way so that:

CapsLock becomes Ctrl
LeftGUI becomes LeftAlt
LeftAlt becomes LeftGUI
RightAlt becomes RightGUI
Menu becomes RightAlt

(an earlier core did help a bit by swapping GUI and Alt keys, I believe it was you who did it?)


Yes, I remember. I have some commented-out code for that which wasn't finished. I'll have another look when I can, maybe we can just do an "amiga layout" option at first (INI flag).

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Tue Jun 14, 2016 2:04 pm

Joystick/Mouse emulation on reduced keyboards:
first press ScrLock: Mouse emulation
second press ScrLock: Joystick 1 emulation
third press ScrLock: Joystick 2 emulation
fourth press ScrLock: disable any emulation

Keys used for emulation: 4 cursor keys, Left Ctrl, Left Shift.

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Tue Jun 14, 2016 2:10 pm

Auto-fire option would be good. But need to take into account following: Some games use Ctrl as a fire, others use Shift. Speed of autofire should be adjustable. If it too fast then game will stop register quick presses (will work as a hold), if too slow, then autofire will be useless because manual quick presses will work better.

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Tue Jun 14, 2016 2:19 pm

I think Amiga core issues should be addressed to Amiga core developer (on github). He is pretty active and can handle both core and FW code. When Amiga core is russing, the FW uses other OSD and many other FW things available to Amiga-only. Even keyboard scancodes are different when Amiga core is running.
Here is discussion mostly for 8bit cores which handled by common code in FW, i think...

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Tue Jun 14, 2016 4:30 pm

@kolla, try this, added an option "key_menu_as_rgui=1" to mist.ini.
For now it only works on the amiga core; I've tried to add it to the 8-bit one but it doesn't work yet.
mist-firmware.zip


On Workbench using Menu key + E pops up the "Execute" window, so seems to work.
You do not have the required permissions to view the files attached to this post.

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Tue Jun 14, 2016 4:32 pm

Sorgelig wrote:Joystick/Mouse emulation on reduced keyboards:
first press ScrLock: Mouse emulation
second press ScrLock: Joystick 1 emulation
third press ScrLock: Joystick 2 emulation
fourth press ScrLock: disable any emulation

Keys used for emulation: 4 cursor keys, Left Ctrl, Left Shift.


I tried this on three keyboards... and none worked; tried with both cursor keys and numeric keypad.
(tried both the joystick tester and using keys ingame with the NES core).

Keyboard LED are cycling so at least something is happening, but none of the settings seem to emulate the joystick.

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Tue Jun 14, 2016 4:47 pm

Newsdee wrote:I tried this on three keyboards... and none worked; tried with both cursor keys and numeric keypad.
(tried both the joystick tester and using keys ingame with the NES core).

Keyboard LED are cycling so at least something is happening, but none of the settings seem to emulate the joystick.

Which cores you've tried?
All my cores are working fine with these emulations. I will tell you more: i don't have any joysticks. Everything related to joystick i'me testing only on this emulation.
I'm using wireless keyboard Logitech K400r (the best keyboard for MiST, IMHO). May be try other keyboard? It looks weird...

kolla
Captain Atari
Captain Atari
Posts: 194
Joined: Thu Sep 17, 2015 11:39 pm
Contact:

Re: firmware discussion

Postby kolla » Tue Jun 14, 2016 8:25 pm

Newsdee wrote:@kolla, try this, added an option "key_menu_as_rgui=1" to mist.ini.
For now it only works on the amiga core; I've tried to add it to the 8-bit one but it doesn't work yet.

On Workbench using Menu key + E pops up the "Execute" window, so seems to work.


Oh wow, fast respons :) I am on a small trip right now, but will try once I get back home next week.
-- kolla

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Wed Jun 15, 2016 6:02 am

Sorgelig wrote:Which cores you've tried?
All my cores are working fine with these emulations. I will tell you more: i don't have any joysticks. Everything related to joystick i'me testing only on this emulation.
I'm using wireless keyboard Logitech K400r (the best keyboard for MiST, IMHO). May be try other keyboard? It looks weird...


I didn't try your cores but it should work with any 8-bit core, unless you are doing something special. :)

My favorite keyboard for the MiST is the Rapoo 8000 which is very small and light. I also tried with a Filco Majestouch2 (full keyboard) and a Leopold FC660 (mini keyboard). Neither of the three keyboards worked.

As it happens I also have a K400r in the house. I'll give it a try.

That said, in general, aren't you just after autofire for joystick buttons sent to the core? I'm thinking that could be done centrally. Or is there something already implemented?

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Wed Jun 15, 2016 7:30 am

Since i know my cores better than other's i suggest to try them. That's simple :) Try this emulation in my ZX core.
Autofire can be implemented in core, but it will require implementation in every core, which is not so practical.
This is one of thing is better to be implemented in FW.
Actually, it can be applied to real joysticks as well.

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Wed Jun 15, 2016 11:03 am

Sorgelig wrote:Actually, it can be applied to real joysticks as well.


Yes this is what I meant. Basically we want the features of the NES advantage joystick :)

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Sun Jun 19, 2016 4:49 am

Sorgelig wrote: If it too fast then game will stop register quick presses (will work as a hold), if too slow, then autofire will be useless because manual quick presses will work better.


I've made some preliminary changes to support autofire in general; but I'm having trouble to have the cores recognize it (OSD seems to work fine). Can you give it a try with one of your cores?

(edit: see post below)
Last edited by Newsdee on Sun Jun 19, 2016 7:10 am, edited 2 times in total.

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Sun Jun 19, 2016 6:53 am

I think I've got it. While I get the UI done for it, please try it by changing these settings in hid.c for now:

Code: Select all

   .turbo=50,
   .turbo_mask=0x30,    // A and B buttons   


Note that the mask has 4 bits in the LSB side that are for directions. Autofire should work for these as well as start/select. Not sure if useful but I prefer to code handling for the entire byte to keep things flexible. :)

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Sun Jun 19, 2016 4:44 pm

New firmware released (replacing previous 20160619 binary). The turbo function should work with any joystick connected.

kolla
Captain Atari
Captain Atari
Posts: 194
Joined: Thu Sep 17, 2015 11:39 pm
Contact:

Re: firmware discussion

Postby kolla » Mon Jun 20, 2016 11:42 pm

kolla wrote:
Newsdee wrote:@kolla, try this, added an option "key_menu_as_rgui=1" to mist.ini.
For now it only works on the amiga core; I've tried to add it to the 8-bit one but it doesn't work yet.

On Workbench using Menu key + E pops up the "Execute" window, so seems to work.


Oh wow, fast respons :) I am on a small trip right now, but will try once I get back home next week.


Yes, now tested and it works - excellent!!!

Thanks a billion, finally I can cut, copy, paste etc :)
-- kolla

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Fri Jun 24, 2016 9:51 am

I've pushed the commit with feature i was waited for a long time - more than 2 values for O option.

How it's done:
- FW now uses 32bit for OSD status. 8bit truncated value is also transmitting for backward compatibility. user_io.v in the core need to be updated to support receiving of 32bit status.
- O option can have 2 indexes (old version with single index is supported as well), like
O23,Option,val1,val2,val3;
It means bits 2..3 (status[3:2]) are used for this option. The number of values not required to be matched to number of all possible values. Like in example, we have 3 values only. So, every press on this option will switch between only these 3 values in sequential way: val1 -> val2 -> val3 -> val1 -> ...
- Index number expanded to 31 possible values. Following "numbers" are possible: 0-9,A-V. i.e: OKM means status[22:20].
- There is no limitation how many bits are used in O option. You may have like 8 values for single option. The only limitation is total amount of bits for OSD options: 32.
Last edited by Sorgelig on Fri Jun 24, 2016 10:09 am, edited 2 times in total.

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Fri Jun 24, 2016 9:53 am

I think the first core using this feature will be Spectrum. I will release it soon.

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Fri Jun 24, 2016 10:01 am

There is one consequence raised now: With many values is better to be able to switch both ways (up and down). So, it would be good to reserve keys left/right for this purpose. But these keys are already used for page switch.
So... need to think how to make navigation easier.

Another thing we need to think: increase amount of options and how it can be organized. It can be split to several pages. But i personally would like to have scroll. This will be more flexible in how many options you want to add.

User avatar
mambrino
Atari freak
Atari freak
Posts: 56
Joined: Mon May 09, 2016 4:59 pm

Re: firmware discussion

Postby mambrino » Sun Jun 26, 2016 10:58 am

Sorgelig wrote:Joystick/Mouse emulation on reduced keyboards:
first press ScrLock: Mouse emulation
second press ScrLock: Joystick 1 emulation
third press ScrLock: Joystick 2 emulation
fourth press ScrLock: disable any emulation

Keys used for emulation: 4 cursor keys, Left Ctrl, Left Shift.


Joystick emulation in 160613 firmware version works perfectly for me, but after 160616 changes (maybe code refactoring?) it stop working for Amiga core. Leds don't cycle and no joystick response.

Sorgelig wrote:There is one consequence raised now: With many values is better to be able to switch both ways (up and down). So, it would be good to reserve keys left/right for this purpose. But these keys are already used for page switch.
So... need to think how to make navigation easier.

One option would be to use PgUp and PgDown for page switching and reserve left/right for switching both ways.

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Sun Jun 26, 2016 3:29 pm

Committed a new firmware that should fix the Amiga core incompatibility issues.
(I've had to disable a couple of features to get it stable - Turbo and PS2 keyboard display will be added back later on)

kolla
Captain Atari
Captain Atari
Posts: 194
Joined: Thu Sep 17, 2015 11:39 pm
Contact:

Re: firmware discussion

Postby kolla » Wed Jun 29, 2016 1:45 pm

@Newsdee

Could you add link to firmwares in your signature or something?

Every time you have an update, I find myself searching for the darn firmware updates, their location is sadly not obvious :)
Even https://github.com/mist-devel/mist-boar ... heFirmware does not really say _where_ to get firmwares from, at last I cannot see it.
-- kolla

Sorgelig
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 4693
Joined: Mon Dec 14, 2015 10:51 am
Location: Russia/Taiwan

Re: firmware discussion

Postby Sorgelig » Wed Jun 29, 2016 2:27 pm

I've added link on the top of that page.

User avatar
Newsdee
Atari God
Atari God
Posts: 1406
Joined: Fri Sep 19, 2014 8:40 am

Re: firmware discussion

Postby Newsdee » Wed Jun 29, 2016 3:15 pm

That's a great idea. It was time for me to update my sig anyway :)

kolla
Captain Atari
Captain Atari
Posts: 194
Joined: Thu Sep 17, 2015 11:39 pm
Contact:

Re: firmware discussion

Postby kolla » Wed Jun 29, 2016 10:37 pm

Thank you very much, both of you! :D
-- kolla


Return to “MiST”

Who is online

Users browsing this forum: No registered users and 3 guests