Time synchronization through serial cable. is it possible?

Hello,
we are using a Verdin iMX8M Mini on custom carrier board, TorizonCore v5.7.0
We have removed a supercapacitor connected to VCC_BACKUP and which was used to power the RTC.
We have disconnected the Ethernet port and rely exclusively on the cellular modem connection on our custom board as network connection.
We have connected a serial cable to login into the unit.

With this configuration we would expect that when we switch off the power, the RTC will lose the correct timestamp and it will synchronize the clock via ntp service when the modem connection is fully up, which it could take few minutes.

But as soon as we login into the unit the timestamp is already correct, even if the modem is not up!
is it possible that the timer synchronization is occurring via the serial cable? there could be other sources of synchronization? is there a way to check the source?

Regards,
Rocco

Greetings @RoccoBr,

But as soon as we login into the unit the timestamp is already correct, even if the modem is not up!

If I understand everything correctly, the system time was somehow set correctly on boot, despite the RTC not being powered, and no network connection to synchronize off of.

If that’s the case that certainly does sound puzzling. Referencing our RTC documentation: Real-Time Clock / RTC (Linux) | Toradex Developer Center

There are a number of time synchronization services present in our BSP. There is systemd-timesyncd which synchronizes system time with the network, then there’s systemd-timedated which synchronizes the system time back to the RTC. Perhaps you can check the logs for these services to see if there’s any clues. Also can you confirm that somehow no previous time is being stored in the RTC somehow?

is it possible that the timer synchronization is occurring via the serial cable?

As far as I’m aware this shouldn’t be happening.

there could be other sources of synchronization? is there a way to check the source?

As seen in the RTC article I referenced running timedatectl, will show whether network time synchronization is active or not, you could also disable this network synchronization to remove any doubts. Other than the network and RTC there shouldn’t be any other sources of time synchronization configured.

Best Regards,
Jeremias

Hello @RoccoBr,

Do you have any updates on this topic? Have you been able to check the logs from the services that @jeremias.tx pointed out?

hi @rudhi.tx we are still investigating