Thank you for your donation!


Cloudsmith graciously provides open-source package management and distribution for our project.


Power button and relay
#3
Wink 
Hi,

I can do the first part (wire a "off" push button)  Smile

Here is a GPIO map - We can use pins that are not marked with a red dot :

[Image: rpi_hiffiberrydac_gpio.jpg]
Please mind that other Hifi DAC can use differents GPIO pins !

Then, turn Raspberry Pi ON

Connect to the PI with SSH :
- Run PuTTY on your computer
- login "pi"
- password "moodeaudio"

Then, open and edit /boot/config.txt (https://www.makeuseof.com/tag/edit-boot-...pberry-pi/)
- enter "cd /"
- enter "ls"
- enter "cd /boot"
- enter "sudo nano config.txt"
- add a line "dtoverlay=gpio_shutdown,gpio_pin=23"
(I use GPIO 23 that is pin 16 to connect my "off" push button)
NB: verr num key may not work... so that to type numbers and "-" use keys on top of QWERTY
- enter CTRL+X to save
- enter "exit" to close PuTTY

Then shut down the PI with the shutdown menu of the Moode Audio web interface

Thus, you can plug the "off" push button between the pin 16 and ground

When I turn on again the PI, the push button makes the PI shutdown properly
It works also when Moode Audio is playing music.

The first part is done  Smile

I have to do the next part : find or generate an electronic signal to said PI is ready to power down - I don't know how to do that...  Blush

Regards
Reply


Messages In This Thread
Power button and relay - by electroremy - 03-21-2021, 08:15 PM
RE: Power button and relay - by bitlab - 03-21-2021, 08:43 PM
RE: Power button and relay - by electroremy - 03-22-2021, 03:42 PM
RE: Power button and relay - by electroremy - 03-22-2021, 05:01 PM
RE: Power button and relay - by electroremy - 04-06-2021, 11:28 AM
RE: Power button and relay - by usename8 - 09-05-2021, 01:02 PM
RE: Power button and relay - by bitlab - 04-06-2021, 06:44 PM
RE: Power button and relay - by gregvds - 04-17-2021, 07:56 AM
RE: Power button and relay - by DRONE7 - 04-17-2021, 11:08 PM
RE: Power button and relay - by gregvds - 04-18-2021, 08:34 AM
RE: Power button and relay - by DRONE7 - 04-19-2021, 08:30 AM
RE: Power button and relay - by coin777 - 09-28-2021, 09:47 PM
RE: Power button and relay - by usename8 - 10-01-2021, 05:08 AM
RE: Power button and relay - by Gekel - 10-07-2021, 08:46 PM

Forum Jump: