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 f945ab8 commit 66ceabdCopy full SHA for 66ceabd
src/rp2_common/hardware_rtc/rtc.c
@@ -183,9 +183,9 @@ bool rtc_set_alarm(const datetime_t *t, rtc_callback_t user_callback) {
183
if (t->sec >= 0) s1 |= RTC_IRQ_SETUP_1_SEC_ENA_BITS | (((uint)t->sec) << RTC_IRQ_SETUP_1_SEC_LSB);
184
else if (_alarm_repeats == CONTINUOUS_REPEAT_ON_SEC) {
185
// repeatable every second! All entries are -1
186
- datetime_t tNew;
187
- rtc_get_datetime(&tNew);
188
- s1 = RTC_IRQ_SETUP_1_SEC_ENA_BITS | ((((uint)tNew.sec + 1) % 60) << RTC_IRQ_SETUP_1_SEC_LSB);
+ datetime_t new_dt;
+ rtc_get_datetime(&new_dt);
+ s1 = RTC_IRQ_SETUP_1_SEC_ENA_BITS | ((((uint)new_dt.sec + 1) % 60) << RTC_IRQ_SETUP_1_SEC_LSB);
189
}
190
191
rtc_hw->irq_setup_0 = s0;
0 commit comments