Skip to content
This repository was archived by the owner on Sep 16, 2024. It is now read-only.

Commit 9fd8921

Browse files
committed
Put RtcStopAlarm into IRAM to avoid crash when FS is being read/written and Lora IRQ interrupts it
1 parent 933b370 commit 9fd8921

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

esp32/lora/rtc-board.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ IRAM_ATTR void RtcSetAlarm( uint32_t timeout )
168168
RtcStartAlarm( timeout );
169169
}
170170

171-
void RtcStopAlarm( void )
171+
IRAM_ATTR void RtcStopAlarm( void )
172172
{
173173
RtcTimerContext.AlarmState = ALARM_STOPPED;
174174
}
@@ -246,4 +246,4 @@ static IRAM_ATTR void RtcAlarmIrq( void )
246246

247247
// NOTE: The handler should take less then 1 ms otherwise the clock shifts
248248
TimerIrqHandler( );
249-
}
249+
}

0 commit comments

Comments
 (0)