30.12.2019, 14:04
(28.12.2019, 19:08)Tokatubs Wrote:(28.12.2019, 15:00)Auzzii Wrote: Hello,
what is best way to make virtual object for time input for scada. I need it to be 08:00 instead of 8:0 (image in attachment)
Tnx,Post as resident script. Then modify adresses as you choose. Then time is 10. 3 byte and date is 11. 3 byte.Code:-- get current data as table now = os.date('*t') -- system week day starts from sunday, convert it to knx format wday = now.wday == 1 and 7 or now.wday - 1 -- time table time = { day = wday, hour = now.hour, minute = now.min, second = now.sec, } -- date table date = { day = now.day, month = now.month, year = now.year, } -- write to bus grp.write('9/0/8', time, dt.time) grp.write('9/0/9', date, dt.date)
Hi, i have no problem with script.
But user input in scada. In one fild user want input hours from 00 to 24 and in other minutes 00 to 60.
Tnx