reset sonde info if configuration is changed (corrected), version update

pull/153/head^2
Hansi, dl9rdz 2021-09-05 17:10:18 +02:00
rodzic b807c512e3
commit 4755c0ffca
2 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -1,4 +1,4 @@
const char *version_name = "rdzTTGOsonde";
const char *version_id = "devel20210817";
const char *version_id = "devel20210905";
const int SPIFFS_MAJOR=2;
const int SPIFFS_MINOR=14;

Wyświetl plik

@ -453,8 +453,8 @@ void Sonde::addSonde(float frequency, SondeType type, int active, char *launchsi
}
Serial.printf("Adding %f - %d - %d - %s\n", frequency, type, active, launchsite);
// reset all data if type or frequency has changed
if(type != sondeList[nSonde].type || frequency != sondeList[nSonde].frequency) {
memset(sondeList[nSonde], 0, sizeof(SondeInfo));
if(type != sondeList[nSonde].type || frequency != sondeList[nSonde].freq) {
memset(&sondeList[nSonde], 0, sizeof(SondeInfo));
}
sondeList[nSonde].type = type;
sondeList[nSonde].typestr[0] = 0;