comparison Discovery/Src/tMenuEditSystem.c @ 671:b456be1e152d Betatest

Support of unknown charging counter values: The RTE now provides negativ charge counter values in case the counter value has not yet been confirmed by a completed charge cycle. Some condition checks needed to be updated to be compatible with the usage of negativ values.
author Ideenmodellierer
date Sat, 12 Mar 2022 22:58:22 +0100
parents 16833cd3a2f5
children 4f70155362d2
comparison
equal deleted inserted replaced
670:7a352b449055 671:b456be1e152d
1079 text[2] = 0; 1079 text[2] = 0;
1080 write_field_button(StMSYS5_SetSampleIndx, 30, 800, ME_Y_LINE3, &FontT48, text); 1080 write_field_button(StMSYS5_SetSampleIndx, 30, 800, ME_Y_LINE3, &FontT48, text);
1081 #endif 1081 #endif
1082 1082
1083 1083
1084 if(stateRealGetPointer()->lifeData.battery_charge == 0) 1084 if(stateRealGetPointer()->lifeData.battery_charge <= 0)
1085 { 1085 {
1086 text[0] = TXT_2BYTE; 1086 text[0] = TXT_2BYTE;
1087 text[1] = TXT2BYTE_SetBatteryCharge; 1087 text[1] = TXT2BYTE_SetBatteryCharge;
1088 text[2] = 0; 1088 text[2] = 0;
1089 snprintf(&text[2],10,": %u%%",settingsGetPointer()->lastKnownBatteryPercentage); 1089 snprintf(&text[2],10,": %u%%",settingsGetPointer()->lastKnownBatteryPercentage);