tasmota / decode-config

Backup/restore and decode configuration tool for Tasmota
GNU Lesser General Public License v3.0
211 stars 32 forks source link

AdcParam doesn't seem to be saved from tasmota 13.1.0 esp32 device #93

Closed spacelama closed 1 week ago

spacelama commented 1 week ago

Describe the bug

AdcParam1 is set in my device, but the values returned by decode-config appear to be just defaults

To Reproduce

In a tasmota esp32 device, running 13.1.0, run on the console:

adcparam 6,0,1023,0,24730

Verify that adcparam returns:

15:00:56.151 CMD: adcparam
15:00:56.159 MQT: stat/batterymon1/RESULT = {"AdcParam1":[6,0,1023,0,24730]}

Run decode-config.py over your device and look for adc related params: decode-config.py --source batterymon1 | jq | grep -i adc.*param

Expected behavior

Was hoping for perhaps the array of adcparams to be returned so they restored at a later date without managing extra config out-of-band

Version Information

Please complete the following information
use decode-config.py -V --debug to retrieve the info


: 57523,12; decode-config.py -V --debug
decode-config.py v14.2.0.0 [7f0912b] by Norbert Richter nr@prsolution.eu

Script:   decode-config.py
Version:  14.2.0.0 [7f0912b]
Python:   3.11.2
Platform: Linux-6.9.7+bpo-amd64-x86_64-with-glibc2.36 - x86_64
OS:       Linux 6.9.7+bpo-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.9.7-1~bpo12+1 (2024-07-03)
Time:     2024-09-03 15:05:46

System' information of your Tasmota data

Append -g System to your decode-config parameter, e. g. decode-config.py -s myconfig.dmp -g System


: 57530,19; decode-config.py --source batterymon1 -g System
{"bootcount": 300, "bootcount_reset_time": 1694356011, "cfg_crc": "0x8926", "cfg_crc32": "0xe0ec1f6d", "cfg_holder": 4617, "cfg_size": 4096, "cfg_timestamp": 1724855595, "header": {"data": {"crc": "0x4dbe", "crc32": "0xe0ec1f6d", "hardware": "ESP82", "size": 4096, "version": {"id": "0xd010000", "name": "13.1.0"}}, "env": {"platform": "Linux-6.9.7+bpo-amd64-x86_64-with-glibc2.36", "python": "3.11.2", "script": "decode-config.py v14.2.0.0 [7f0912b]", "system": "Linux x86_64 6.9.7+bpo-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.9.7-1~bpo12+1 (2024-07-03)"}, "template": {"crc": "0x8926", "crc32": "0xe0ec1f6d", "size": 4096, "version": {"id": "0xd000002", "name": "13.0.0.2"}}, "timestamp": "2024-08-28 14:33:15"}, "version": "0xd010000"}

Additional context

Add any other context about the problem here.

curzon01 commented 1 week ago

Unfortunately, your information does not match:

tasmota esp32 device, running 13.1.0

decode-config.py --source batterymon1 -g System

"header": {
...
"data": {
...
"hardware": "ESP82",
}
},
...

What is the result of decode-config.py --source batterymon1 | jq '.config_version' (should be != 0 on any ESP32)?

spacelama commented 1 week ago

Sorry, I'm a dummy. Had only assumed esp32 because it's one of my newer devices. It's an 8266:

: 57484,1; decode-config.py --source batterymon1 | jq '.config_version'
0

esp chip ID: 5891535 (ESP8266EX)

curzon01 commented 1 week ago

Should be solved, give it a try...