diff options
Diffstat (limited to 'testhal/STM32F1xx')
-rw-r--r-- | testhal/STM32F1xx/RTC/main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/testhal/STM32F1xx/RTC/main.c b/testhal/STM32F1xx/RTC/main.c index ea7155f47..19043a02a 100644 --- a/testhal/STM32F1xx/RTC/main.c +++ b/testhal/STM32F1xx/RTC/main.c @@ -24,7 +24,7 @@ RTCTime timespec;
RTCAlarm alarmspec;
-#define TEST_ALARM_WAKEUP FALSE
+#define TEST_ALARM_WAKEUP TRUE
#if TEST_ALARM_WAKEUP
@@ -45,9 +45,9 @@ int main(void) { chThdCreateStatic(blinkWA, sizeof(blinkWA), NORMALPRIO, blink_thd, NULL);
/* set alarm in near future */
- rtcGetTime(×pec);
+ rtcGetTime(&RTCD1, ×pec);
alarmspec.tv_sec = timespec.tv_sec + 60;
- rtcSetAlarm(&alarmspec);
+ rtcSetAlarm(&RTCD1, 0, &alarmspec);
while (TRUE){
chThdSleepSeconds(10);
|