Hi,
ZUno 2 has a built-in RTC timer. It has been used since version 3.09 to get the values of micros()/millis(). The Time Parameter command class is used to set the time on the device from the controller, by default it configures the built-in RTC. In order to use the Time Parameter class, it must be enabled via ZUNO_ENABLE. The Z-Wave controller must also support this class of commands. Some controllers set the time when the device is connected to the network, some have additional items in the device menu for this. In the Z-Way controller, this functionality is located in the Expert Interface in the Expert Commands section. The built-in RTC retains its value up to and including EM4 mode. Example of using the built-in RTC:
Your example works well during integration of the Z-uno2 into the Home center 3 z-wave network,
and I see the message *** Time was updated:
But, if I unplug or reset the module, it restarts with time set to 13.04.2023 12:55:33 and I never see the message *** Time was updated:. Note that 13.04.2023 12:55:33 is may be the time when I try first ?
I am not sure who/where is the culprit between HC3 and Z-uno module...
After a reset, the z-uno module is not supposed to ask time to HC3? is there a way to do so?
Some "progress": in fact the starting time printed after reset or power on is the time of when the code was uploaded, but in GMT+0 instead of GMT+2 (after inclusion time is GMT +2).
Just to let you know: I have found a workaround that does not use Time Parameter class but more classical(?) configuration parameters to send Unix time.
It works...
Two questions:
the RTC provided time suffers from a big shift, it underestimates exact time about 1%. I have observed that among 4 Z-uno2 (and in fact it was also the case among 5 old Z-uno1).
1% sounds acceptable, but this is around 1s every 2 mn or 7 hours/month error.
Even my very old fashion pendulum clock has better perf !
May be you should remove R from 'RTC' ?
With Z-uno2, is there still an overflow issue with the RTC given time after 50days ? (50 days = 2^32 seconds)
Best Regards,
Yves
PS:My discoveries, for people interested in the subject:
The embeded RTC is not backuped in case of power loss
It restarts with T0 equal to code build time
RTC given time is late approx 1% off elapsed time since last time set
Fibaro's Home Center 3 does not seem to provide Time Parameter class parameter easily/at all
Hello, according to above.
I have a Z-Uno ver2, rel 3.0.10, controller Razzberry 7 pro on a RaspBerry 4.
With the same example as above and if z-uno power down, it will, when on again,
show the same time as set when the program where built.
************************************** VisaTiden.ino *************************************
*** Current TimeStamp: 1709118678
2024-02-28 12:11:18
*** Current TimeStamp: 1709118708
2024-02-28 12:11:48
�************************************** VisaTiden.ino *************************************
*** Current TimeStamp: 1709118678
2024-02-28 12:11:18
*** Current TimeStamp: 1709118708
2024-02-28 12:11:48
After built and monitor print, the two above, I disconnected usb from my computer and went for lunch.
When I came back, about an hour later, I connected Z-Uno to my computer and got the last print.
What can I do to be sure that the right time is shown?