Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The i.MX 8M Mini processor contains a real time clocks (RTC), which is located in the low-power domain of the internal SNVS module. The internal RTC is available as rtc1 in Linux, however it is not used by default. In order to reduce retention power consumption the i.MX 8M Mini based modules use an external persistent time source - RTC chip STM M41T62, which is common with other congatec i.MX 8 designs. The external RTC is available as rtc0 in Linux.

In the Linux environment the RTC can be read and set using the hwclock utility (see the following examples)

Set current date and write into the default RTC

Code Block
languagebash
$ date -s "Thu Jan 31 14:09:00 2019"
$ hwclock -w

Check the current date

Code Block
languagebash
$ hwclock
Tue Jun 18 11:09:18 2019  0.000000 seconds