kopia lustrzana https://github.com/micropython/micropython
ports: mimxrt: Fix SNVS_LP build on non-RT1176 devices.
The SDK updates includes a breaking change on devices without valid external tamper support. This is done by adding a macro checking whether the `FSL_FEATURE_SNVS_HAS_MULTIPLE_TAMPER` macro is defined and contains non-zero values in SDK driver. Currently this is only enabled on RT1176, so here we are adding the same check to prevent calling the non-exist function on other devices. Signed-off-by: Yilin Sun <yilin.sun@nxp.com>pull/13429/head
rodzic
c9d2437cc8
commit
3171c925b7
|
@ -156,8 +156,11 @@ void machine_rtc_start(void) {
|
|||
SNVS->HPCOMR |= SNVS_HPCOMR_NPSWA_EN_MASK;
|
||||
// Do a basic init.
|
||||
SNVS_LP_Init(SNVS);
|
||||
|
||||
#if defined(FSL_FEATURE_SNVS_HAS_MULTIPLE_TAMPER) && (FSL_FEATURE_SNVS_HAS_MULTIPLE_TAMPER > 0)
|
||||
// Disable all external Tamper
|
||||
SNVS_LP_DisableAllExternalTamper(SNVS);
|
||||
#endif
|
||||
|
||||
SNVS_LP_SRTC_StartTimer(SNVS);
|
||||
// If the date is not set, set it to a more recent start date,
|
||||
|
|
Ładowanie…
Reference in New Issue