Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'Verify bin header failed' error #2

Open
glynhudson opened this issue Jun 18, 2016 · 3 comments

Comments

@glynhudson
Copy link

@glynhudson glynhudson commented Jun 18, 2016

Hi Dan, as you have probably have gathered I have been working towards re-creating your awesome continuous delivery project, and learning lots in the process. I think I'm almost there. I've got Travis and platformio setup to auto generating the compiled .bin on a release, see blog post. Today I setup the server php script and the ESP code. At first it seemed to work when the build number of the firmware matched the build number on the GitHub release I saw the following output from the ESP:

    Going to update firmware...
    Checking for Update. Current version: 0.0.1
    HTTP_UPDATE_NO_UPDATES

However when I released a point updated release on Github (0.0.1 > 0.0.2), I got the following update from the ESP:

    Going to update firmware...
    Checking for Update. Current version: 0.0.1
    HTTP_UPDATE_FAILD Error (-106): Verify bin header failedGoing to update firmwar. 

Have you any idea what could be causing the bin header failed error? The PHP script is obviously working to serve up the updated .bin, however the ESP http updater seem to be throwing an error.

Here is my ESP code with modified URL for the php scrip. The server code is unchanged ([appart from the repo URL])(https://github.com/openenergymonitor/EmonESP/blob/ota/ota/firmware.php#L3). My php script is served from here if you want to test it.

@squix78

This comment has been minimized.

Copy link
Owner

@squix78 squix78 commented Jun 26, 2016

Hi Glyn. I think I resolved your issue and I hope you're not gonna hate yourself for it: your php script starts with an empty line, actually with a new line character:

@glynhudson

This comment has been minimized.

Copy link
Author

@glynhudson glynhudson commented Jun 26, 2016

Doh indeed! Thanks so much, sometimes the simplest things cause so much pain! Now working beautifully 👍

Checking for Update. Current version: 0.0.3#

 ets Jan  8 2013,rst cause:2, boot mode:(3,6)

load 0x4010f000, len 1264, room 16 
tail 0
chksum 0x0f
csum 0x0f
@cp:0
     ld

emonESP Startup
BUILD_TAG: 0.0.4#
Connecting as Wifi Client to xxx epass:xxxx
Connected, IP Address: 192.168.0.75
HTTP server started
Going to update firmware...
Checking for Update. Current version: 0.0.4#
@squix78

This comment has been minimized.

Copy link
Owner

@squix78 squix78 commented Jun 27, 2016

Sweet! Happy that it works now!

Sent from my iPhone

On 27.06.2016, at 00:32, Glyn Hudson notifications@github.com wrote:

Doh indeed! Thanks so much, sometimes the simplest things cause so much pain! Now working beautifully 👍

Checking for Update. Current version: 0.0.3#

ets Jan 8 2013,rst cause:2, boot mode:(3,6)

load 0x4010f000, len 1264, room 16
tail 0
chksum 0x0f
csum 0x0f
@cp:0
ld

emonESP Startup
BUILD_TAG: 0.0.4#
Connecting as Wifi Client to xxx epass:xxxx
Connected, IP Address: 192.168.0.75
HTTP server started
Going to update firmware...
Checking for Update. Current version: 0.0.4#

You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.