Hi, i am hoping someone can help me create a button that can send a json string to tasmota power strip that will set the timer at a time set by input_datetime.
i can publish this string: {“Enable”:1,“Time”:“01:00”,“Window”:0,“Days”:"-------",“Repeat”:1,“Output”:2,“Action”:1}
and the timer is activated at 04.00, however if i try: {“Enable”:1,“Time”:"( states(“input_datetime.timer_2_on”, “timestamp”) | timestamp_custom("%H.%M", False) )",“Window”:0,“Days”:"-------",“Repeat”:1,“Output”:2,“Action”:1}
or
{“Enable”:1,“Time”:"{{ state_attr(“input_datetime.timer_1_off”, “timestamp”) | timestamp_custom("%H.%M", False) }}",“Window”:0,“Days”:"-------",“Repeat”:1,“Output”:1,“Action”:0}
i get an invalid json error, i am guessing i will need to create a sensor that inserts the time into the json string then somehow send that sensor state.
can anybody point me in the right direction to make this happen? the idea is the tasmota timers retain function if the network is down so i perform automations with HA and set basic failsafe timers to ensure lights are off at the critical times.