We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3ada760 commit 2970c50Copy full SHA for 2970c50
cores/nRF5/freertos/portable/CMSIS/nrf52/port_cmsis_systick.c
@@ -182,6 +182,13 @@ void vPortSuppressTicksAndSleep( TickType_t xExpectedIdleTime )
182
configPRE_SLEEP_PROCESSING( xModifiableIdleTime );
183
if ( xModifiableIdleTime > 0 )
184
{
185
+#if (__FPU_USED == 1)
186
+ // nRF52832 errata 87: prevent FPU from keeping CPU on
187
+ // https://infocenter.nordicsemi.com/topic/errata_nRF52832_Rev2/ERR/nRF52832/Rev2/latest/anomaly_832_87.html?cp=4_2_1_0_1_24
188
+ __set_FPSCR(__get_FPSCR() & ~(0x0000009F));
189
+ (void) __get_FPSCR();
190
+ NVIC_ClearPendingIRQ(FPU_IRQn);
191
+#endif
192
#ifdef SOFTDEVICE_PRESENT // TODO
193
uint8_t sd_en = 0;
194
(void) sd_softdevice_is_enabled(&sd_en);
0 commit comments