jpezz
Posts: 97
Joined: Fri Apr 26, 2013 6:14 pm
Location: North Carolina, U.S.

Can I get back the flashing green light?

Thu Apr 04, 2019 1:41 pm

I have a Pi 3B+ and used the shutdown switch program described here: https://www.instructables.com/id/Simple ... wn-Button/. It works great. However, the first time I used it, it flashed the green light as it said but then on, there is no green light EVER i.e. on bootup, disk access, etc. Other than that, the Pi works great as do the GPIO pins used for that program (25 & 26) and other hardware attached (GPIO17).
Is there any way to get back my green light?

User avatar
NGC6543
Posts: 75
Joined: Thu Feb 28, 2019 7:30 pm
Location: Lancashire, UK

Re: Can I get back the flashing green light?

Thu Apr 04, 2019 1:58 pm

Can't help with the light, but you don't need a script for that on the 3B+. Just add the following line to /boot/config.txt

dtoverlay=gpio-shutdown,gpio_pin=3

You can change the GPIO pin, but leaving it at 3 means the same button will start the Pi up again too. Of course, if you use I2C which uses that pin, you'll need to change it.

ETA: I did use the script method on my 3B+ before I discovered the above method, and my green light still worked.

User avatar
B.Goode
Posts: 7868
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: Can I get back the flashing green light?

Thu Apr 04, 2019 2:04 pm

jpezz wrote:
Thu Apr 04, 2019 1:41 pm
I have a Pi 3B+ and used the shutdown switch program described here: https://www.instructables.com/id/Simple ... wn-Button/. It works great. However, the first time I used it, it flashed the green light as it said but then on, there is no green light EVER i.e. on bootup, disk access, etc. Other than that, the Pi works great as do the GPIO pins used for that program (25 & 26) and other hardware attached (GPIO17).
Is there any way to get back my green light?

There doesn't seem to be anything in the off_button Python script associated with that tutorial that would disable the Activity led.


As a troubleshooting/diagnostic step, could you try getting a new or spare microSD card and writing a fresh version of the current release of the Raspbian Stretch Operating System (the Lite version would suffice for this purpose). Then try booting from that card. This would eliminate any unexpected errors arising from configuration of your RPi for use with the off button.

jpezz
Posts: 97
Joined: Fri Apr 26, 2013 6:14 pm
Location: North Carolina, U.S.

Re: Can I get back the flashing green light?

Fri Apr 05, 2019 1:26 am

NGC6543 wrote:
Thu Apr 04, 2019 1:58 pm
Can't help with the light, but you don't need a script for that on the 3B+. Just add the following line to /boot/config.txt

dtoverlay=gpio-shutdown,gpio_pin=3

You can change the GPIO pin, but leaving it at 3 means the same button will start the Pi up again too. Of course, if you use I2C which uses that pin, you'll need to change it.

ETA: I did use the script method on my 3B+ before I discovered the above method, and my green light still worked.
All that did was stop the poweroff from completing. Thanks anyway.

jpezz
Posts: 97
Joined: Fri Apr 26, 2013 6:14 pm
Location: North Carolina, U.S.

Re: Can I get back the flashing green light?

Fri Apr 05, 2019 1:33 am

B.Goode wrote:
Thu Apr 04, 2019 2:04 pm
jpezz wrote:
Thu Apr 04, 2019 1:41 pm
I have a Pi 3B+ and used the shutdown switch program described here: https://www.instructables.com/id/Simple ... wn-Button/. It works great. However, the first time I used it, it flashed the green light as it said but then on, there is no green light EVER i.e. on bootup, disk access, etc. Other than that, the Pi works great as do the GPIO pins used for that program (25 & 26) and other hardware attached (GPIO17).
Is there any way to get back my green light?

There doesn't seem to be anything in the off_button Python script associated with that tutorial that would disable the Activity led.


As a troubleshooting/diagnostic step, could you try getting a new or spare microSD card and writing a fresh version of the current release of the Raspbian Stretch Operating System (the Lite version would suffice for this purpose). Then try booting from that card. This would eliminate any unexpected errors arising from configuration of your RPi for use with the off button.
Well, here's what I tried:
A new backup Pi came in yesterday. I have a Pi system at our museum and I'm working on a second system for a different purpose so I had ordered one. I tried the same SD on the new Pi and the light works fine. I did not try activating the shutdown script on the new one.

I also tried an older SD (I rotate them out as I update the software) that was done before I used that script. It still did not resolve the light issue on the older one.

Green light, wherefore art thou?

User avatar
HawaiianPi
Posts: 4241
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: Can I get back the flashing green light?

Fri Apr 05, 2019 2:15 am

jpezz wrote:
Fri Apr 05, 2019 1:33 am
Green light, wherefore art thou?
Dead, most likely. :cry:

The question is, what killed it? :?
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

User avatar
NGC6543
Posts: 75
Joined: Thu Feb 28, 2019 7:30 pm
Location: Lancashire, UK

Re: Can I get back the flashing green light?

Fri Apr 05, 2019 11:10 am

jpezz wrote:
Fri Apr 05, 2019 1:26 am
All that did was stop the poweroff from completing. Thanks anyway.
What makes you think it didn't complete? (ETA: You did disable your script when you tried the other method, didn't you?)

The Pi doesn't power off as such - it just halts*. Either method produces exactly the same result as far as I can see (I tested them), except that the dtoverlay method doesn't have to have a script running (or call one).

*Which is why I'm building a UPS with a proper, controlled, power-off function.

jpezz
Posts: 97
Joined: Fri Apr 26, 2013 6:14 pm
Location: North Carolina, U.S.

Re: Can I get back the flashing green light?

Fri Apr 05, 2019 2:42 pm

NGC6543 wrote:
Fri Apr 05, 2019 11:10 am
jpezz wrote:
Fri Apr 05, 2019 1:26 am
All that did was stop the poweroff from completing. Thanks anyway.
What makes you think it didn't complete? (ETA: You did disable your script when you tried the other method, didn't you?)

The Pi doesn't power off as such - it just halts*. Either method produces exactly the same result as far as I can see (I tested them), except that the dtoverlay method doesn't have to have a script running (or call one).

*Which is why I'm building a UPS with a proper, controlled, power-off function.
Simple, instead of the screen going blank and showing that there was no input
Cable not connected
(feature of the monitor), it sits there showing
plymouth-poweroff service
forever.

jpezz
Posts: 97
Joined: Fri Apr 26, 2013 6:14 pm
Location: North Carolina, U.S.

Re: Can I get back the flashing green light?

Fri Apr 05, 2019 2:44 pm

HawaiianPi wrote:
Fri Apr 05, 2019 2:15 am
jpezz wrote:
Fri Apr 05, 2019 1:33 am
Green light, wherefore art thou?
Dead, most likely. :cry:

The question is, what killed it? :?
Oh well! Better the light than the Pi. Thanks.

Return to “Troubleshooting”