Page 1 of 1

RaspTouch from Audiophonics (France)

PostPosted: 14 Feb 2017, 17:05
by K5DBB
I have one of the new RaspTouch units from Audiophonics in France. This is a beautiful unit with touch-screen display, Raspberry Pi 3, the Audiophonics ES9018K2M DAC board and the Audophonics Power Management Module for the Raspberry Pi.

I am really impressed with this unit. It looks beautiful in the CNC machined aluminum enclosure with touch-screen display. I ordered it pre-assembled with RuneAudio pre-installed on an externally accessible MicroSD card.

I have a question about the power-down from within the menu in RuneAudio. I made a back-up MicroSD card. I downloaded the RuneAudio disk image and burned it to a SanDisk 8-Gbyte card. I installed the card and configured my play list. When I went to use Shut Down from the menu within RuneAudio, the unit would re-boot instead of shut down. I confirmed this several times and could find nothing in the settings that would affect this behavior.

I re-inserted the original MicroSD card as supplied by Audiophonics and the Shut Down from the RuneAudio menu worked properly.

Does anyone have any experience with this problem ??? I have attached a few photos to illustrate the Audiophonics Power Management Module.

Re: RaspTouch from Audiophonics (France)

PostPosted: 14 Feb 2017, 18:49
by hondagx35
Hi K5DBB,

Does anyone have any experience with this problem ???

I wouldn't call it a problem.
What is the reason for using the RuneAudio image?

The image provided by Audiophonics is based on our latest RP2/3 image.

These are the major modifications.
/var/www/command/rune.shutdown:
Code: Select all
#!/bin/bash
#
#  Copyright (C) 2013-2014 RuneAudio Team
#  http://www.runeaudio.com
#
#  RuneUI
#  copyright (C) 2013-2014 – Andrea Coiutti (aka ACX) & Simone De Gregori (aka Orion)
#
#  RuneOS
#  copyright (C) 2013-2014 – Simone De Gregori (aka Orion) & Carmelo San Giovanni (aka Um3ggh1U)
#
#  RuneAudio website and logo
#  copyright (C) 2013-2014 – ACX webdesign (Andrea Coiutti)
#
#  This Program is free software; you can redistribute it and/or modify
#  it under the terms of the GNU General Public License as published by
#  the Free Software Foundation; either version 3, or (at your option)
#  any later version.
#
#  This Program is distributed in the hope that it will be useful,
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
#  GNU General Public License for more details.
#
#  You should have received a copy of the GNU General Public License
#  along with RuneAudio; see the file COPYING.  If not, see
#  <http://www.gnu.org/licenses/gpl-3.0.txt>.
#
#  file: command/rune_shutdown
#  version: 1.3
#  coder: Simone De Gregori
#

if [[ $1 == "poweroff" ]] ; then
  echo "power off RuneAudio"
  splash="/usr/share/bootsplash/shutdown.png"
  gpio mode 7 out
  gpio write 7 1
  sleep 1
  echo "Setting pin GPIO7 Low"
  gpio write 7 0
else
  echo "reboot RuneAudio"
  splash="/usr/share/bootsplash/reboot.png"
  # Reboot blink will stop after Boot OK return
  echo "setting pin GPIO 4 High"
  gpio -g mode 4 out
  gpio -g write 4 1
fi

echo "Stop MPD and unmount shares..."
mpc stop
systemctl stop nginx
sleep 1
killall xinit
sleep 1
ply-image "$splash"
systemctl stop mpd
systemctl stop spopd
sleep 1
export DISPLAY=:0
xset dpms force off
sleep 1
umount -aft nfs
umount -aft cifs


/usr/lib/systemd/system/sds.service
Code: Select all
##Made by Hondagx35
##For Audiophonics sds.sh power manager board
##Save this as /usr/lib/systemd/system/sds.service

[Unit]
Description=Audiophonics Shutdown Service
After=network.target

[Service]
ExecStart=/usr/local/bin/sds.sh
ExecReload=/usr/bin/kill -HUP $MAINPID
KillMode=process
Restart=always
RestartSec=10
StartLimitInterval=30
StartLimitBurst=20

[Install]
WantedBy=multi-user.target


/usr/local/bin/sds.sh
Code: Select all
#!/bin/bash
#Thanks to Hondagx35
#http://www.runeaudio.com/forum/audiophonics-i-sabre-v3-dac-es9023-tcxo-t3377.html#p13106
#http://www.runeaudio.com/forum/audiophonics-i-sabre-v3-dac-es9023-tcxo-t3377-20.html#p13195

PATH=/bin:/usr/bin:/usr/bin/gpio

echo "Audiophonics Shutdown script starting..."
echo "Asserting pins : "
echo "ShutDown : GPIO17=in, Low"
echo "BootOK : GPIO22=out, High"

gpio -g mode 17 in
gpio -g write 17 0
gpio -g mode 22 out
gpio -g write 22 1

while [ 1 ]; do
  if [ "$(/usr/bin/gpio -g read 17)" = "1" ]; then
        echo "ShutDown order received, RaspBerry pi will now enter in standby mode..."
        /var/www/command/rune_shutdown poweroff
        systemctl poweroff
        break
  fi
/bin/sleep 0.25
done

exit 0

This file has to executable.

Frank

Re: RaspTouch from Audiophonics (France)

PostPosted: 14 Feb 2017, 19:54
by K5DBB
<<< I wouldn't call it a problem. What is the reason for using the RuneAudio image? The image provided by Audiophonics is based on our latest RP2/3 image. >>>

The reason is that I wanted a Back-Up of the MicroSD card image. I used the standard tools available on-line to make a .IMG file of the Audiophonics 8-Gbyte card that was supplied with my RaspTouch. I then tried to burn this image to another 8-Gbyte Sandisk Extreme card. When I tried this, I encountered an error stating that the .IMG file generated from the Audiophonics card was a few bytes too large to fit on the 8-Gbyte Sandisk card. I tried twice, receiving the same error twice.

So, I thought that I would just generate the Back-Up card by using the standard RuneAudio image available here for download.

This image worked fine except that now, my RaspTouch would Reboot instead of Shut Down when requested from the menu inside RuneAudio.

Re: RaspTouch from Audiophonics (France)

PostPosted: 14 Feb 2017, 22:08
by hondagx35
Hi K5DBB,

you only have to bring the three files from my last post in place and execute this:
Code: Select all
systemctl enable sds
systemctl start sds


Please search the forum to see how to get access to the console and transfer files to your sd card.

Frank