I already posted the query in my game jounral post, but I had the thought of potentially linking some Robotic script to an external device to produce some cool effects, like haptic feedback or a custom controller for puzzle games.
I imagine it's not something that's implemented, but you don't know unless you ask, right?
Page 1 of 1
Interface GPIO pins on RPI? Can you use the GPIO pins in any way?
#2
Posted 29 October 2019 - 11:42 PM
MegaZeux generally doesn't expose any platform-specific features like this to MZX games and that probably isn't changing. SDL 2 has a built-in haptic library, so there's a (very slim) chance that particular example might be doable sometime in the future if MZX ends up supporting it and SDL supports whatever the Raspberry Pi uses for haptic feedback. Don't count on it being soon (if at all), though.
If you make the custom controller an HID-compliant USB/Bluetooth/etc. device that might be enough to get SDL to detect it, in which case you can set up a game controller mapping for it. I don't know what the specifics are for getting SDL to detect a controller in Linux.
Typically what MZXers end up doing for these sorts of extensions is communicating with an external program via file access. If you want to do this, that's probably how you'll have to go about it.
If you make the custom controller an HID-compliant USB/Bluetooth/etc. device that might be enough to get SDL to detect it, in which case you can set up a game controller mapping for it. I don't know what the specifics are for getting SDL to detect a controller in Linux.
Typically what MZXers end up doing for these sorts of extensions is communicating with an external program via file access. If you want to do this, that's probably how you'll have to go about it.
"Let's just say I'm a GOOD hacker, AND virus maker. I'm sure you wouldn't like to pay for another PC would you?"
xx̊y (OST) - HELLQUEST (OST) - Zeux I: Labyrinth of Zeux (OST) (DOS OST)
w/ Lancer-X and/or asgromo: Pandora's Gate - Thanatos Insignia - no True(n) - For Elise OST
MegaZeux: Online Help File - Keycode Guide - Joystick Guide - Official GIT Repository
xx̊y (OST) - HELLQUEST (OST) - Zeux I: Labyrinth of Zeux (OST) (DOS OST)
w/ Lancer-X and/or asgromo: Pandora's Gate - Thanatos Insignia - no True(n) - For Elise OST
MegaZeux: Online Help File - Keycode Guide - Joystick Guide - Official GIT Repository
#3
Posted 30 October 2019 - 02:45 AM
Lachesis, on 30 October 2019 - 09:42 AM, said:
Typically what MZXers end up doing for these sorts of extensions is communicating with an external program via file access. If you want to do this, that's probably how you'll have to go about it.
Linux typically exposes gpio through the filesystem, but MegaZeux's path protection won't let you write to it directly. What you could do is set up a symlink in your game's directory pointing at one of those gpio files, make sure the permissions are all good, then have your game write to that.
<Malwyn> Yes, yes. Don't worry I'd rather masturbate with broken glass than ask you for help again. :(
#4
Posted 30 October 2019 - 01:11 PM
Dr Lancer-X, on 29 October 2019 - 09:45 PM, said:
Linux typically exposes gpio through the filesystem, but MegaZeux's path protection won't let you write to it directly. What you could do is set up a symlink in your game's directory pointing at one of those gpio files, make sure the permissions are all good, then have your game write to that.
Whoa, alright. I'll have to figure out all the intermediate steps, but thanks a ton for that!
#5
Posted 30 October 2019 - 01:14 PM
Lachesis, on 29 October 2019 - 06:42 PM, said:
MegaZeux generally doesn't expose any platform-specific features like this to MZX games and that probably isn't changing. SDL 2 has a built-in haptic library, so there's a (very slim) chance that particular example might be doable sometime in the future if MZX ends up supporting it and SDL supports whatever the Raspberry Pi uses for haptic feedback. Don't count on it being soon (if at all), though.
If you make the custom controller an HID-compliant USB/Bluetooth/etc. device that might be enough to get SDL to detect it, in which case you can set up a game controller mapping for it. I don't know what the specifics are for getting SDL to detect a controller in Linux.
Typically what MZXers end up doing for these sorts of extensions is communicating with an external program via file access. If you want to do this, that's probably how you'll have to go about it.
If you make the custom controller an HID-compliant USB/Bluetooth/etc. device that might be enough to get SDL to detect it, in which case you can set up a game controller mapping for it. I don't know what the specifics are for getting SDL to detect a controller in Linux.
Typically what MZXers end up doing for these sorts of extensions is communicating with an external program via file access. If you want to do this, that's probably how you'll have to go about it.
And thank you as well
Share this topic:
Page 1 of 1