10.10.2022, 06:25
Next firmware will have an option to hide day and/or seconds for data type 10 (3 byte time / day).
Dré's script is correct. string.format supports multiple arguments so the script can be shorter. There's no different in using single or double quotes in Lua.
Dré's script is correct. string.format supports multiple arguments so the script can be shorter. There's no different in using single or double quotes in Lua.
Code:
value = event.getvalue()
time = string.format('%d:%02d:%02d', value.hour, value.min, value.sec)
log(time)