NuttX offers a function clock_synchronize() that synchronizes system clock
with clock from RTC (internal or external). The synchronization is done
during board initialization and I suppose this can also be called from an
application level if required.
I think clock_synchronize() is okay for startup initialization, but would be inappropriate at run time.  That is because it could cause the current time to apparently jump backward.  That could be fatal under certain circumstances as described for adjtime() in https://github.com/apache/nuttx/issues/8858

Reply via email to