mirror of https://github.com/ARMmbed/mbed-os.git
STM32 : Sunday value is different for STM32F1
parent
2a824a1ceb
commit
e455d74f3d
|
@ -250,8 +250,8 @@ void rtc_write(time_t t)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Fill RTC structures
|
// Fill RTC structures
|
||||||
if (timeinfo.tm_wday == 0) {
|
if (timeinfo.tm_wday == 0) { /* Sunday specific case */
|
||||||
dateStruct.WeekDay = 7;
|
dateStruct.WeekDay = RTC_WEEKDAY_SUNDAY;
|
||||||
} else {
|
} else {
|
||||||
dateStruct.WeekDay = timeinfo.tm_wday;
|
dateStruct.WeekDay = timeinfo.tm_wday;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue