I'm running an i.MX RT1170 series processor for a GUI application. The application happens to display a clock. I've noticed that the time I'm displaying lags behind my PC (connected to the internet) by around 6 seconds per day.
I've tried to enter a calibration value to adjust for this drift, but it appears that it's not being applied. Below is my initialization code for the RTC module:
/* High power module */
snvs_hp_rtc_config_t rtcConfig;
SNVS_HP_RTC_GetDefaultConfig(&rtcConfig);
rtcConfig.rtcCalValue = 0xf; // +15 counts per each 32768 ticks of the counter
rtcConfig.rtcCalEnable = true; // enable RTC calibration
SNVS_HP_RTC_Init(SNVS, &rtcConfig);
SNVS_HP_RTC_StartTimer(SNVS);
/* Coin-cell powered low power module */
...
/* Synchronize RTC time and date with SRTC */
SNVS_HP_RTC_TimeSynchronize(SNVS);
...
Originally we calculated the calibration value to be +2 counts per 32768 ticks of the counter:
6 seconds behind = missing approximately 6s* 32768 ticks/s = missing approximately 196608 ticks
196608 ticks / (seconds per day) = 196608 ticks / (24hr/day * 60min/hr * 60s/min) = 2.275 ticks/s
Therefore every second and additional 2 counts need to be added to the RTC counter. After adding this it appeared to have no change. So I changed the value to +15 counts per 32768 ticks of the counter to see if I can notice a difference. Once again I can't see a change.
Is the code snippet above the appropriate way to use the RTC calibration value?

Here's what the processor's reference manual says on the subject.