Can't enter runcommand by pressing a button.
-
@Dochartaigh said in Can't enter runcommand by pressing a button.:
@meleu said in Can't enter runcommand by pressing a button.:
But I think you don't have to touch any of these files to solve your issue.
What should I do to solve this issue then?
Discover which button is the button 0 and press that button.
-
Hmm it is my launching images. They won't let me press A on the joystick when launching?!?
-
@Dominus said in Can't enter runcommand by pressing a button.:
Hmm it is my launching images. They won't let me press A on the joystick when launching?!?
after the image is gone you have two seconds to press the button 0. Pressing the button while the image is being shown takes no effect, unfortunately...
-
@meleu said in Can't enter runcommand by pressing a button.:
@Dochartaigh said in Can't enter runcommand by pressing a button.:
@meleu said in Can't enter runcommand by pressing a button.:
But I think you don't have to touch any of these files to solve your issue.
What should I do to solve this issue then?
Discover which button is the button 0 and press that button.
That's what you were getting at before! Gotcha. Still doesn't work. I'm assuming the magic "0" button is the one which works as "A" in the RetroPie Setup menu (which is commonly different than what's "A" in the RetroPie interface while choosing ROMs and such). That's "X" on this controller. Also tried every other button (A, B, X, Y, Left bumper, Right bumper). It will also sometimes work on NES, but then not on SNES, or vice versus for example. The directions on screen also say press A button (not an exact button you have to press)...
-
@meleu said in Can't enter runcommand by pressing a button.:
press the button 0. Pressing the button while the image is being shown takes no effect, unfortu
Oh that's what it is exactly. Except on the keyboard, I can still press it when the image is showing.
-
@Dochartaigh google about
jstest
tool and you'll be able to discover exactly which button is the button 0 in the joysticks you have connected to your system. -
@Dominus said in Can't enter runcommand by pressing a button.:
@meleu said in Can't enter runcommand by pressing a button.:
press the button 0. Pressing the button while the image is being shown takes no effect, unfortu
Oh that's what it is exactly. Except on the keyboard, I can still press it when the image is showing.
Oh, sorry. You have to press button 0 twice. The first press exits
fbi
(the program used to display the image), and the second press invokes runcommand menu. -
@meleu said in Can't enter runcommand by pressing a button.:
jstest
I thank you for your help, but what I'm explicitly saying is NO BUTTON works at all. Like none. On 5+ different controllers I tried every single button. Even tried them twice like I had better luck with before. It does NOT work...
This used to work all the time in 4.0.2, 4.0.8, even the first version of 4.1 (I'm at 4.1.11 now). I could press ANY (A, B, X, Y) button and it would open. I just did a brand new fresh install from the Pi Zero image, on a brand new SD card (been working at that for a couple hours now), and guess what? I STILL can't get into runcommand 100% of the time. Another user here just said the same happens to them....I'm assuming it's a problem in the code somewhere. Something is bricked.
-
Another user here just said the same happens to them....I'm assuming it's a problem in the code somewhere. Something is bricked.
I'm not assuming it's a problem in the code because if it was, other users would complain about it. I think the user you mention is @Dominus , and it seems that his problem was related to the launching images and now it seems to be solved.
Also, you said the problem is intermittent. The code doesn't change between one execution and another.
Sorry but to help you we need a way to reproduce your issue.
If you want to go deeper into this investigation yourself, the help I can give is just share these informations:
-
the
joy2key.py
is the tool responsible to convert joystick button strokes into keyboard strokes. -
The function
start_joy2key()
in this part of the runcommand.sh code is where runcommand invokes the joy2key action. -
This line of runcommand.sh is where the runcommand is waiting for the button 0 pressing.
-
-
@meleu said in Can't enter runcommand by pressing a button.:
Also, you said the problem is intermittent. The code doesn't change between one execution and another.
All I can tell you is what I've experienced:
• Trying multiple controllers would rule a specific controller [type/brand] as being the culprit, correct?
• Trying different USB hubs would rule out the hub as being the problem, correct?
• Trying another Pi Zero would rule out the computer itself (and it's USB connection) as being faulty, correct?
• Trying the SD card in another Zero where the same problem persists would even further rule out any hardware issues, and make you think it's the software, correct?
• Having the exact same issue happen on a completely different, freshly-loaded-from a newly downloaded image (made on another computer, and on a different card reader, written onto a brand new/different SD card itself), would further dictate the problem is the code...isn't that what anyone would think?Am I incorrect with any of the above assumptions? (please let me know and I'll change my testing routine!!! ;) If you guys haven't noticed I'm extremely thorough with my testing before I report a problem (essentially by doing my best to rule out any possible hardware fault before posting here - even trying to reproduce -on occasion- the same problem on a totally different computer and install). Heck, I even post screenshots from my monitor (occasionally) so you know I'm not just full of expletive ;)
I'm also pretty sure (which I can't check now as I don't have an older image loaded up), that in the past I was able to hit a button OTHER THAN button 0 to enter runcommand. runcommand also specifically says to press "a button" instead of "the 0 button". Even on that code you linked to (which to be honest is a foreign language to me), it says ""check for key pressed to enter configuration" - instead of "check for 0 button pressed". I also know I can press ANY key on my keyboard and it'll open runcommand. I can also, for example, hit the "A" button on NES like 10 tries in a row and it won't open runcommand - then switch over to SNES and it'll open right up... (or the opposite sometimes). I'm not saying you're wrong as you clearly know more than I do, but I hope you can see how this would all make any logical person think along the lines of what I'm thinking.
-
All I can tell you is what I know:
- the
runcommand.sh
can only get joystick input becausejoy2key.py
translate some joystick input to keyboard input. - the
runcommand.sh
asksjoy2key.py
to make the button 0 act like the <ENTER> key, make the button 1 act like the <TAB> key, and the d-pad act like the respective arrow keys. - the line of code that makes the
runcommand.sh
wait for input for 2 seconds can read ANY key stroke from the keyboard, but can't get any input from joystick directly. It gets your button 0 pressing only becausejoy2key.py
translates it to the <ENTER> key. - maybe the "other than button 0" that worked was the button 1, which is translated to the <TAB> key (sorry for that, I insisted on button 0 but you can press button 1 too).
- the "a" in the "press a button" message is an indefinite article, not the button name. I agree that it isn't the clearest text to use, but it is the text the devs chose (and to be honest I can't think on a clearer text to suggest). Using "press the 0 button" would bring confusion because the button 0 is a software thing, and users look at the joystick (hardware) they have in hands.
- the
-
Button 0 or 1 definitely makes more sense. I almost always press "A" or "B" (hey, I came from the original Nintendo world ;) to launch the menu (but others weren't working either).
ANY key from the keyboard also makes sense - as I can press any key on the keyboard and it'll launch.
I'll look at the specific controller configs for these 3-4 (maybe 5?) controllers I tried (I've been using cheap chinese-made ones lately since my friends don't want to buy $15-18 Buffalo or Hyperkin controllers). That's stored in "/opt/retropie/configs/all/retroarch-joypads/", right?
-
I appreciate you have tried lots of combinations, but the fact is, this is a problem others are not having (bear in mind the last image of retropie has had over 450,000 downloads). If there was a major issue, many more people would be reporting it.
So something with your set-up is the cause. Start from a fresh 4.1 image, on a specific machine, and try and reproduce it - then list the steps you took and exact specifications of that set-up.
-
@Dochartaigh said in Can't enter runcommand by pressing a button.:
I'll look at the specific controller configs for these 3-4 (maybe 5?) controllers I tried (...). That's stored in "/opt/retropie/configs/all/retroarch-joypads/", right?
No. You have to use the
jstest
tool that I suggested above. -
@BuZz said in Can't enter runcommand by pressing a button.:
this is a problem others are not having (bear in mind the last image of retropie has had over 450,000 downloads). If there was a major issue, many more people would be reporting it.
I know BuZz, you tell me this all the time ;)
Here's exactly what I do taken from my notes. I use 95% of the same notes for the Pi Zero's vs. Pi 3's (but only included my workflow for the Zero below). Right now I have TWO different Pi Zero's built from these exact directions with the same problem. One was built last night, the other maybe 3 weeks ago (so RetroPie 4.1.2? and 4.1.11).
Download Pi 1/0 image from RetroPie site
Unzip img.gz file
Format SD card with ApplePi-Baker (I always do this 2x times just in case)
Put image on SD card
Plug in USB hub w/ USB wifi adapter, keyboard 2.4ghz adapter, 1x controller
Bootup Pi Zero 1st time - which resizes partition automaticallySetup keyboard for A,B,X,Y,Select,Start etc.
Setup USB controller for same
Setup Wifi (or plug in ethernet hub)
Config keyboard from 105 to 101 key with “dpkg-reconfigure keyboard-configuration” so it works properly
uncomment “disable_overscan=1” and “hdmi_drive=2” in Config.txt,
rebootsudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade
reboot
Update all core packages from binary (from RetroPie setup GUI)
reboot
install from optional packages: lr-prboom, lr-quickness, lr-tyrquake, kodi, Wolf4SDL, AND SSelph scraper from tools
rebootPlug in USB drive with “retropie/roms” folders and while it’s copying all the ROMs over (about 13GB):
(make a consolidated save game directory and change permissions so my FTP program is allowed to copy over the config files more easily than using sudo nano to edit them in the hard-to-use linux text editor)
sudo -s
cd RetroPie
mkdir saves
sudo chmod 777 -R /home/pi/RetroPie/saves
sudo chmod 777 -R /etc/emulationstation“/etc/emulationstation”
Change megadrive to “genesis”, change PC Engine to “tg16” (so correct logos for USA are used), reorder so NES, SNES, and Genesis are the first three systems listed.“/opt/retropie/configs/all/retroarch.cfg”
Add: input_player1_analog_dpad_mode = "1" (and the same code for players 1-8 to use analog stick)
Change: savefile_directory = "/home/pi/RetroPie/saves"
Change: savestate_directory = "/home/pi/RetroPie/saves”Run df -Bm until I see that everything is done copying over, then reboot.
Exit from emulationstation and run SSelph’s scraper (usually overnight) to get art for all ROMs.
THEN, I test everything which is where there’s commonly some of the issues I’ve described popping up.
For the last build I used stock overclock settings:
arm_freq=1000
gpu_freq=500
core_freq=500
sdram_freq=500
sdram_schmoo=0x02000020
over_voltage=2
sdram_over_voltage=2And changed the default NES emulator to be lr-quicknes…that’s my entire process I’ve done about 100 times (not even joking) so far.
-
@Dochartaigh said in Can't enter runcommand by pressing a button.:
this is a problem others are not having (bear in mind the last image of retropie has had over 450,000 downloads). If there was a major issue, many more people would be reporting it.
I know BuZz, you tell me this all the time ;)
I believe I possibly mentioned it to you once in your other topic. I will keep repeating it if you keep saying there is a problem with the software whilst being the only one with the issue so far :) (tbh I can't remember everything I have said to everyone - I have made a lot of posts to a lot of people).
Can you reproduce this on a rpi1/2/3 without the Hub and the same controller? What controllers are you using? What PSU ? Do you have any other controllers ?
For the sake of testing this I would avoid any overclocking.
-
BuZz, I thought I was special because I'm just the right amount of annoying (yet cheeky and fun) to stand out on this forum? WTH? lol
I don't own a Raspberry Pi 1 or 2 - just several Pi Zero's and I'm down to one Pi 3 Model B at the moment. I do have multiple hubs, and even those little flat micro USB to USB adapters I could plug a controller directly into the Zero if you wanted.
The controllers I've been testing with most frequently are iNNEXT brand (cheap chinese ones, but the best of the ~7 cheap brands I tested). Also have both the types of iBuffalo SNES and Famicon-style, Hyperkin Sega Genesis 6-button, a random NES 2-button, and about 15 different USB adapters for real controllers. Over the last couple nights I've tried the iNNext, red Buffalo Famicon-style, and the Hyperkin (Genesis 6-button). Honestly don't know if I was pressing 0 or 1 on all of them - usually just try at least 2 random buttons at a time, get mad it isn't going into runcommand, then switch in another controller (sometimes rebooting in-between if plugging in another controller crashes the system like it's been doing lately on occasion like I mentioned I my other topic).
Power supply is usually an Anker 4-port 10amp? USB charging hub (2.4 amp per channel). When I was testing two on Zero's last night at the same time I stole the Canakit 2.5amp from the Pi 3. Multiple USB cables - mostly Amazon Basic and some Cables Direct.
Also, I posted in more detail on my other topic, but I found a random SD card and popped it in. It has RetroPie 4.1.5 on it. All my test NES/SNES games play perfect on it (no lag) AND runcommand seems to work whenever I try to enter it with the same INNext brand controller (and same everything else like power/HDMI/hub)...just thought I'd put it out there that 4.1.5 seems perfect but 4.1.11 is giving me issues (but it IS only one example...just something to note).
-
I am not sure if you found out the solution, but for me, oddly enough, it was about moving the left joystick on my PS3 controller that I use for RetroPie. During the run command splash menu, I move the left stick around to enter runcommand launch menu.
-
@dochartaigh I have the same problem cannot access launch options unless I use a keyboard it works every time with the keyboard and the o key is mapped to select on my controller but with the controller it never works if you have found a fix for it would be nice to know. thx.
-
@ncrx please open another topic and give as much info about your setup as you can (like those suggested in the read-me-first post).
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.