Firmware version mismatch

Hello,

I am trying to update one of my device over the air, but it keeps throwing “Firmware version mismatch”.
I have selected “No Condition” under “APPLY UPDATE IF THE DEVICE HAS” but still it says mismatch.

However, I had the old .bin file saved for the same device. If i upload that particular file, it updates perfectly.

I updated my ESP8266 core and Blynk lib to the latest version. Can this be the issue?

I have used the Edgent example with no modification on the header files. And provisioning done via phone. auth token is not hard coded on the firmware.

UPDATE

I downgraded the Blynk lib to 1.2.0 from 1.3.0. And now if I compile the file (no changes made in the code), it uploads and OTA is successful.

Can anybody tell me what is wrong?

I suspect that your code has BLYNK_DEVICE_NAME rather than `BLYNK_TEMPLATE_NAME’ defined.

Pete.

I have changed that as well. Tried both. Only downgrading the lib works.

EDIT:

Tried updating the second device, and now this is giving the same issue…
Even, the edgent bare example sketch is also giving the same error on the new version.
Also did a fresh install of the blynk lib. But the problem is still there.

So have you actually increased the…

#define BLYNK_FIRMWARE_VERSION "x.x.x"

line of code so that the number is higher than that shown as the current version number in the Blynk.Air shipment screen?

Pete.

In the about section of the device,

It’s showing current firmware version as 1.1.0

I tried with same firmware number and also increasing the firmware to 1.2.0 in the code.

But it still says firmware mismatch. Even though i have selected “no conditions”

I had never faced such issues in the past. I have updated N number of devices N number of times…

So i am sure i am not missing on anything.

I ran into this yesterday with a device I have.

I’ll update you shortly but the only way I could get new firmware onto the device was my manually flashing it.

Now that I have it with fresh firmware on it, I’m going to try and push another OTA update to it and see if the issue is resolved.

I’ll update everyone in a couple hours once I get a chance to do this test.

1 Like

Yeah, even i am thinking of flashing it physically.

If I downgrade the blynk lib version, OTA works. As soon as I upgrade the library to the latest, it says firmware mismatch.

I think this is BUG.

I tried with multiple devices and this issue is persistent.

I was pretty confident I had a bug with my compile error issue I ran into a while back but it turned out I hadn’t noticed Blynk had changed some definition names in the Template ID section. It’s possible this is a similar issue. @PeteKnight had me pointed in the right direction.
Now that I have a device online with the new version of the library if I can successfully do OTA I’ll assume something changes similarly in the OTA and we just haven’t noticed and that is what is causing our issues.

Once we flash the device physically with latest lib, the OTA works. But my devices are running the old lib, now i am not able to update them to the new lib. Thats the challenge.

I will have to update all the devices physically now. And thats a big headache for me.

I also can update OTA once I’ve done a manual flash.

I’ll try and dig through and see if I can figure out the reasoning but it’s probably got to do with the fact that Blynk changed the one #define from BLYNK_DEVICE_NAME to BLYNK_TEMPLATE_NAME in between the two libraries and the OTA handler is catching that difference.

Probably. I think blynk team should start investigating on this. I think it’s easy to reproduce the same at their end.

Please respond BLYNK TEAM

@vshymanskyy it seems that Blynk.Air has stopped working (at least for the ESP8266 - I’ve not tested any other boards) in the 1.3.0 library.

Here’s the tests I did…

Open Arduino IDE 1.8.19
Check that the ESP8266 core is up to date (3.1.2)
Downgrade Blynk library to 1.2.0
Open ESP8266 Edgent example (from the 1.2.0 library)
Add Template ID etc from an existing project
Select Wemos D1 Mini as my board type in the sketch
Upload to a new D1 Mini Pro
Provisioned device via app
Changed BLYNK_FIRMWARE_VERSION from “0.1.0” to “0.1.1”
Exported compiled binary
Uploaded to device via Blynk.Air - Worked as expected

Upgraded Blynk library to 1.3.0
Changed Changed BLYNK_FIRMWARE_VERSION from “0.1.1” to “0.1.2”
Exported compiled binary
Uploaded to device via Blynk.Air - Failed with “Firmware Version Mismatch” error

Thought the least significant number might be being ignored, so…
Changed Changed BLYNK_FIRMWARE_VERSION from “0.1.2” to “0.2.0”
Exported compiled binary
Uploaded to device via Blynk.Air - Failed with “Firmware Version Mismatch” error

Thought most significant number may need to change, so…
Changed Changed BLYNK_FIRMWARE_VERSION from “0.2.0” to “1.2.3”
Exported compiled binary
Uploaded to device via Blynk.Air - Failed with “Firmware Version Mismatch” error

Thought something in the Edgent example supplied with the latest library may be missing from the earlier example, so…
Opened ESP8266 Edgent example (from the 1.3.0 library)
Add Template ID etc from the same project used above
Select Wemos D1 Mini as my board type in the sketch
Changed BLYNK_FIRMWARE_VERSION from “0.1.0” to “3.4.5”
Uploaded to device via Blynk.Air - Failed with “Firmware Version Mismatch” error

The existing firmware version from the device is being correctly detected, and the new firmware version from the new .bin file is also being detected correctly…

If I downgrade to Blynk library version 1.2.0 and try uploading via Blynk.Air it works fine with the Edgent example from either 1.2.0 or 1.3.0…

Pete.

3 Likes

@Dmitriy this might be related to the change of device info message format.
Was this deployed to the public Blynk Cloud?

Any update? Is the issue fixed?

We’ll look into this one soon, it’s scheduled for the next week

1 Like

The issue is reproduced and analyzed. We’re now finding the best way to resolve it.
@Madhukesh Thanks for reporting it!

2 Likes

The issue is fixed. It is entirely cloud-side, so it should start working automagically for everyone, once we do our servers update. We’ll notify you once our cloud software is updated.

2 Likes

That was real quick!!
Thanks for attending the problem and finding a fix…

@ThaiNguyen The issue you are facing and the issue being discussed on this topic are totally different. Please create your own topic for your issues being faced. And the problem you just mentioned isn’t a problem. It’s already been discussed several times on the forum. Please use the search tool in the forum to find the answer to your issue.

If you feel your issue is totally different and not solved, create a new topic and explain in detail.

2 Likes

@Madhukesh the fix is deployed.

1 Like