Code : Tout sélectionner
commandArray = {}
time = os.date("*t")
owl, total = otherdevices_svalues['cm180']:match("([^;]+);([^;]+)")
owl = tonumber(owl)
if devicechanged['cm180'] then
if (((time.hour > 1) and (time.hour < 7)) or ((time.hour > 11) and (time.hour < 13))) then
commandArray['UpdateDevice'] = '178|0|' .. owl
else
commandArray['UpdateDevice'] = '177|0|' .. owl
end
end
return commandArrayavez vous vu quelque chose qui fait la même chose et qui marche