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
Copy file name to clipboardExpand all lines: boot/cypress/BlinkyApp/Readme.md
+5-2Lines changed: 5 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,6 +15,8 @@ Functionality:
15
15
Currently supported platforms
16
16
17
17
* PSOC_062_2M
18
+
* PSOC_062_1M
19
+
* PSOC_062_512K
18
20
19
21
### Hardware limitations
20
22
@@ -31,7 +33,7 @@ These values are set by specifing following macros: `-DUSER_APP_SIZE`, `-DUSER_A
31
33
Pre-build action calls GCC preprocessor which intantiates defines for particular values in `BlinkyApp_template.ld`.
32
34
33
35
Default values set for currently supported targets:
34
-
*PSOC_062_2M in `BlinkyApp.mk` to `-DUSER_APP_START=0x10018000`
36
+
*`BlinkyApp.mk` to `-DUSER_APP_START=0x10018000`
35
37
36
38
**Important**: make sure RAM areas of CM4-based BlinkyApp and CM0p-based MCUBootApp bootloader do not overlap.
37
39
Memory (stack) corruption of CM0p application can cause failure if SystemCall-served operations invoked from CM4.
@@ -40,7 +42,7 @@ Memory (stack) corruption of CM0p application can cause failure if SystemCall-se
40
42
41
43
Root directory for build is **boot/cypress.**
42
44
43
-
The following command will build regular HEX file of a BlinkyApp for BOOT slot:
45
+
The following command will build regular HEX file of a BlinkyApp for BOOT slot. Substitute `PLATFORM=` to a paltform name you use in all following commands.
44
46
45
47
make app APP_NAME=BlinkyApp PLATFORM=PSOC_062_2M IMG_TYPE=BOOT
46
48
@@ -135,6 +137,7 @@ Files to use for programming are:
135
137
-`MAKEINFO` - 0 (default) - less build info, 1 - verbose output of compilation.
136
138
-`HEADER_OFFSET` - 0 (default) - no offset of output hex file, 0x%VALUE% - offset for output hex file. Value 0x10000 is slot size MCUBoot Bootloader in this example.
137
139
-`IMG_TYPE` - `BOOT` (default) - build image for BOOT slot of MCUBoot Bootloader, `UPGRADE` - build image for UPGRADE slot of MCUBoot Bootloader.
140
+
-`ENC_IMG` - 0 (default) - build regular upgrade image, `1` - build encrypted upgrade image (MCUBootApp should also be built with this flash set 1)
138
141
139
142
**NOTE**: In case of `UPGRADE` image `HEADER_OFFSET` should be set to MCUBoot Bootloader slot size.
* BlinkyApp - simple PSoC6 blinking LED application which is a target of BOOT/UPGRADE;
10
10
11
-
The demonstration device is CY8CPROTO-062-4343W board which is PSoC6 device with 2M of Flash available.
11
+
Cypress boards, that can be used with this evaluation example:
12
+
- CY8CPROTO-062-4343W - PSoC 6 2M on board
13
+
- CY8CKIT-062-WIFI-BT - PSoC 6 1M on board
14
+
- CY8CPROTO-062S3-4343W - PSoC 6 512K on board
12
15
The default flash map implemented is the following:
13
16
14
17
Single-image mode.
@@ -118,7 +121,7 @@ Since this application is created to demonstrate MCUBoot library features and no
118
121
119
122
1.`SCB5` used to configure serial port for debug prints. This is the most commonly used Serial Communication Block number among available Cypress PSoC 6 kits. If you try to use custom hardware with this application - change definition of `CYBSP_UART_HW` in `main.c` of MCUBootApp to SCB* that correspond to your design.
120
123
121
-
2.`CY_SMIF_SLAVE_SELECT_0` is used as definition SMIF driver API. This configuration is used on evaluation kit for this example CY8CPROTO-062-4343W. If you try to use custom hardware with this application - change value of `smif_id` in `main.c` of MCUBootApp to value that corresponds to your design.
124
+
2.`CY_SMIF_SLAVE_SELECT_0` is used as definition SMIF driver API. This configuration is used on evaluation kit for this example CY8CPROTO-062-4343W, CY8PROTO-062S3-4343W, CY8CKIT-062-4343W. If you try to use custom hardware with this application - change value of `smif_id` in `main.c` of MCUBootApp to value that corresponds to your design.
122
125
123
126
124
127
### Downloading Solution's Assets
@@ -146,17 +149,24 @@ This folder contains make files infrastructure for building MCUBoot Bootloader.
146
149
147
150
make app APP_NAME=MCUBootApp PLATFORM=PSOC_062_2M BUILDCFG=Release MCUBOOT_IMAGE_NUMBER=2
148
151
152
+
* To Build MCUBootApp with external memory support - pass `USE_EXTERNAL_FLASH=1` flag to `make` command in examples above. In this case UPGRADE image will be located in external memory. Refer to ExternalMemory.md for additional details.
153
+
149
154
Root directory for build is **boot/cypress.**
150
155
151
156
**Encrypted Image Support**
152
157
153
-
To protect user image from unwanted read Upgrade Image Encryption can be applied. The ECDH/HKDF with EC256 scheme is used in a given solution as well as mbedTLS as a crypto provider.
158
+
To protect user image from unwanted read - Upgrade Image Encryption can be applied. The ECDH/HKDF with EC256 scheme is used in a given solution as well as mbedTLS as a crypto provider.
159
+
160
+
To enable image encryption support use `ENC_IMG=1` build flag (BlinkyApp should also be built with this flash set 1).
154
161
155
-
To enable image encryption support `MCUBOOT_ENC_IMAGES` and `MCUBOOT_ENCRYPT_EC256` have to be defined (can be done by uncommenting in `mcuboot_config.h`).
156
-
User is also responsible on providing corresponding binary key data in `enc_priv_key[]` (file `\MCUBootApp\keys.c`). The public part will be used by imgtool when signing and encrypting upgrade image. Signing image with encryption is described in `\BlinkyApp\readme.md`.
162
+
User is also responsible for providing corresponding binary key data in `enc_priv_key[]` (file `\MCUBootApp\keys.c`). The public part will be used by imgtool when signing and encrypting upgrade image. Signing image with encryption is described in `\BlinkyApp\Readme.md`.
157
163
158
164
After MCUBootApp is built with these settings unencrypted and encrypted images will be accepted in secondary (upgrade) slot.
159
165
166
+
Example command:
167
+
168
+
make app APP_NAME=MCUBootApp PLATFORM=PSOC_062_2M BUILDCFG=Debug MCUBOOT_IMAGE_NUMBER=1 ENC_IMG=1
169
+
160
170
**Programming solution**
161
171
162
172
There are couple ways of programming hex of MCUBootApp and BlinkyApp. Following instructions assume one of Cypress development kits, for example `CY8CPROTO_062_4343W`.
@@ -186,6 +196,8 @@ Connect a board to your computer. Switch Kitprog3 to DAP-BULK mode by pressing `
186
196
**Currently supported platforms:**
187
197
188
198
* PSOC_062_2M
199
+
* PSOC_062_1M
200
+
* PSOC_062_512K
189
201
190
202
**Build environment troubleshooting:**
191
203
@@ -205,9 +217,5 @@ Also IDE may be used:
205
217
206
218
*Msys2* - to use systems PATH navigate to msys2 folder, open `msys2_shell.cmd`, uncomment set `MSYS2_PATH_TYPE=inherit`, restart MSYS2 shell.
207
219
208
-
*Cygwin* - add following to build command `CURDIR=pwd | cygpath --mixed -f -` so that build command looks like that:
209
-
210
-
make app APP_NAME=MCUBootApp PLATFORM=PSOC_062_2M CURDIR=`pwd | cygpath --mixed -f -`
211
-
212
220
This will iherit system's PATH so should find `python3.7` installed in regular way as well as imgtool and its dependencies.
Copy file name to clipboardExpand all lines: boot/cypress/README.md
+6-4Lines changed: 6 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -26,10 +26,10 @@ The default flash map for MCUBootApp implemented is next:
26
26
27
27
The flash map is defined through sysflash.h and cy_flash_map.c.
28
28
29
-
It is also possible to place secondary (upgrade) slots in external memory module so resulting image size can be doubled.
29
+
It is also possible to place secondary (upgrade) slots in external memory module. In this case primary slot can be doubled in size.
30
30
For more details about External Memory usage, please refer to separate guiding document `MCUBootApp/ExternalMemory.md`.
31
31
32
-
MCUBootApp checks image integrity with SHA256, image authenticity with EC256 digital signature verification and uses completely SW implementation of cryptographic functions based on mbedTLS Library.
32
+
MCUBootApp checks image integrity with SHA256, image authenticity with EC256 digital signature verification and uses either completely software implementation of cryptographic functions or accelerated by hardware - both based on mbedTLS Library.
33
33
34
34
### Downloading Solution's Assets
35
35
@@ -60,9 +60,11 @@ This folder contains make files infrastructure for building both MCUBoot Bootloa
60
60
61
61
Instructions on how to build and upload MCUBootApp bootloader application and sample user applocation are located in `Readme.md` files in corresponding folders.
0 commit comments