feat(ui): show real weekday/day/month on HOME screen instead of placeholder
UI_ShowClockPage()/UI_ShowSetTimePage() now take weekday/day/month(/year) and build the date bar dynamically via Build_DateString() instead of the fixed placeholder string. app_home.c reads the full date from RTC via PCF8563_ReadDateTime() and recalculates weekday since the RTC's stored date may differ from the software clock's. config.h exposes current_day/month/year/weekday alongside the existing time fields so main.c's debug commands don't need a separate include.
This commit is contained in:
@@ -141,6 +141,10 @@ extern SystemState current_state; // 系统当前整体运行状态
|
||||
extern u8 current_hour; // 当前系统时间:小时
|
||||
extern u8 current_min; // 当前系统时间:分钟
|
||||
extern u8 current_sec; // 当前系统时间:秒
|
||||
extern u8 current_day; // 当前系统日期:日
|
||||
extern u8 current_month; // 当前系统日期:月
|
||||
extern u8 current_year; // 当前系统日期:年 (0~99,代表 2000~2099)
|
||||
extern u8 current_weekday; // 当前系统日期:星期 (0=周日, ..., 6=周六)
|
||||
extern volatile u8 clock_updated; // 时钟分钟更新标志 (1表示需要刷新待机页时间)
|
||||
extern volatile bit second_tick_flag; // 整秒滴答标志位,每秒置 1,由主循环转换为 KEY_EVENT_SECOND_TICK 事件
|
||||
|
||||
|
||||
Reference in New Issue
Block a user