[GPIO] is it possible to map combination Hotkey button into single button?
-
first of all sorry for my english
I'm building an arcade bartop with PI3 Recalbox
is it possible to map combination Hotkey button into single button? (mainly use for MAME , Neo-Geo)
i've read some others topics and i don't really understand much
im also a total noob for command line stuff
for example , my thought is
I'll drop P2 Select button (no need for P2 insert coins)
then i will have spare button for somthing else
here is the plans i madeis it possible ?
thanks in advance
i'm really appreciate -
in fact, no. BUT : we can map a gpio to a special python script if needed. I just hope it's still compatible with the gpio driver
And BTW, your buttons layout should be :
Y X TL
B A TR -
Don't know if it's possible, but maybe directly in hardware mode ?
If you wire HK GPIO+START GPIO on the same buton... Will it work to quit game ?
I think you can, at least, try this... (not too hard to test and zero python script )
-
@screech well, that's risky, be cause other HK combos will never work. But could be done is SELECT is the HK and the QUIT button is wired to both SELECT and START.
And one more question : what is the RESET button supposed to do ? Reset the game or reset the pi ? If you want to reset the game, it's the HK+A comboAgain : scripting it would be a lot better, in my opinion
-
@subs said in [GPIO] is it possible to map combination Hotkey button into single button?:
@screech well, that's risky, be cause other HK combos will never work. But could be done is SELECT is the HK and the QUIT button is wired to both SELECT and START.
And one more question : what is the RESET button supposed to do ? Reset the game or reset the pi ? If you want to reset the game, it's the HK+A comboAgain : scripting it would be a lot better, in my opinion
reset game . but still i just can't think of any other HK + button that more important
if so can you point me the the guide if i want to learn how to use python script
thank you -
@subs don't you think this wirring can't work ?
-
@Tick-Lpsk see :
https://forum.recalbox.com/topic/3504/emulator-exit-button-gpio/11
https://forum.recalbox.com/topic/3435/game-reset/10
That's some wip, i can help you for a better integration in recalbox@screech It would work. But can't use the quit/reset/screenshot buttons as hotkeys by themselves and use other combos like load/save state, rewind, shaders etc ...
-
@Tick-Lpsk please keep us informed
-
first, i don't know why GPIO doesn't recognize hotkey
others button work perfect
anyways i found out that i have to use Select button as Hotkey button (Like Select+Start = quit)
then i've tried screech idea.
i hot wire select > quit button < start
the button act weird . it's seem that you can't do it that way
So. i think the best way is to do a python script as @subs said
but i have limited knowledge to understand complicated codes stuff
would you kindly tell me how to do it step-by-step
Thank You -
I have the Same Problem. Is it not possible to add this Exit Button Option to Future Recalbox releases. Would be great for all Cabinet Builders. Maybe just a line in the config.
-
Why don't you guys just go for one more button in the front? Like I did. I know it does not help the script problem, but the usability is great and it's very easy to achieve.
-
Of course its not a big deal and all my Cabinet have a HK Button but an Exit Button would be a Nice thing to have in future releases.
-
@Nachtgarm i wonder why there are condoms on your sticks ... Dude, you sure you're doing fine ?
Concerning the topic : a button can not have different "functions : it can't be HK +something else. So the only way is the python way.
Find your available gpios (i hope you do have some free ones ... If you're susing the gpio driver for your sticks, then we're stuck). From there, we should be able to write down the python and tell you how and where to run it. @supernature2k my dear python + gpio guru, time to show yoyr skills and think about a nice implementation of what we've been working lately for 4.1
-
@subs sure bro, just tell me how you picture it.
Here is my proposal:
new option in recalbox.conf
gpio.emulatorbutton.quit=3
;gpio.emulatorbutton.reset=5problem: it works very well with retroarch but what about the standalones emus?
-
@supernature2k i rather think about a conf file + a script that would read it. Options should look like in recalbox.conf like "gpyio.pinnumber=state, action" (the gpYio is voluntary haha but name it the way you want)
state = pull, push, any handled state
action : a set of defined actions (we know how to kill an emulator, as well as run some retroarch commands)Explain how to start this script in S99custom
See the picture ?
For other emulators, it's not possible, but just quit them. Too bad, gotta move forward. I'm not sure setting all this in the recalbox.conf is a good idea because it may look really messy someday, and that's an option people may not often use. Gotta ask @digitaLumberjack
-
im excited !
-
@subs These are not my sticks. It was a cabinet I sold to a customer and therefore I kept the handles untouched and shiny
-
@Nachtgarm yeah yeah ... you pervert ... lol
-
@subs You have NO idea 3:-)