boblemaire / IoTaWatt

IoTaWatt Open WiFi Electric Energy Monitor
https://iotawatt.com
GNU General Public License v3.0
639 stars 177 forks source link

Second IotaWatt added, first looses all configuration #335

Closed lyricnz closed 1 year ago

lyricnz commented 1 year ago

I had an Iotawatt setup with default device-name, and had configured the inputs etc, and it was all working fine.

I bought a second device, configured the wifi, and the first unit appears to have lost all it's input settings (inputs, calibration, etc). Yes, I guess there was some kind of clash on iotawatt.local? It looks like the saved data is there - once I recreated all the inputs, I can see the old data.

Any idea what happened? This seems like a case where it would be useful to be able to export/import settings for safe storage.

boblemaire commented 1 year ago

You can download the config.txt with the file manager. If you want to upload it again, rename it to config+1.txt.

When you have two IoTaWatt by the same name, there is the possibility that the browser app loaded the default config from one and then subsequently uploaded it to the other. There are a lot of variables that would determine how iotawatt.local is resolved at any specific time. Hopefully you have renamed one of them and this will not be an ongoing problem.

lyricnz commented 1 year ago

Is there any way to detect if there's an existing iotawatt.local before the new device is registered with that name? Then it could add unique suffix etc

lyricnz commented 1 year ago

FWIW I have renamed both of them, so if I ever add a third, I won't experience this.