|
14 | 14 |
|
15 | 15 | ## Programming and Deployment |
16 | 16 |
|
17 | | -The Makefile in this directory provides several helper targets for deployment: |
| 17 | +The Makefile for this board is simplified to focus on OpenOCD-based deployment. |
| 18 | + |
| 19 | +### Makefile Targets |
18 | 20 |
|
19 | 21 | | Target | Description | |
20 | 22 | | :--- | :--- | |
21 | 23 | | **`make`** | Compiles the Tock kernel for the Nucleo-U545RE-Q. | |
22 | | -| **`make flash`** | Flashes **only the kernel** to the board using `probe-rs`. | |
23 | | -| **`make flash_ocd`** | Flashes **only the kernel** to the board using `openocd`. | |
24 | | -| **`make app`** | Merges the kernel with a userspace app (`.tbf`) into a single unified ELF. Requires `APP_PATH`. | |
25 | | -| **`make app_flash`** | Compiles, merges, and **flashes both the kernel and app** in one step using `probe-rs`. | |
26 | | -| **`make app_flash_ocd`** | Compiles, merges, and **flashes both the kernel and app** in one step using `openocd`. | |
| 24 | +| **`make flash`** | Flashes the release kernel using `openocd`. | |
| 25 | +| **`make flash-debug`** | Flashes the debug kernel using `openocd`. | |
| 26 | +| **`make program`** | Installs apps using `tockloader` via `openocd`. Requires `APP`. | |
| 27 | +| **`make install`** | Alias for `make flash`. | |
27 | 28 |
|
28 | 29 | ### Usage Examples |
29 | 30 |
|
30 | | -**1. Flash only the kernel:** |
| 31 | +**1. Flash the release kernel:** |
31 | 32 | ```bash |
32 | 33 | make flash |
33 | | -# OR |
34 | | -make flash_ocd |
35 | 34 | ``` |
36 | 35 |
|
37 | | -**2. Flash kernel merged with a specific app:** |
| 36 | +**2. Flash the debug kernel:** |
| 37 | +```bash |
| 38 | +make flash-debug |
| 39 | +``` |
| 40 | + |
| 41 | +**3. Install an application:** |
| 42 | +Note: This requires a `.tab` (Tock Application Bundle) file. |
38 | 43 | ```bash |
39 | | -# Provide the path to your compiled Tock Binary Format (.tbf) file |
40 | | -make app_flash APP_PATH=/path/to/your/app.tbf |
41 | | -# OR |
42 | | -make app_flash_ocd APP_PATH=/path/to/your/app.tbf |
| 44 | +make program APP=/path/to/your/app.tab |
43 | 45 | ``` |
44 | 46 |
|
45 | 47 | ## Flashing Notes |
46 | 48 |
|
47 | | -This board is flashed using **`probe-rs`** or **`openocd`**. Due to the specific |
48 | | -memory layout and metadata sections of the STM32U5, the Makefile surgically |
49 | | -extracts executable sections (stripping metadata like `.ARM.attributes`) before |
50 | | -flashing to prevent errors when writing to protected system memory addresses. |
| 49 | +This board is flashed using **`openocd`**. The Makefile handles the necessary |
| 50 | +initialization and mass erase before programming. |
51 | 51 |
|
52 | 52 | ### OpenOCD Requirements |
53 | 53 |
|
|
0 commit comments