mgos32-to-tasmota32
mgos32-to-tasmota32 copied to clipboard
How to work around manifest.json mismatch with deviceInfo for Shelly Plug US Plus identifying as Plug US
I just received a Shelly Plug US, the box has "Plus" in the upper right. The Shelly Web UI has "Shelly PlugUS" in its footer. I popped open the case, it has an ESP32-U4WD on the daughterboard. So I'm sure it is a "Plus" device.
However Shelly deviceInfo reports this as simply PlugUS, no "Plus":
"deviceInfo": {
"name": "shelly03",
"id": "shellyplugus-ccdba7d11c10",
"mac": "CCDBA7D11C10",
...
"batch": "2245-Frankever",
"fw_sbits": "00",
"model": "SNPL-00116US",
"gen": 2,
"fw_id": "20231106-160237/1.0.8-gdba0ee3",
"ver": "1.0.8",
"app": "PlugUS", <--------------------- ???
"auth_en": false,
"auth_domain": null
}
I tried flashing tasmota32solo1.factory.bin over the air, with no luck. On the recommendation of experts on the Tasmota discord chat, I then tried mgos32-to-tasmota32-PlusPlugUS.zip, totalling 2043697 bytes. Simultaneously with loading the firmware, I had the Shelly diagnostic log open in another browser window. It showed:
shos_rpc_inst.c:230 ota.start via WS_in 192.168.0.11:52350
shelly_ota.cpp:304 Starting update (0x3ffe4818), timeout=600 commit_timeout=0 ignore_same=0
shos_rpc_inst.c:230 ota.write via WS_in 192.168.0.11:52350
shelly_ota.cpp:403 'manifest.json' 1793 bytes (hdr 71 desc 0 crc eb0f6367)
shelly_ota.cpp:523 fw: PlusPlugUS ver 12.5.0 20231029-135017/tasmota-12.5.0
shelly_update.cpp:305 incoming fw signatures: 00
shelly_update.cpp:297 Wrong app name 'PlusPlugUS' <---------- ??
shelly_ota.cpp:311 Aborting update: aborted by user
shelly_ota.cpp:234 OTA status error, 0 %
shelly_ota_source_rp:21 leftover RPC source 0x3ffe1f78
shos_rpc_inst.c:230 ota.write via WS_in 192.168.0.11:52350
I unzipped mgos32-to-tasmota32-PlusPlugUS.zip and found the manifest.json file:
{
"name": "PlusPlugUS",
"platform": "esp32",
"version": "12.5.0",
"build_id": "20231029-135017/tasmota-12.5.0",
"build_timestamp": "2023-10-29T13:50:17Z",
I changed
"name": "PlusPlugUS",
to
"name": "PlugUS",
Then zipped all the files together again and attempted to load this. In the log:
Zip it all together after this change. Installing, and the log gives:
shos_rpc_inst.c:230 ota.start via WS_in 192.168.0.11:52350
shelly_ota.cpp:304 Starting update (0x3ffe4534), timeout=600 commit_timeout=0 ignore_same=0
shos_rpc_inst.c:230 ota.write via WS_in 192.168.0.11:52350
shelly_ota.cpp:403 'bootloader-tasmota.bin' 15648 bytes (hdr 80 desc 0 crc 160e0a45)
shelly_ota.cpp:311 Aborting update: manifest.json was not first in archive <----------------- !!!
shelly_ota.cpp:234 OTA status error, 0 %
shelly_ota_source_rp:21 leftover RPC source 0x3ffe3334
shelly_notification:209 Event from sys: {"component":"sys", "event":"ota_error", "msg":"error", "ts":1702904137.62}
shos_rpc_inst.c:230 ota.write via WS_in 192.168.0.11:52350
I rebuilt the archive in a better order, using no compression, and forcing manifest.json to be first. These are linux command line:
zip -0 poop.zip manifest.json
zip -u -0 poop.zip bootloader-tasmota.bin fs-4MB-tasmota.img otadata-tasmota.bin partition-table-tasmota.bin tasmota32solo1.bin
Uploading poop.zip worked.
There remains issues getting the template configuration correct, but that's a second issue.