Release 1.01
Diff: Menu.cpp
- Revision:
- 8:9d4e684d8eb8
- Parent:
- 7:d8673bb9fb6f
diff -r d8673bb9fb6f -r 9d4e684d8eb8 Menu.cpp --- a/Menu.cpp Fri Sep 27 13:20:32 2019 +0000 +++ b/Menu.cpp Tue Mar 17 17:23:15 2020 +0000 @@ -243,10 +243,8 @@ /******************************************************************************/ void Menu::displayVersion (LCD * lcd) { - - lcd->locate(3,35); - lcd->printf("v1.01"); + lcd->printf("v1.02"); } /******************************************************************************/ void Menu::displayCurrentTime (LCD * lcd) @@ -267,8 +265,33 @@ cur_month = timeinfo->tm_mon + 1; cur_day = timeinfo->tm_mday; +#if 1 + + if ( cur_hours < 12 ) { + + cur_hours = (cur_hours == 0) ? 12 : cur_hours; + lcd->locate(0,20); + lcd->printf(" %02d:%02d:%02dam %02d/%02d/%02d", + cur_hours, cur_mins, cur_secs, cur_month, cur_day, (cur_year%100)); + + } else { + + cur_hours = (cur_hours - 12); + cur_hours = (cur_hours == 0) ? 12 : cur_hours; + lcd->locate(0,20); + lcd->printf(" %02d:%02d:%02dpm %02d/%02d/%02d", + cur_hours, cur_mins, cur_secs, cur_month, cur_day, (cur_year%100)); + + + } + +#else + lcd->locate(0,20); - lcd->printf(" %02d:%02d:%02d %02d/%02d/%04d", cur_hours, cur_mins, cur_secs, cur_month, cur_day, cur_year); + lcd->printf(" %02d:%02d:%02d %02d/%02d/%04d", + cur_hours, cur_mins, cur_secs, cur_month, cur_day, cur_year); + +#endif lcd->locate(1,33); lcd->printf("Addr=%02d",escmController.cur_address);