hum, I think the script will continue to use version 0.0.1 from the apt repo for a little while… but I guess it’s best not to overlook thas aspect. @wstevens0n, what version is reported by:
$ sudo service phatbeatd status
● phatbeatd.service - LSB: Starts PHAT BEAT VLC control daemon at boot time
Loaded: loaded (/etc/init.d/phatbeatd)
Active: active (exited) since Wed 2017-04-12 23:34:20 CDT; 17h ago
Process: 403 ExecStart=/etc/init.d/phatbeatd start (code=exited, status=0/SUCCESS)
Apr 12 23:34:11 piRadi0 phatbeatd[403]: Starting…
Apr 12 23:34:12 piRadi0 su[429]: Successful su for root by root
Apr 12 23:34:12 piRadi0 su[429]: + ??? root:root
Apr 12 23:34:12 piRadi0 su[429]: pam_unix(su:session): session opened for u…0)
Apr 12 23:34:20 piRadi0 phatbeatd[403]: 2017-04-12 23:34:20.285699: PHAT BEA…8
Apr 12 23:34:20 piRadi0 systemd[1]: Started LSB: Starts PHAT BEAT VLC contr…e.
Apr 13 17:24:14 piRadi0 systemd[1]: Started LSB: Starts PHAT BEAT VLC contr…e.
Apr 13 17:26:05 piRadi0 systemd[1]: Started LSB: Starts PHAT BEAT VLC contr…e.
Hint: Some lines were ellipsized, use -l to show in full.
$ pip list
phatbeat (0.0.1)
I tried doing a stop and start of the service with no avail. Buttons are still registering via test script.
~/Pimoroni/phatbeat/test $ ./test.sh
testing audio
speaker-test 1.0.28
Playback device is default
Stream parameters are 48000Hz, S16_LE, 2 channels
WAV file(s)
Using device: phat-beat
Rate set to 48000Hz (requested 48000Hz)
Buffer size range from 2048 to 8192
Period size range from 1024 to 1024
Using max buffer size 8192
Periods = 4
was set period_size = 1024
was set buffer_size = 8192
0 - Front Left
1 - Front Right
Time per period = 2.849641
testing basic wav playback
Using device: phat-beat
Playing WAVE './test.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
testing gpio control...
press all buttons along the side of the pHAT...
press the power button on the pHAT to exit...
testing VU meter
Fast Forward pressed!
Play/Pause pressed!
Rewind pressed!
Volume Up pressed!
Volume Down pressed!
Power On/Off pressed!
exiting...
From what I saw the other day was that service is running as intended, but some reason it didn’t register button mappings for VLC unless I manually executed from the terminal.
I’m not sure if it’s conflicting the the boot up of the OS or an additional security “feature”, but I’ve had similar issues like this with other scripts in Raspbian and editing autostart always seemed to be a good fail-safe.
I have the same issue. It looks like the service is started:
pi@PiRadio:~ $ sudo service phatbeatd status
● phatbeatd.service - LSB: Starts PHAT BEAT VLC control daemon at boot time
Loaded: loaded (/etc/init.d/phatbeatd)
Active: active (exited) since Thu 2017-10-05 15:10:59 CEST; 2min 1s ago
Process: 432 ExecStart=/etc/init.d/phatbeatd start (code=exited, status=0/SUCCESS)
Oct 05 15:10:52 PiRadio phatbeatd[432]: Starting…
Oct 05 15:10:52 PiRadio su[507]: Successful su for root by root
Oct 05 15:10:52 PiRadio su[507]: + ??? root:root
Oct 05 15:10:52 PiRadio su[507]: pam_unix(su:session): session opened for user root by (uid=0)
Oct 05 15:10:58 PiRadio phatbeatd[432]: 2017-10-05 15:10:58.766830: PHAT BEAT daemon running with PID: 683
Oct 05 15:10:59 PiRadio systemd[1]: Started LSB: Starts PHAT BEAT VLC control daemon at boot time.
But the buttons do not work. sudo service phatbeatd start does not work, but stopping and starting it does - that is, until reboot. :(
Guess I could autostart it like wstevens0n suggest, but would like a more permanent solution.