From 6cde2d83787ef3e628a6b418ec25ab30f520da84 Mon Sep 17 00:00:00 2001 From: mcudev <29890609+mcudev@users.noreply.github.com> Date: Sun, 15 Oct 2017 13:27:44 -0400 Subject: [PATCH] docs: bootloader microsd creation note and typo fix (#47) --- docs/bootloader.md | 11 +++++++++++ docs/memory.md | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/docs/bootloader.md b/docs/bootloader.md index eff466c7..4d82ead4 100644 --- a/docs/bootloader.md +++ b/docs/bootloader.md @@ -29,6 +29,17 @@ if it did not, then a corruption/erasure of later stage flash memory would leave the device unusable (only the boardloader could run and it would not pass execution to a later stage that fails signature validation). +Developer note: + +A microSD card can be prepared with the following. Note that the bootloader is allocated 128 KiB. + +WARNING: Ensure that you want to overwrite and destroy the contents of `/dev/mmcblk0` before running these commands. +Likewise, `/dev/mmcblk0` may be replaced by your own specific destination. + + 1. `sudo dd if=/dev/zero of=/dev/mmcblk0 bs=512 count=256 conv=fsync` + + 1. `sudo dd if=build/bootloader/bootloader.bin of=/dev/mmcblk0 bs=512 conv=fsync` + ## Second Stage - Bootloader Second stage checks the integrity and signatures of the firmware and runs diff --git a/docs/memory.md b/docs/memory.md index 69b0c596..a9262ded 100644 --- a/docs/memory.md +++ b/docs/memory.md @@ -9,7 +9,7 @@ | Sector 2 | 0x08008000 - 0x0800BFFF | 16 KiB | boardloader (1st stage) (write-protected) | Sector 3 | 0x0800C000 - 0x0800FFFF | 16 KiB | ? | Sector 4 | 0x08010000 - 0x0801FFFF | 64 KiB | storage area #1 -| Sector 5 | 0x08020000 - 0x0803FFFF | 128 KiB | boardloader (2nd stage) +| Sector 5 | 0x08020000 - 0x0803FFFF | 128 KiB | bootloader (2nd stage) | Sector 6 | 0x08040000 - 0x0805FFFF | 128 KiB | firmware | Sector 7 | 0x08060000 - 0x0807FFFF | 128 KiB | firmware | Sector 8 | 0x08080000 - 0x0809FFFF | 128 KiB | firmware