• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

OTA updates with sleep possible?

Q&A Forum › Category: ESP8266 › OTA updates with sleep possible?
0 Vote Up Vote Down
Steve Fisch asked 4 years ago

I have successfully used your example of OTA Updates for a sketch.

To save battery life, most if not all of my sketches use the code for sleeping.

Unfortunately, when the board is sleeping, I can’t figure out a way to send code to the board.

I’d appreciate any suggestions.

As always, thanks in advance,
Steve

Question Tags: OTA (Over-the-Air) Updates – AsyncElegantOTA, with sleep possible?
4 Answers
0 Vote Up Vote Down
Steve Mercer answered 4 years ago

You obviously wake the board either at regular intervals or on an external interrupt. At the end of the code run, just before going to sleep, send a “check for updates” request to a server and if the response is “Yes” (Or whatever you want), start the OTA update code.

0 Vote Up Vote Down
Steve Fisch answered 4 years ago

Steve,
Thanks for your answer. I’d be greatly appreciative if you would send some sample code for a “check for updates” request to a server.

Thanks in advance,
Steve

0 Vote Up Vote Down
Steve Mercer answered 4 years ago

I use IOTAppStory. It completely automates the OTA updates. I use the Preferences library to save the date. I check that the date is not today and then callHome(). 

0 Vote Up Vote Down
Steve Mercer answered 4 years ago

Hmmmm. I need to update to 2.1 of IOTAppStory and it uses EEPROM as well (The Preferences library uses EEPROM).

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025
  • [eBook Updated] Learn ESP32 with Arduino IDE eBook – Version 3.2 April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.