custom library - fota for non networked devices

Discussion about programs, libraries and tools that work with MicroPython. Mostly these are provided by a third party.
Target audience: All users and developers of MicroPython.
Post Reply
lnsri22
Posts: 75
Joined: Fri Aug 17, 2018 12:16 pm
Location: India

custom library - fota for non networked devices

Post by lnsri22 » Tue Dec 18, 2018 1:02 pm

Hello everyone!!

Is there any idea on developing a custom library to support fota -Firmware Over The Air for non networked devices such as PyBoard or any such bare metals? :roll:

It would be of a great help if anybody could share some insights or some way as it seems that I have been pitching in the dark to start off with :)


Thanks in advance!!
lnsri22 :)

kevinkk525
Posts: 969
Joined: Sat Feb 03, 2018 7:02 pm

Re: custom library - fota for non networked devices

Post by kevinkk525 » Tue Dec 18, 2018 1:04 pm

If your device is not networked, how is this going to work and how is this different than connecting a pc to it and flashing a new firmware?
Kevin Köck
Micropython Smarthome Firmware (with Home-Assistant integration): https://github.com/kevinkk525/pysmartnode

lnsri22
Posts: 75
Joined: Fri Aug 17, 2018 12:16 pm
Location: India

Re: custom library - fota for non networked devices

Post by lnsri22 » Tue Dec 18, 2018 1:40 pm

The term non-networked which I referred was the factory state of the device. Like ESP8266 which is Wi-Fi enabled(networked) by default, PyBoard is not.

I am planning to use an external cellular engine. Coming across various forums, I find that the typical way of doing this is to maintain two banks in the flash memory (one - for running application and another to store the firmware that is being downloaded).

I am trying to figure this out on PyBoard(way to access built in flash memory. I'm not sure whether I might need use an external flash since the built-in flash has limited capacity).

If this could be done without the means of disturbing the running application, it would be great with respect to PyBoard.

This is needed in scenarios of remotely updating the firmware that is running on the device

Any help is greatly appreciated!!

Thanks in advance
lnsri22 :)

kevinkk525
Posts: 969
Joined: Sat Feb 03, 2018 7:02 pm

Re: custom library - fota for non networked devices

Post by kevinkk525 » Tue Dec 18, 2018 1:58 pm

For remotely updating firmware your device has to be networked in some kind (WLAN, i2c, ...).
I don't know if anything is done in that direction. Apparently not even OTA works for esp8266 yet.
Kevin Köck
Micropython Smarthome Firmware (with Home-Assistant integration): https://github.com/kevinkk525/pysmartnode

lnsri22
Posts: 75
Joined: Fri Aug 17, 2018 12:16 pm
Location: India

Re: custom library - fota for non networked devices

Post by lnsri22 » Tue Dec 18, 2018 2:13 pm

Thanks for the quick reply there!! :)

As of now , the only way of networking is to use the GSM module(project specific). :roll:

I not sure whether I could use any other module to get this done :|
lnsri22 :)

kevinkk525
Posts: 969
Joined: Sat Feb 03, 2018 7:02 pm

Re: custom library - fota for non networked devices

Post by kevinkk525 » Tue Dec 18, 2018 4:53 pm

Well you definitely need a way of uploading/downloading the new firmware (WLAN, I2C, some bus, GSM, ...) and an OTA module. ESP32 (at least loboris port) has an OTA module that can be used with WLAN and ethernet. I don't know about the pyboard and esp8266 does not seem to have support for that yet.
Kevin Köck
Micropython Smarthome Firmware (with Home-Assistant integration): https://github.com/kevinkk525/pysmartnode

User avatar
Roberthh
Posts: 3667
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: custom library - fota for non networked devices

Post by Roberthh » Tue Dec 18, 2018 9:15 pm

There is an OTA variant for ESP8266. Just look into the download section.

kevinkk525
Posts: 969
Joined: Sat Feb 03, 2018 7:02 pm

Re: custom library - fota for non networked devices

Post by kevinkk525 » Wed Dec 19, 2018 8:49 am

Thanks. Looks like there's some work done although it is not as easy as the OTA solution provided in loboris port for esp32.
Kevin Köck
Micropython Smarthome Firmware (with Home-Assistant integration): https://github.com/kevinkk525/pysmartnode

Post Reply