Hi there, i’ve build up my project with using raspberry pi2, thanks to retropie.. now i am playing mame games with no problem with my ps3 controller (still designing a custom joystick-button front panel). My coin acceptor is working fine, but i am planning to add a relay-based hardware for accepting coin when a game is started from emulator. Otherwise, coin will be wasted if i use my coin in emulation station. I want to use my coin acceptor closed on default and when a game is started, i would like to trigger a relay and make it on open position.
I would like to ask you, is there any way to trigger a relay when a game is started from emulation station ?
you can adjust /opt/retropie/supplementary/runcommand.sh which is used to launch the emulators and handle some configuration to trigger another script before launching (which would control your relay via gpio
Hi I am working on setting up coin acceptor as well. You said you had it working on the RetroPie, I basically want to set it up as the coin button. Is that simply done through an IO port, or do I need an IPAC?
You could go about this another way. The coin is a button press or keystroke. A script can be written (likely) that will capture the key stroke regardless of the system running or just the front end and increase the count by 1. If 4 coins are inserted the count will be 4
Then each time you press start the button count would count down 4,3,2,1 etc.
Then the script could listen for running processes ex. Mame.exe or pifba.exe etc. this way if the process isn’t running and a user presses start it won’t decrease the counter.
In theory this would make emulated games like snes pay per play too as a user couldn’t send a start button unless coins were inserted.
I have wrote similar scripts in autohotkey for Windows and Mame but don’t have any real experience with Linux.
I’d like to see this happen, but people are very passionate about people charging for mame etc so your mileage may vary