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

Add AsyncElegantOTA #118

Merged
merged 12 commits into from
May 13, 2019
Merged

Add AsyncElegantOTA #118

merged 12 commits into from
May 13, 2019

Conversation

ayushsharma82
Copy link
Contributor

Add AsyncElegantOTA to perform OTA's Elegantly.

@probonopd
Copy link
Owner

Cool! 👍 Build is using the library now but there is still a compile error, please see the build log.

@ayushsharma82
Copy link
Contributor Author

@probonopd Right. I am working on a Fix.

@ayushsharma82
Copy link
Contributor Author

ayushsharma82 commented May 2, 2019

@probonopd It's saying SendCommands and ReceiveResponses are not declared?

https://github.com/ayushsharma82/WirelessPrinting/blob/master/ESP8266WirelessPrintAsync/ESP8266WirelessPrintAsync.ino#L891

Is that due to, functions declared under it?

@probonopd
Copy link
Owner

probonopd commented May 2, 2019

Looks like it. Feel free to move.

@ayushsharma82
Copy link
Contributor Author

@probonopd Passed ESP8266 Build. ESP32 Build is causing some problem due to a script error in travis.yml . Please take a look.

@probonopd
Copy link
Owner

probonopd commented May 2, 2019

Maybe need to add #include <Hash.h> for ESP32.

I will try to add this.

Seems to be a known issue:

@probonopd
Copy link
Owner

So this was not sufficient, still getting ESP8266WirelessPrintAsync:9:20: error: Hash.h: No such file or directory for ESP32. Maybe @me-no-dev knows?

@ayushsharma82
Copy link
Contributor Author

Maybe you can figure this out.. i have no idea why it's not getting Hash.h

@probonopd
Copy link
Owner

Yes, but give me some time. Thanks until here, great PR

@ayushsharma82
Copy link
Contributor Author

No problem.

@probonopd
Copy link
Owner

probonopd commented May 2, 2019

Yay! Looks like we have a winner. 👍

Do they work for you, including OTA?

(Links available for 14 days)

@ayushsharma82
Copy link
Contributor Author

@probonopd I will it check today. 👍

@ayushsharma82
Copy link
Contributor Author

Surprisingly, It compiles for me without that library.Try latest release of ESP32 Arduino Core.

@ayushsharma82
Copy link
Contributor Author

ayushsharma82 commented May 3, 2019

I just checked the build logs. It is using 75% of Sketch space. Is there any space left for an OTA? 🤦‍♂ .

@probonopd
Copy link
Owner

probonopd commented May 4, 2019

On the ESP32 using Firefox 64 on Linux, getting

failed

but the update nevertheless seems to have worked. I have the updated firmware on the machine afterwards.

@probonopd
Copy link
Owner

Also, we need a link to /update from the main page so that one finds the page.

@ayushsharma82
Copy link
Contributor Author

ayushsharma82 commented May 4, 2019 via email

@ayushsharma82
Copy link
Contributor Author

Fixed webpage and tested on my ESP32.
There is a travis script error for esp8266. @probonopd please take a look.

Thanks!

@probonopd
Copy link
Owner

Don't know why it is failing, perhaps an intermittent issue?

@ayushsharma82
Copy link
Contributor Author

ayushsharma82 commented May 11, 2019 via email

@probonopd
Copy link
Owner

http://arduino.esp8266.com/stable/package_esp8266com_index.json gives in Firefox:

SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data

@ayushsharma82
Copy link
Contributor Author

ayushsharma82 commented May 11, 2019 via email

@probonopd
Copy link
Owner

I never compile anything locally. It needs to pass the automated builds...

@ayushsharma82
Copy link
Contributor Author

ayushsharma82 commented May 11, 2019 via email

@probonopd
Copy link
Owner

The build is working now. Do we not get the red arrow anymore? (Couldn't test myself yet)

@ayushsharma82
Copy link
Contributor Author

Nope. I have updated AsyncElegantOTA. It shows the Successful when updated.
ESP32 was resetting before the AsyncWebServer had actually sent the response in background. So i have added a 1 second delay in which it will send the response back to the webpage.

@ayushsharma82
Copy link
Contributor Author

Can we merge it now?

@probonopd
Copy link
Owner

I did not have a chance to test it on ESP8266 and ESP32 yet, sorry. Do we have a link to the firmware update page from the main frontpage?

@ayushsharma82
Copy link
Contributor Author

I will add that

@ayushsharma82
Copy link
Contributor Author

Done

@probonopd
Copy link
Owner

If you have successfully tested updating on ESP8266 and ESP32 hardware with no red arrows or other errors, then I think we can merge?

@ayushsharma82
Copy link
Contributor Author

ayushsharma82 commented May 13, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants