Update payload_pico.ino

pull/277/head
Alan Johnston 2 years ago committed by GitHub
parent bad10309e1
commit fdc7a85f7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1864,18 +1864,18 @@ void read_config() {
Serial.println("Reading config file");
char buff[32];
File mode_file = LittleFS.open("/config.txt", "r");
if (!mode_file) {
write_mode(mode);
} else {
if (mode_file.read((uint8_t *)buff, 31)) {
// if (!mode_file) {
// write_mode(mode);
// } else {
// if (mode_file.read((uint8_t *)buff, 31)) {
// Serial.println("Reading mode from .mode file");
sscanf(buff, "%d", &mode);
mode_file.close();
// Serial.print("Mode is ");
// Serial.print(mode);
}
}
// }
//}
}
void write_config(int save_mode) {

Loading…
Cancel
Save

Powered by TurnKey Linux.