Turn on the screen when an item changes

On a mini PC I have Openhabian 2.5M1 running.
On a Raspberry Pi3 I have a touch screen on the Habpanel in the browser running in full screen.
Of course, the screen goes into standby mode after 10 minutes, it should also.
Now I’d like to, if the value of an item changes, (certain value) that the screen wakes up from standby mode.

Is this possible? And if so, can someone please give me a hint.

Yes it is possible.
There is a WOL binding in openHAB. https://www.openhab.org/addons/bindings/wol1/

You have to configure the WOL Binding and make a Rules File with a If condition.

Ah ok.
I will try it out tonight.
Many thanks

Can you give an example if this one… I fail to understand how WOL can wake a screensaver, which is what Oliver is referering to as far as I understand.

I think that with the command “turn on” also the screen goes on.
I will test it tonight

Please let us know the outcome…I have been searching for something like that as well. I would never have thought WOL would work though. (it´s not its main purpose).

You can also provide wol with an exec command.
In case of doubt, that may work.

I share the result.

I know… But “turning on” a device (computer) with WOL, which is already turned on, normally doesnt make sense. I would be alittle surprised if it would turn off the screensaver. I have never tried though… So I look forward to your outcome :slight_smile:

There is a Linux Package called Screensaver.
If you make the WOL with the Screensaver Command it could be your solution…

My knowlegde in Linux is very limited. I´ll need amore complete guide as to how :slight_smile:

Did you test it?

Is an HDMI screen? If so and if is CEC compatible you can install the cec-client package on the rpi and issue the command to wake up the screen .

No, unfortunately not.
have solved it now with php and sendHttpGetRequest

Are they configured properly??

What exactly do you mean?
This is great with PHP.

Can you post your source code?

First I looked for the command to turn on the monitor:

/ opt / vc / bintvservice -p; sudo / bin / chvt 6; sudo / bin / chvt 7

Then I made an executable (.sh) file out of it

#! / Bin / bash
/ opt / vc / bintvservice -p; sudo / bin / chvt 6; sudo / bin / chvt 7

Finally, create a php file that executes this file.

<? Php shell: exec ( "/ usr / local / bin / datei.sh"); ?>

The rule from Openhab is:

rule “doorhttp”
When
Item Door changed
then
sendHttpGetRequest ( “http://192.xxx.xxx.xxx/panelon.php?param=”)
end

regards
Oliver

3 Likes