popravek tasmote

master
Jure Podgorše 2023-06-06 13:26:26 +02:00
parent 959f21359c
commit fa47ab8757
1 changed files with 3 additions and 3 deletions

View File

@ -24,7 +24,7 @@ end
# payload = kako dolgo naj bo vklopljen, v milisekundah
def pojdi_levo(cmd, idx, payload, payload_json)
if zadnji > tasmota.millis() + cakaj end
if tasmota.millis() < zadnji + cakaj return nil end
tasmota.set_power(0, true)
@ -37,7 +37,7 @@ end
# payload = kako dolgo naj bo vklopljen, v milisekundah
def pojdi_desno(cmd, idx, payload, payload_json)
if zadnji > tasmota.millis() + cakaj end
if tasmota.millis() < zadnji + cakaj return nil end
tasmota.set_power(1, true)
@ -54,7 +54,7 @@ end
# payload = kako dolgo naj bo vklopljen, v milisekundah
def pojdi_ravno(cmd, idx, payload, payload_json)
if zadnji > tasmota.millis() + cakaj end
if tasmota.millis() < zadnji + cakaj return nil end
tasmota.set_power(0, true)
tasmota.set_power(1, true)