Skip to content

Commit e8eb299

Browse files
committed
Added documentation for STM32-L0x3
1 parent 2766952 commit e8eb299

1 file changed

Lines changed: 33 additions & 0 deletions

File tree

docs/Targets.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,39 @@ On other systems, the SWAP space can be as small as 512B, if multiple smaller fl
3636
More information about the geometry of the flash and in-application programming (IAP) can be found in the manufacturer manual of each target device.
3737
3838
39+
## STM32L0x3
40+
41+
Example 192KB partitioning on STM32-L073
42+
43+
This device is capable of erasing single flash pages (256B each).
44+
45+
However, we choose to use a logic sector size of 4KB for the swaps, to limit the amount of
46+
writes to the swap partition.
47+
48+
The proposed geometry in this example `target.h` uses 32KB for wolfBoot, and two
49+
partitions of 64KB each, leaving room for up to 8KB to use for swap (4K are being used here).
50+
51+
```C
52+
#define WOLFBOOT_SECTOR_SIZE 0x1000 /* 4 KB */
53+
#define WOLFBOOT_PARTITION_BOOT_ADDRESS 0x8000
54+
#define WOLFBOOT_PARTITION_SIZE 0x10000 /* 64 KB */
55+
#define WOLFBOOT_PARTITION_UPDATE_ADDRESS 0x18000
56+
#define WOLFBOOT_PARTITION_SWAP_ADDRESS 0x28000
57+
```
58+
59+
### Building
60+
61+
Use `make TARGET=stm32l0`. The option `CORTEX_M0` is automatically selected for this target.
62+
63+
#### Known issues
64+
65+
With Ed25519 (default SIGN algorithm) it's not possible at the moment to compile wolfboot
66+
with optimizations, due to a GCC linker error complaining about a missing symbol `__gnu_thumb1_case_uqi`.
67+
68+
Possible workarounds:
69+
- Compile ed25519 with debug (optimizations are disabled) : `make TARGET=stm32l0 DEBUG=1`
70+
- Use ECDSA instead (which is much faster) : `make TARGET=stm32l0 SIGN=ECC256`
71+
3972
## SiFive HiFive1 RISC-V
4073

4174
### Features

0 commit comments

Comments
 (0)