MYSBootLoader OTA documentation
-
Is there any documentation on how MYSBootloader expects to receive OTA firmware updates? This is a slick feature for sure but I need to write an OTA stack for my controller since I am not using MYSController.
I checked for documentation but there seems to be almost zero there (just a brief mention that OTA exists on the serial protocol page).
-
@jsiddall You can find additional information and sources here:
-
Thanks @tekka. Binary huh? Looks like it's time I read http://perldoc.perl.org/perlpacktut.html
I also see #define FIRMWARE_BLOCK_SIZE 16
with 6 bytes of other headers brings it up to 22 bytes of the 25 available payload bytes. Is it safe to assume the block size won't be changing any time soon?
Also, if the actual firmware doesn't fill the last block is the expected behavior to send less than FIRMWARE_BLOCK_SIZE bytes (i.e.: no padding)?
-
@jsiddall It's actually 7 bytes header, leaving 25 bytes for payload.
FW blocks are 16 bytes (FIRMWARE_BLOCK_SIZE). Padding bytes (0xFF) are added to fill the page (m328p has 64 words per page). CRC is calculated over all transmitted pages.See here for additional information: https://github.com/mysensors/MySensorsSampleController
-
@tekka, yes, sorry, should have clarified. 7 bytes for MYS sensor, but the 6 bytes I was referring to as a "header" was the typedef on the firmware download. So 7+6=13/32 leaving up to 19 bytes for the firmware block itself.
Thanks for the clarification on the padding and the CRC. That will become important.
Suggested Topics
-
Arduino Celebrates 10 years (Malmö/Sweden)
Announcements • 29 Mar 2014, 17:08 • hek 29 Mar 2014, 17:08 -
Sending offset to node
Development • 31 Jan 2025, 00:59 • bsl88k 4 Feb 2025, 12:14 -
LAN8720A - will mysensors work with this module
Development • 13 Nov 2024, 17:06 • Marcin 15 Nov 2024, 10:59 -
Radio waking up for no reason.
Development • 4 Jul 2020, 21:09 • Sasquatch 15 Jan 2025, 08:33 -
PJON and Minicore not working
Development • 21 Mar 2025, 19:51 • Trand 21 Mar 2025, 19:51 -
MQTT-Help me understand about the MQTT Gateway.
Development • 2 Mar 2025, 01:44 • dpcons 12 Mar 2025, 23:39