Skip to content

Commit c041805

Browse files
mmahadevan108Arto Kinnunen
authored and
Arto Kinnunen
committed
MIMXRT1050: Update for deep sleep latency
1. Do not disable and enable osillators during deep sleep entry and exit 2. Increase the deep sleep to pass tests Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
1 parent ba554b5 commit c041805

File tree

2 files changed

+1
-19
lines changed
  • targets

2 files changed

+1
-19
lines changed

targets/TARGET_NXP/TARGET_MCUXpresso_MCUS/TARGET_MIMXRT1050/TARGET_EVK/lpm.c

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -132,32 +132,14 @@ void CLOCK_SET_DIV(clock_div_t divider, uint32_t value)
132132

133133
void ClockSelectXtalOsc(void)
134134
{
135-
/* Enable XTAL 24MHz clock source. */
136-
CLOCK_InitExternalClk(0);
137-
/* Wait CCM operation finishes */
138-
CLOCK_CCM_HANDSHAKE_WAIT();
139-
/* Take some delay */
140-
SDK_DelayAtLeastUs(40);
141135
/* Switch clock source to external OSC. */
142136
CLOCK_SwitchOsc(kCLOCK_XtalOsc);
143-
/* Turn off XTAL-OSC detector */
144-
CCM_ANALOG->MISC0_CLR = CCM_ANALOG_MISC0_OSC_XTALOK_EN_MASK;
145-
/* Power Down internal RC. */
146-
CLOCK_DeinitRcOsc24M();
147137
}
148138

149139
void ClockSelectRcOsc(void)
150140
{
151-
/* Enable internal RC. */
152-
XTALOSC24M->LOWPWR_CTRL |= XTALOSC24M_LOWPWR_CTRL_RC_OSC_EN_MASK;
153-
/* Wait CCM operation finishes */
154-
CLOCK_CCM_HANDSHAKE_WAIT();
155-
/* Take some delay */
156-
SDK_DelayAtLeastUs(4000);
157141
/* Switch clock source to internal RC. */
158142
XTALOSC24M->LOWPWR_CTRL_SET = XTALOSC24M_LOWPWR_CTRL_SET_OSC_SEL_MASK;
159-
/* Disable XTAL 24MHz clock source. */
160-
CCM_ANALOG->MISC0_SET = CCM_ANALOG_MISC0_XTAL_24M_PWD_MASK;
161143
}
162144

163145
void LPM_SetRunModeConfig(void)

targets/targets.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1955,7 +1955,7 @@
19551955
"device_name": "MIMXRT1052",
19561956
"bootloader_supported": true,
19571957
"overrides": {
1958-
"deep-sleep-latency": 5,
1958+
"deep-sleep-latency": 10,
19591959
"network-default-interface-type": "ETHERNET"
19601960
}
19611961
},

0 commit comments

Comments
 (0)