You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On Atmel Samd/Same MCU, the bootloader regions are locked. This means that you cannot flash your own bootloader with probe-rs.
Tools like OpenOCD can modify the MCU Fuses like so in order to write to the bootloader region of these controllers:
atsame5 bootloader 0 // Write 0 to bootloader fuse
program bootloader.bin verify
atsame5 bootloader 16384 // Set bootloader size to 16KB
Describe the solution you'd like
Probe-rs can be extended in order to perform this. For now, the only use case for fuse modifying would be to flash the bootloader. With regards to implementation, I could see a couple ways on doing this:
Create a new flag for probe-rs that allows for fuse toggling bootloader protection (And thus setting the target size after flash - This would allow for writing a larger bootloader if needed)
Modify the default flash process (Read the current fuse state, set it to 0. Write flash, Write back old fuse state) - Maybe let the user pass a flag to probe-rs to acknowledge writing to 'dangerous' flash regions
The text was updated successfully, but these errors were encountered:
In general, the team is hesitant to add target-specific flags. If you can write a flash algorithm that implements 2) we can add atsamdXXXX-with-bootloader targets that execute the modified flash algorithm.
On Atmel Samd/Same MCU, the bootloader regions are locked. This means that you cannot flash your own bootloader with probe-rs.
Tools like OpenOCD can modify the MCU Fuses like so in order to write to the bootloader region of these controllers:
Describe the solution you'd like
Probe-rs can be extended in order to perform this. For now, the only use case for fuse modifying would be to flash the bootloader. With regards to implementation, I could see a couple ways on doing this:
Create a new flag for probe-rs that allows for fuse toggling bootloader protection (And thus setting the target size after flash - This would allow for writing a larger bootloader if needed)
Modify the default flash process (Read the current fuse state, set it to 0. Write flash, Write back old fuse state) - Maybe let the user pass a flag to probe-rs to acknowledge writing to 'dangerous' flash regions
The text was updated successfully, but these errors were encountered: