Forum Replies Created
-
AuthorPosts
-
tombofixParticipant
You beat me to it Floob… What Floob said!
04/22/2015 at 23:15 in reply to: Simple 1 button GPIO on off switch: 1 switch, 2 wires, 10 lines of code #95928tombofixParticipantAmazing! Fitted with an old reset switch off a PC as they fit perfectly across the pins on a Pi 2.
Things to note:
Make sure your quote marks are the quote marks generated by nano. If you copy and paste the code your quotes and apostrophes will be incorrect and the script won’t run. It’ll typically result in an error about the directory not existing. If they look like they have curls then they aren’t correct.rc.local should be
sudo sh /home/pi/scripts/shutdown.sh
I also found that I needed to install the GPIO components on my build before they worked.
sudo apt-get update sudo apt-get remove python-rpi.gpio python3-rpi.gpio
Mine now works beautifully, can’t thank you enough as feel it is ready to be fitted in to a console!
tombofixParticipantCheck out my post (https://www.petrockblock.com/forums/topic/usb-snes-controller-d-pad-not-working-in-games/).
If you are using Version 3 Beta 2 I am starting to think there might be a problem with the autoconfig files.
My fix was as follows:
1 – Backup all files under config
2 – Delete them all
3 – Reconfigure each joypad using RetroPie Setup script and Joystick setupMy original issue was also fixed by using Floobs retroarch config as my spacing had got changed. As long as you haven’t edited that file then I would try what I said above.
tombofixParticipantHi All,
Thanks again to Floob who resolved my issue, as it turned out in this instance my retroarch.cfg had some spacing issues that resulted in this issue.
However…
I recreated the entire system over this weekend as I was unhappy with the card I was using, only to be confronted by exactly the same issue again (this time without me making any configuration changes). To fix it though I deleted all the automatically created config files and let it create a new one. This time it worked perfectly with my SNES controllers working without the need to go near the retroarch.cfg file.
Many thanks to all that helped, it really was appreciated!
Tombofix
————————–
Why not check out my blog?
The most popular post is about Floppy Disks:
http://www.roughing-it.net/?p=56tombofixParticipantNo need, since I re-did the tetrarch.cfg with your version and the joystick config completed the controller now works! Hallelujah! Floor, if I could buy you a pint right now I would! Thank you!!
tombofixParticipantInteresting.. Direction now works but the buttons don’t! Just reconfiguring using Joystick Setup
tombofixParticipantJust recreated it, rebooting now and will let you know. Can I have you USB gamepad file to test too?
tombofixParticipantPastebin: http://pastebin.com/aJ5GbN19
It happens on all emulators that I’ve tried (NES, SNES, MegaDrive, MasterSystem, Game Boy).
tombofixParticipantYes, the yellow text appears with the same amount of space following the end. I tried removing the spaces but then it doesn’t appear as an auto-configure.
Just performed an interesting test:
I deleted the config file, re-created using the setup file but this time I set my A, B, X and Y buttons as the D-PAD whilst using the A, B, X and Y buttons as Up, Down, Left, Right. Guess what happens?
A, B, X and Y buttons remain as action buttons exactly as they always did (shoot, jump etc) whilst the D-Pad mirrors the A, B, X and Y buttons also.
The config file changed to include the input_up_btn etc
tombofixParticipantI take it there is no need for me to put in the btn code h0up etc?
tombofixParticipantNothing has changed in the tetrarch.cfg file to my knowledge.
I’ve just realised that the -32767 was put in by me when the -1 etc wasn’t working. I’ve deleted the config file again and recreated it so it now shows 1 rather than 32767.
The result.
Still no D-Pad!
tombofixParticipantExcept .cfg not being permitted on here! See attached .txt file.
tombofixParticipantHi Floob, thanks for the response! I’d love to get the auto-enable working. I just dug out my last Pi but the image is corrupt so I can’t test the controller on 2.6 or below yet.
Attached to this is the cfg (without having been opened to preserve it) downloaded via FileZilla. Fingers crossed it might give you an idea.
tombofixParticipantherbfargus:
I did look at the autoenable feature but I do use a multitude of controllers based on the emulator I’m playing on. Is there a way to specify specific controllers when they are plugged in based on the RetroArch.cfg file?Floob:
I have re-run it several times, even with all the config files deleted so it recreated a fresh version. The content is listed below:input_device = “USB gamepad ”
input_driver = “udev”
input_b_btn = “2”
input_y_btn = “3”
input_select_btn = “8”
input_start_btn = “9”
input_up_axis = “-1”
input_down_axis = “+1”
input_left_axis = “-0”
input_right_axis = “+0”
input_a_btn = “1”
input_x_btn = “0”
input_l_btn = “4”
input_r_btn = “5”
input_enable_hotkey_btn = “8”
input_exit_emulator_btn = “9”
input_menu_toggle_btn = “0”
input_load_state_btn = “4”
input_save_state_btn = “5”
input_reset_btn = “2”
input_state_slot_increase_axis = “+0”
input_state_slot_decrease_axis = “-0” -
AuthorPosts