On/off when run_this_before_entering_active_state #1637
ghost
started this conversation in
Show and tell
Replies: 1 comment
-
Thanks for this! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I want to show how you can use your raspberry to trigger your amp to turn on when you run
run_this_before_entering_active_state
and turn it off when you runrun_this_after_exiting_active_state
My system is:
Purify EVAL1
smps1200a400
SMSL SU-8s
Raspberry PI4
Elac FS407
The SMPS1200a400 has the ability to turn on at 0V and go into standby at 3V. And that is the starting point for this "guide". If you need to switch on at 12V and go into standby at 0V, that is also possible, but that is beyond the scope of this guide. (Suggestions and examples are welcome)
I use GPIO/BCM pin 21/GND39 on my Raspberry which is connected to GPIO/GND PIN J5.1/J5.5 on my smps1200a400 using two of these https://www.conrad.com/p/tru -components-718672-35-mm-audio-jack-socket-vertical-vertical-number-of-pins-num-2-mono-black-1-pcs-1567107
sudo usermod -a -G gpio shairport-sync
On via GPIO
sudo mkdir script
sudo nano script/amp_on.py
Off via GPIO
sudo nano script/amp_off.py
Off on boot via GPIO
sudo mkdir logs
sudo nano script/off_on_boot.sh
sudo chmod 755 script/off_on_boot.sh
sudo crontab -e
@reboot sh /home/pi/script/off_on_boot.sh >/home/pi/logs/cronlog 2>&1
sudo nano /etc/shairport-sync.conf
Beta Was this translation helpful? Give feedback.
All reactions