Update main.c SSTV if I2C fail show zero batt voltage

master-psag-fm-only-fsk
Alan Johnston 2 weeks ago committed by GitHub
parent e70b24e360
commit 274e90de22
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -1140,7 +1140,10 @@ int main(int argc, char * argv[]) {
else
fprintf(fp, "BAT %4.2fV %4.0fmA C\n", batteryVoltage, batteryCurrent); // show command and control is on
*/
fprintf(fp, "BAT %.2fV %.0fmA", batteryVoltage, batteryCurrent);
if (failureMode == FAIL_I2C1)
fprintf(fp, "BAT %.2fV %.0fmA", batteryVoltage, batteryCurrent);
else
fprintf(fp, "BAT %.2fV %.0fmA", 0.0, 0.0);
if (c2cStatus != DISABLED)
fprintf(fp," C");
if (sim_mode || (failureMode != FAIL_NONE))

Loading…
Cancel
Save

Powered by TurnKey Linux.