imx233: add HW_RTC_CTRL and HW_RTC_STAT registers to debug screen

Change-Id: Id52f86b26ee039781f44fde639fb8f184c7dc438
This commit is contained in:
Sebastian Leonhardt 2025-11-24 22:15:59 +01:00
parent c43919352d
commit 69bc230e7d
3 changed files with 6 additions and 1 deletions

View file

@ -542,7 +542,8 @@ bool dbg_hw_info_rtc(void)
lcd_putsf(0, line++, "alarm: %lu", info.alarm);
for(int i = 0; i < 6; i++)
lcd_putsf(0, line++, "persist%d: 0x%lx", i, info.persistent[i]);
lcd_putsf(0, line++, "rtc_ctrl: 0x%lx", info.rtc_ctrl);
lcd_putsf(0, line++, "rtc_stat: 0x%lx", info.rtc_stat);
lcd_update();
yield();
}

View file

@ -55,5 +55,7 @@ struct imx233_rtc_info_t imx233_rtc_get_info(void)
info.alarm_wake_en = BF_RD(RTC_PERSISTENT0, ALARM_WAKE_EN);
info.alarm_wake = BF_RD(RTC_PERSISTENT0, ALARM_WAKE);
info.alarm_irq = BF_RD(RTC_CTRL, ALARM_IRQ);
info.rtc_ctrl = HW_RTC_CTRL;
info.rtc_stat = HW_RTC_STAT;
return info;
}

View file

@ -34,6 +34,8 @@ struct imx233_rtc_info_t
uint32_t seconds;
uint32_t persistent[6];
uint32_t alarm;
uint32_t rtc_ctrl;
uint32_t rtc_stat;
bool alarm_en, alarm_wake_en, alarm_wake, alarm_irq;
};