OS Execute
Posted: Thursday 21 May 2020 21:03
Hello - I try to figure out the following
I have a Ilyama Touchscreen in the kitchen on which I Dashticz visualisize - but if nobody is home - I switch off the screen with tvservice -o
With DZevent I run (on motion in the kitchen) the script which enables the touchscreen with tvservice -p - screen turns on but stays black.
on ssh command I run DISPLAY=:0 xdotool mousemove 100 100 2 times and this works - now I add these commend in the Dzevent script as a screenon.sh bas script and as wel as stand alone os.execute lines - but both ways doesn't work. When I start the bash script with blocky I get the 256 error, by adding > /dev/null 2>&1 & the error disapears but still doesn't work
Is there someone who can help me? bash script works on ssh command
bash script
dzevents

Thank you in advance for your help and support
Peter
I have a Ilyama Touchscreen in the kitchen on which I Dashticz visualisize - but if nobody is home - I switch off the screen with tvservice -o
With DZevent I run (on motion in the kitchen) the script which enables the touchscreen with tvservice -p - screen turns on but stays black.
on ssh command I run DISPLAY=:0 xdotool mousemove 100 100 2 times and this works - now I add these commend in the Dzevent script as a screenon.sh bas script and as wel as stand alone os.execute lines - but both ways doesn't work. When I start the bash script with blocky I get the 256 error, by adding > /dev/null 2>&1 & the error disapears but still doesn't work

bash script
Code: Select all
#!/bin/bash
#Touchscreen Off
tvservice -p
sleep 5
DISPLAY=:0 xdotool mousemove 10 100
sleep 3
DISPLAY=:0 xdotool mousemove_relative 10 100
Code: Select all
return {
on = {
devices = {
'SimMuis'
}
},
execute = function(domoticz, device)
os.execute("/home/pi/domoticz/scripts/bash-on.sh")
end
}

Thank you in advance for your help and support
Peter