Merge pull request #13570 from kaspar030/ztimer_allow_adjust_config
sys/ztimer: allow "adjust" config for ztimer_usec, ztimer_msec
This commit is contained in:
commit
c2f9700f5e
@ -155,6 +155,11 @@ void ztimer_init(void)
|
|||||||
FREQ_1MHZ, CONFIG_ZTIMER_USEC_FREQ);
|
FREQ_1MHZ, CONFIG_ZTIMER_USEC_FREQ);
|
||||||
# endif
|
# endif
|
||||||
# endif
|
# endif
|
||||||
|
# ifdef CONFIG_ZTIMER_USEC_ADJUST
|
||||||
|
LOG_DEBUG("ztimer_init(): ZTIMER_USEC setting adjust value to %i\n",
|
||||||
|
CONFIG_ZTIMER_USEC_ADJUST);
|
||||||
|
ZTIMER_USEC->adjust = CONFIG_ZTIMER_USEC_ADJUST;
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef ZTIMER_RTT_INIT
|
#ifdef ZTIMER_RTT_INIT
|
||||||
@ -170,5 +175,10 @@ void ztimer_init(void)
|
|||||||
ZTIMER_MSEC_CONVERT_LOWER,
|
ZTIMER_MSEC_CONVERT_LOWER,
|
||||||
FREQ_1KHZ, ZTIMER_MSEC_CONVERT_LOWER_FREQ);
|
FREQ_1KHZ, ZTIMER_MSEC_CONVERT_LOWER_FREQ);
|
||||||
# endif
|
# endif
|
||||||
|
# ifdef CONFIG_ZTIMER_MSEC_ADJUST
|
||||||
|
LOG_DEBUG("ztimer_init(): ZTIMER_MSEC setting adjust value to %i\n",
|
||||||
|
CONFIG_ZTIMER_MSEC_ADJUST);
|
||||||
|
ZTIMER_MSEC->adjust = CONFIG_ZTIMER_MSEC_ADJUST;
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user