sebt3
homebrew player (P. & C.)
The physical hardware are several separed devices :I don't understand what I see here. I just heard the word funkey monkey a thousand times in the forums but I totally ignore its purpose.
- left nub is one joystick (having no buttons, no giro, no rumble, only 2 analog axis)
- right nub is an other distinct joystick
- the gaming buttons (shoulders, d-pad... everything around the d-pad) form a keyboard
- the letters keys (including [fn]) is also a keyboard
- the rumble pack is yet an other joysick, with no button nor axis
funkeymonkey with its pyrainput plugin grab and merge all these physical devices to create 3 virtual device, the OS use in the end :
- a full featured keyboard
- a mouse
- a full featured joystick
yes and no...Is the layout hardcoded in this funkey monkey and can only be changed at compilation time?
You have to understand how keyboard and key-mapping work. Physically the key just next to the tab key on a french keyboard (a) and a german (q) both produce the same "opcode". It's the keyboad mapping that makes it either an "a" or a "q".
The keyboard pyra-input provide "opcodes" for each keypress (or [fn] combo).
So yes the opcode are completly hardcoded, but the mapping is still configurable at will... just like with a regular keyboard.
For most keys, pyra-input is just a passthrow to limit induced latency to the bare minimum, but since [fn] is a key and not a special modifier like it is on laptop keyboard, pyra-input simulate this behaviour.
And for most key, the combinaison [fn]+key is either drawn on the keyboard or documented on the boards somewhere. so these combinaison produce the op-code related to these keys. But some are not. For these I had to get creative because all the pyra keys + all the possible [fn]+key produce way over 104 keys a normal keyboard produce. Hence [fn]+[e] will produce the op-code for the [setup] key some multimedia keyboard do provide, or [fn]+[r] will generate the opcode for [delete-fle] some weird keyboard do have. and so on. Now that you know how to read that block of code, get back to it, it will looks way clearer
I was suggesting to remap these special corner case for your needs : no features lost and you get the glyph (what is drawn on screen, aka opcode+mapping) you want