I have a Homematic HM-ES-PMSw1-Pl and use it for an electrical towel-heating (i use OH2).
Because of safety reasons, i would like to use the ON_TIME Datapoint.
For example when the ON-Command is received and later, because of any error, the OFF won’t reach the device. With ON_TIME i am sure the heating will stop after a timout.
My Items:
Number wohnzSk_phy_onTime “SK ON_TIME [%d s]” { channel=“homematic:HM-ES-PMSw1-Pl:ccu:NEQ040xxxx:1#ON_TIME”, forceUpdate=“true” }
First time it works…the device is just for 40s or whatever on and then switches off without a command from OH.After that i HAVE TO send 1 OFF command (i know its already off but otherwise it wont work) before i can turn it on again with an ON-Command. This is exactly what i want. But this last ON command (and all the following tries) seems to work without ON_TIME (no blinking LED, no automatic switching after time).
Maybe anyone has ideas?
And how i can use this AUTOMATIC ON TIME channel (i found no syntax or example).
The ON_TIME is a special datapoint that must always be sent before the ON command. You have to set forceUpdate in the channel configuration.
forceUpdate=“true” does not work in the items file, currently only in PaperUI. I think it’s possible to configure it in the things file, but i don’t know how.
But you can user the ON_TIME_AUTOMATIC datapoint. Each device with a ON_TIME datapoint also has a ON_TIME_AUTOMATIC.
Hello Gerhard and thank you for your help.
Today i changed following code based on your tipps:
I added 1 Item:
Number wohnzSk_phy_onTimeAutomatic “ON_TIME_AUTOMATIC” { channel=“homematic:HM-ES-PMSw1-Pl:ccu:NEQ040yyyy:1#ON_TIME_AUTOMATIC”} //really channel 1?
And within my rule with the “System started” Trigger I added following 2 lines (these lines are executed just once at bootup, arent they?):
wohnzSk_phy_onTimeAutomatic.sendCommand(ON)
wohnzSk_phy_onTime.sendCommand(30)
And now I also dont send the ONTIME anymore within the SWITCH-ON-RULe, except once at systemStarted (like you see above.)
So my new “SWITCH-ON-RULE” looks like:
wohnzSk_phy_state.sendCommand(ON)
INFO&Question: I have multiple different “System started” rules over my *.rules files…i hope thats no probleme…maybe just ONE such rule is allowed within the whole OH2 program?
And within paperui i enabled(will enable soon) the forceUpdate option at channel:
“homematic:HM-ES-PMSw1-Pl:ccu:NEQ040xxxx:1#ON_TIME” and also removed this option again within my ITEMS-File.
I will test these changes maybe on saturday because know i dont have a ccu anymore (i sent it back yesterday because it lost its teached devices 2 times within the last 2 weeks :-/)
So when i get the new one i will report fail or success the next days.
Thank you again very much for your help…cu
hmmm…dont know why but the new code alsoe does not work.
its nearly the same as when i am using ONTIME.
It works at the beginning (once…i see it at the blinking led and the devices switches off) und after that never again (no blinking, so the device stays ON).
As you said I send the value for onTimeAutomatic once at SystemStart and after that I only send ON and OFF commands…nothing more.
Within homematic i did nothing with the device settings (so its set to OnOff-switch without any times = default).