Closed JakubVanek closed 4 years ago
Just to be sure: you can't overwrite the bootloader that way, right?
Yes, this bootloader is stored in a separate chip that cannot be written via USB (as far as I know). There's uboot in the main flash image, but it is chainloaded from the EEPROM.
However, I have noticed that the EEPROM containing it is not write protected (WP is tied low, for some reason I thought it was tied high). This means that it could be possible to reprogram the EEPROM from booted Linux.
Hi,
I think it is sometimes useful to have the ability to upload a new firmware to the brick. So far on Linux this has been provided by the C# firmware loader. I have written a different tool for my need, but I think it would be nice to have this in ev3duder too.
I believe the builtin EV3 EEPROM is responsible for handling the upload. ~The write protect pin is permanently activated, so I think it is not possible to hard-brick the brick this way.~ see last comment
I don't know from where the protocol originates. I think it comes from BricxCC and it is not publicly documented. However it is very similar to the protocol that the LMS2012 VM uses when it is running. It is using system commands too, but it is using different command IDs.
The upload has four phases:
There are two more commands:
It may be even possible do partial uploads that would preserve user data by not erasing the whole chip. However I have not yet tested this. The remaining functionality is tested to work.
I have the following proposal for the interface:
Best regards,
Jakub