The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.34 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



Thank you for your donation!


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


Problem: IR HAT power on/off - configuration
#1
I bought this HAT: https://wiki.52pi.com/index.php?title=EP-0077

I used this script: 
Code:
#!/bin/bash
echo -e "\e[32;40mInstall package's for script. \e[0m"
sudo apt-get install -y -qq wiringpi
sudo sh -c " curl -sSL https://raw.githubusercontent.com/geeekpi/RPB-HAT/master/remoteswitch > /bin/remoteswitch "
sudo chmod a+x /bin/remoteswitch
sudo sed -i '$i sudo remoteswitch &' /etc/rc.local
echo -e '"\e[32:40m Reboot your raspberry and try to press the power button, reboot button and test it.\e[0m"'
for i in 5 4 3 2 1
do
 echo -e "\e[32;40m $i second...\e[0m"
 sleep 1
done
sudo sync
sudo shutdown -r now


Remote on and off works. Unfortunately, when I use the power off button in the moode interface, the system shuts down, but hat does not turn off the raspberry's power. The LEDs are on. I then have to press the button on the remote control again and only then everything goes out. After that, turning on the remote is OK. What to do to make the effect the same when:
- I press the button on the remote control
- press power off in moode

?
Reply


Messages In This Thread
IR HAT power on/off - configuration - by arczar - 11-21-2022, 07:46 PM

Forum Jump: