Fix static IP EEPROM save

This commit is contained in:
Mathieu Maret 2019-06-03 00:05:21 +02:00
parent 850391ccce
commit ac6ab8969c
2 changed files with 6 additions and 7 deletions

View File

@ -15,7 +15,7 @@ typedef struct productConfig_t {
uint32_t mask;
uint32_t dns;
uint32_t dns2;
int32_t channel;
uint8_t channel;
char *bssid;
} productConfig;
@ -23,4 +23,3 @@ typedef struct productConfig_t {
int EepromSaveConfig(productConfig &config);
int EepromSaveBootMode(uint8_t bootMode);
void EepromReadConfig(productConfig &config);

View File

@ -87,15 +87,15 @@ void EepromReadConfig(productConfig &config) {
readConfElement(&tmpString, i);
config.ip_mode = atoi(tmpString);
readConfElement(&tmpString, i);
config.ip = atoi(tmpString);
config.ip = atoll(tmpString);
readConfElement(&tmpString, i);
config.gw = atoi(tmpString);
config.gw = atoll(tmpString);
readConfElement(&tmpString, i);
config.mask = atoi(tmpString);
config.mask = atoll(tmpString);
readConfElement(&tmpString, i);
config.dns = atoi(tmpString);
config.dns = atoll(tmpString);
readConfElement(&tmpString, i);
config.dns2 = atoi(tmpString);
config.dns2 = atoll(tmpString);
readConfElement(&tmpString, i);
config.channel = atoi(tmpString);
readConfElement(&config.bssid, i);