-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Softshut Not working #17
Comments
Do you have the board hooked up to the Pi as per the guide linked below? The options as shown in the two pictures here are pins 2 and 6 or pins 7 and 11 - https://learn.pi-supply.com/pi-supply-switch-v1-1-assembly-instructions/ But with the Pin 7 / 11 you need the software running on the pi for it to work correctly |
Hi @shawaj thanks for reaching out. I have physically hooked up the power switch to my Pi in this order: USB to micro USB from power supply to power switch, USB to micro USB from power switch to Pi, Pin 7 on the power switch to Pin 7 on the Pi, and Pin 8 on the power switch to Pin 11 on the Pi. Because of the error I get when running "systemctl status piswitch.service", I believe my issue is with the software. The error is listed below:
Any suggestions? Thanks! |
I have found a solution to the error I was receiving, "RuntimeError: Error waiting for edge". There appears to be an issue in the RPi.GPIO directory when calling "GPIO.wait_for_edge(PinSeven, GPIO.RISING)". The code runs perfectly if that line is removed (as shown below).
|
@LDDill is this an error in our code? Or something you added? |
@shawaj The original code had "GPIO.wait_for_edge(PinSeven, GPIO.RISING)" on line 17. However, the code would give an error when ran. After removing that line the code works correctly. With a press initiating shut down and a hold initiating reboot. |
Hi I followed all of the instructions step-by-step. I am using a raspberry pi 3B+ running raspbian stretch. The ON and Off buttons work, but not the Softshut Off button. Shown below is what I get when I run "systemctl status piswitch.service". Any suggestions?
This is what my softshut.py file looks like.
Thanks!
The text was updated successfully, but these errors were encountered: