advertisement


Be real neat if

Hi all,

its maby a stupid a question but I like to ask anyway:

For my friends I like to work with the Squeezelug/Max2Play image, that contains all in one, LMS and squeezelight as Player. (based on Raspian)

Would it be possible to bring the same script working to turn on an GPIO at play state?
If yes, could sombody give me a quick guide how to?
 
Hi all,

its maby a stupid a question but I like to ask anyway:

For my friends I like to work with the Squeezelug/Max2Play image, that contains all in one, LMS and squeezelight as Player. (based on Raspian)

Would it be possible to bring the same script working to turn on an GPIO at play state?
If yes, could sombody give me a quick guide how to?

Hi palmerx,

I reckon it should work on Raspbian with little or no change required. Remove any piCorePlayer specific stuff.

piCore can be considered a subset of Raspbian, so if it works in piCore it should work in Raspbian. Raspbian usually uses bash instead of sh, and you might prefer to take advantage of python.

This thread pretty much describes how to do it.

regards
Greg
 
Hi there!

Long time ago but I have an answer: It is working on max2play raspian image.


Unluckily I cant get the relay.sh working on the newest piCore image. Can someone help me?

What I did. Updated from 1.18b to 1.22
Then the script was not working anymore.

So I stored relay.sh again with WinSCP in ./home/tc/
Then I made sudo filetool.sh -b to store it.

If I do now:
tc@pCpCorina:~$ sudo ./relay.sh

I have got this:
sudo: ./relay.sh: command not found


Is there a resent change in 1.22 that this is no longer working?:confused:
 
Thanks, this was a thing, and its working now. But I cant get it to autostart after a reboot. Can you help me again?
 
Call it from bootlocal

vi /opt/bootlocal.sh
and add sudo /home/tc/relay.sh > /dev/null &

Dont forget to backup or it will dissappear on reboot.
Sudo Filetool.sh -b
 
@ Bemused, Thanks for your answer.
But we don't install gpio, python?... any labruary else?
What the name of this script? it's relay.sh?
 
You shouldn't need to install anything, name the script what you wish, in this thread we called the various scripts "relay" so relay.sh.
Just create the script with VI, nano or whatever you use, make it executable and call it on startup.

If you're new to this then read this thread starting from page 1 and see how I learned. Make a post If you stumble along the way.

Tony
 
Bemused,
I am looking for all thread and I come back to you if I have a problem.

In this script there is no debug part; could I integer debug part of the first script in this?

Eric
 
Yes I see no reason why you can't integrate the debug part.
Or just manually add the echoes you need for testing and delete or remark them out when your happy with the function.
 
Hello Bemused,
In fact it is quite simple to install this script.
BUT with putty I see "play" and "stop" but nothing in my loud-speakers.
I don't see why.
An idea?
 


advertisement


Back
Top