Skip to content

Running the OTA will kill the node ID and will not complete #44

@BOBAH1248

Description

@BOBAH1248

I use the latest pre-compiled hex from "compiled" folder with jkandasa MyController.org.
First OTA update went well.
But subsequent updates issue the BL_CMD_CLEAR_EEPROM command, which destroys NODE_ID and PARENT_NODE_ID.

for(uint16_t i = 0; i < EEPROM_SIZE; i++) eeprom_update_byte((uint8_t *)i, EEPROM_ERASED_BYTE);

As a result, the controller loses the device and cannot send firmware to it.

In my case, it's even worse, because I have 100 identical devices on the network with the same firmware, which I only distinguish by NODE_ID.
That is, if I push firmware to all devices, my system/network will be destroyed, and it may take several days to restore it - I will have to manually restore NODE_ID on each device.

It's OK, if I change this like to

for(uint16_t i = EEPROM_DISTANCE_ADDRESS; i < EEPROM_SIZE; i++)
    eeprom_update_byte((uint8_t *)i, EEPROM_ERASED_BYTE);

or I should erase EEPROM_FIRMWARE_xxxxx only?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions