Power button
#1
Hi,

I'm having a strange issue with my power button. It seems to do the job turning on. Slide to the right, wait for green light then slight back to the left. But it doesn't want to turn off anymore. It used to be that I would just slide it over to the right and wait for 3 seconds or so and it would turn off.

What should I check/do?

Cheers,

Linus
Reply
#2
What image file did you install? Was it the one from me? Is your LCD working fine? Are the buttons all working fine?

There should be a script that runs that monitors the state of the power button. If it's held for a while, the script shuts down the Pi.

You can also shut down from the main menu, if I recall correctly. You may want to see if that works.

Also, if you are supplying power directly to the Pi, it may not shut down fully.

Did you ever install the Pi upside-down in the GPA? I think we found one that damaged a GPIO pin. I think it caused the power button to not work properly.
Card Fighters' Clash 2 English Translation ( http://cfc2english.blogspot.com/ )
Neo Geo Pocket Flash Cart and Linker Project ( http://www.flashmasta.com/ )
Avatar art thanks to Trev-Mun ( http://trevmun.deviantart.com/ )
Reply
#3
(02-19-2017, 03:15 PM)Flavor Wrote: What image file did you install? Was it the one from me? Is your LCD working fine? Are the buttons all working fine?

There should be a script that runs that monitors the state of the power button. If it's held for a while, the script shuts down the Pi.

You can also shut down from the main menu, if I recall correctly. You may want to see if that works.

Also, if you are supplying power directly to the Pi, it may not shut down fully.

Did you ever install the Pi upside-down in the GPA? I think we found one that damaged a GPIO pin. I think it caused the power button to not work properly.

It was the image from the Google Drive.

The LCD does appear to be working correctly.

All buttons are working correctly though I did have some problems with the B button that have been fixed by resoldering.

I don't think I've installed it upside down at any point.

I did manage to find a quit screen in emulation station that correctly shutdown the machine.

Unfortunately without the power button I can't exit a game to get back to the main menu.

It seems odd that it powers on okay but not off. If I slide the button to the right it does seem to turn off eventually but it can take up to half an hour to detect it. So I'm not sure if that sounds like a bad soldering job or that the script is starved / not running.

I'm powering it using a battery (the correct type now).

I actually have another GPA board I could try but I'd like that as a last resort as I'll have to take the whole thing apart.

Many thanks again for your help, this little thing is awesome. So close to working 100%.
Reply
#4
"half an hour"
That's insane!

This does make me wonder if it's a bad connection somewhere, and that the Pi just doesn't properly detect it most of the time.

Most of the emulators are set up to exit by
tapping the power button (which puts it in HOTKEY mode) and then tapping SELECT (or START+SELECT in some emulators)

If you wanted to change some configuration stuff, it's fairly easy to remove the HOTKEY functionality and just use START+SELECT to exit emulators.

The main reason that I changed it to use the power button (for HOTKEY mode) was because I would sometimes hit START+SELECT when I only meant to hit START. It's rather annoying to accidentally exit a game instead of just hitting START.

I don't really know how to debug this issue over the forum or email. My gut feeling (with the info provided) is that there's a bad connection to the Pi. The power-button bootup functionality isn't handled by the Pi (it's direct on the GPA board). Once the Pi starts up, it sets a GPIO to keep the power turned on.

Then, the power button ALSO is hooked to a GPIO line. When you press it, the Pi should "see" that. If you hold it in, after 5 seconds (which is just my guess from memory) it will send a signal to shutdown.

If this connection between the button and the Pi GPIO is bad, then it would not properly (maybe never, but maybe intermittently) shut down or enter HOTKEY mode.

If you have a keyboard+HDMI to hook up, or if you can SSH into the Pi, we can run the joystick test to get data about every button.

I think it's something like
jstest /dev/input/js0

That should show all the joystick buttons as ON/OFF, and you can see if the power button changes the value.

You can also use
gpio read

to give you info about the state of a GPIO pin, but I don't have the data here in front of me this weekend to tell you what other parameters to give it.

If you want to test that stuff (and can get to a terminal prompt and type), I can get you the info on what/how to test it. LMK
Card Fighters' Clash 2 English Translation ( http://cfc2english.blogspot.com/ )
Neo Geo Pocket Flash Cart and Linker Project ( http://www.flashmasta.com/ )
Avatar art thanks to Trev-Mun ( http://trevmun.deviantart.com/ )
Reply
#5
(02-20-2017, 05:52 AM)Flavor Wrote: "half an hour"
That's insane!

This does make me wonder if it's a bad connection somewhere, and that the Pi just doesn't properly detect it most of the time.

Most of the emulators are set up to exit by
tapping the power button (which puts it in HOTKEY mode) and then tapping SELECT (or START+SELECT in some emulators)

If you wanted to change some configuration stuff, it's fairly easy to remove the HOTKEY functionality and just use START+SELECT to exit emulators.

The main reason that I changed it to use the power button (for HOTKEY mode) was because I would sometimes hit START+SELECT when I only meant to hit START.  It's rather annoying to accidentally exit a game instead of just hitting START.

I don't really know how to debug this issue over the forum or email.  My gut feeling (with the info provided) is that there's a bad connection to the Pi.  The power-button bootup functionality isn't handled by the Pi (it's direct on the GPA board).  Once the Pi starts up, it sets a GPIO to keep the power turned on.  

Then, the power button ALSO is hooked to a GPIO line.  When you press it, the Pi should "see" that.  If you hold it in, after 5 seconds (which is just my guess from memory) it will send a signal to shutdown.

If this connection between the button and the Pi GPIO is bad, then it would not properly (maybe never, but maybe intermittently) shut down or enter HOTKEY mode.

If you have a keyboard+HDMI to hook up, or if you can SSH into the Pi, we can run the joystick test to get data about every button.

I think it's something like
jstest /dev/input/js0

That should show all the joystick buttons as ON/OFF, and you can see if the power button changes the value.

You can also use
gpio read

to give you info about the state of a GPIO pin, but I don't have the data here in front of me this weekend to tell you what other parameters to give it.

If you want to test that stuff (and can get to a terminal prompt and type), I can get you the info on what/how to test it.  LMK

Hey,

 I know this is way old, but did this ever get sorted out?? I just finished building my Freeplay zero and am having the EXACT same issues. Except, I have never been able to use the power button to shut off (or as HOTKEY). Everything else is working fine. Hold to the right and it powers on and that's pretty much it for the power button. I have to either pull the plug (in game) or QUIT through the emulator screen. I have double checked GPIO pins and tried a joystick test. jstest /dev/input/js0. Every button responded except the power. Any advice will be greatly appreciated!
Reply
#6
Do you guys have your power button slider modified so it springs back like a DS power button?

I have seen some people that leave the nub on and then it acts like a on/off switch. This causes other problems (maybe like what you’re experiencing).
Card Fighters' Clash 2 English Translation ( http://cfc2english.blogspot.com/ )
Neo Geo Pocket Flash Cart and Linker Project ( http://www.flashmasta.com/ )
Avatar art thanks to Trev-Mun ( http://trevmun.deviantart.com/ )
Reply
#7
Mine springs back like a DS power button.
Reply
#8
Then I would maybe suspect that where you soldered or hammered the Pi, maybe the one pin that is responsible for the power button didn’t get connected properly somehow.

https://www.freeplaytech.com/support/troubleshooting/

Check there to see about the GPIO troubleshooting.

And I apologize if my post sounds funny. I am on my phone and trying to use speech to text here.
Card Fighters' Clash 2 English Translation ( http://cfc2english.blogspot.com/ )
Neo Geo Pocket Flash Cart and Linker Project ( http://www.flashmasta.com/ )
Avatar art thanks to Trev-Mun ( http://trevmun.deviantart.com/ )
Reply
#9
Hey,

So I guess it was the image I was using. I originally used GPA_PiZeroW_3-13-17.img I have a PiZero W so I thought that made sense. I was pretty sure everything physically was OK so I decided I was going to re-image and this time I used Freeplay_Zero_17111701.img which was actually the only one in the google drive this time around. I can now do everything normally and my power switch works as a HOTKEY and an OFF switch. It is interesting to note that I could almost everything with that other image except power OFF/HOTKEY. Thank you for your quick responses!!
Reply
#10
That actually is pretty interesting. I don't think anything about the power button/switch changed between those. The code for the power button did change, and it likely became better and more stable. I wonder if that script was crashing for some reason.

I'm glad we figured it out, though. I understand the confusion with the file names. That other file was just left around for any of the original "Game Pie Advance" users (if they needed it for some reason).
Card Fighters' Clash 2 English Translation ( http://cfc2english.blogspot.com/ )
Neo Geo Pocket Flash Cart and Linker Project ( http://www.flashmasta.com/ )
Avatar art thanks to Trev-Mun ( http://trevmun.deviantart.com/ )
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)