Or you could try the following:
sudo nano /home/unmutepiamp
and then add the lines ...
#Unmute the Pi-AMP+
echo "22" > /sys/class/gpio/export
echo "out" >/sys/class/gpio/gpio22/direction
echo "1" >/sys/class/gpio/gpio22/value
Then save & exit
Then do
cd /home
chmod a+x unmutepiamp
This script is run at power up using cronie which must be installed so do ...
pacman -S cronie
If you get a 404 error, do ...
pacman –Syy cronie
Now do ...
systemctl enable cronie.service
systemctl unmask cronie.service
systemctl start cronie.service
export EDITOR=nano
crontab -e
And insert following line ...
@reboot sleep 5 ; /home/unmutepiamp
Then save & exit
Now check that cronie is running and that the cron job is there by doing ...
systemctl status cronie
crontab -l
Hope this helps