nihalpasham / rustBoot

rustBoot is a standalone bootloader written entirely in `Rust`, designed to run on anything from a microcontroller to a system on chip. It can be used to boot into bare-metal firmware or Linux.
MIT License
214 stars 21 forks source link

support for stm32f446 #30

Closed Strange21 closed 2 years ago

Strange21 commented 2 years ago

Added support for stm32f446 board, with bootloader and bootfirmware and update firmware.

Strange21 commented 2 years ago

Added working video of the board

https://user-images.githubusercontent.com/93325790/171675363-9a46c319-550d-4c08-978f-17bc8c827c60.mp4

d

Strange21 commented 2 years ago
  • ci.yml

    • the if statement at line 83 needs to be fixed. Have a look at the ci-workflows for the other boards.
    • --> Fixed the if statemen similarly to the existing stm board
  • boards/bootloaders/stm32f446/readme.md

    • this should be renamed to debug.md
    • --> file renamed
  • boards/update/Cargo.toml and rustBoot/Cargo.toml

    • remove the additional default feature defmt. I believe you only needed this for testing -right?
    • --> Yes I have added it for testing purpose only, Removed now.
  • boards/update/src/update/update_flash.rs

    • contains commented out defmt print statements, remove them.
    • --> Removed the print statements.
  • xtask/src/main.rs

    • remove the extra print statement from line 84.
    • --> Removed the print statement.
  • rustBoot/src/image/image.rs

    • again extra use statement at line 6
    • --> Removed

    Justification

    • Why are we using the stm32f446_boot_fw and stm32f446_updt_fw as names for the blinky firmware?
    • Because we want to have unique names for each firmware. If we had same name of the firmware it was causing the error of dependency. Also followed the existing naming convention from nrf board firmware.
    • rustBoot/src/dt/fit.rs
    • why was line 222 changed here?
    • --> This statement was causing the error --> value after borrowing. Because on line 219 config value was passed to configuration, and later it was used in print statement. which was causing he error of value borrowed after use. Therefore I tried to fix it.
nihalpasham commented 2 years ago

looks good and ready for merging.

nihalpasham commented 2 years ago

🎉🎉🎉🎉🎉🎉🎉