Skip to content

Commit 234793e

Browse files
committed
Use overlay for nucleo_f429zi board to place storage map at the correct place in memory.
1 parent e31e393 commit 234793e

File tree

2 files changed

+26
-18
lines changed

2 files changed

+26
-18
lines changed

zephyr/samples/profiles/b-sa/prj.conf

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,16 @@ CONFIG_INIT_STACKS=y
2424
CONFIG_BACNETSTACK=y
2525
CONFIG_BACNETSTACK_LOG_LEVEL=3
2626
CONFIG_BACNETSTACK_BACNET_BASIC=y
27+
# BACnet settings subsystem
28+
CONFIG_BACNETSTACK_BACNET_SETTINGS=y
29+
CONFIG_BACNET_SETTINGS_SHELL=y
30+
# the dependencies of the SETTINGS option.
31+
CONFIG_FLASH=y
32+
CONFIG_FLASH_MAP=y
33+
CONFIG_NVS=y
34+
CONFIG_SETTINGS=y
35+
CONFIG_SETTINGS_NVS=y
36+
CONFIG_SETTINGS_RUNTIME=y
2737
# BACnet Library - options
2838
CONFIG_BACNET_MAX_CHARACTER_STRING_BYTES=128
2939
CONFIG_BACAPP_MINIMAL=y
Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,19 @@
1-
/**
2-
* @file
3-
* @brief Override existing Nucleo F429ZI board for the BACnet sample.
4-
* @author Steve Karg <[email protected]>
5-
* @date January 2025
6-
* @copyright SPDX-License-Identifier: Apache-2.0
1+
/*
2+
* Copyright (c) 2022 STMicroelectronics
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
75
*/
8-
/delete-node/ &storage_partition;
6+
7+
/delete-node/ &storage_partition;
8+
99
&flash0 {
10-
partitions {
11-
/* Configure storage for NVS: rules from nvs.h: uint16_t sector_size
12-
a) shall be more than one sector
13-
b) each sector shall be the same size
14-
c) each sector shalle be smaller than 64KB
15-
*/
16-
storage_partition: partition@100000 {
17-
label = "storage";
18-
reg = <0x000100000 DT_SIZE_K(48)>;
19-
};
20-
};
10+
partitions {
11+
/* Set 48KB of storage at the beginning of bank2 in order to have 3 sectors smaller than 32K
12+
* (nvs.h: uint16_t sector_size)
13+
*/
14+
storage_partition: partition@100000 {
15+
label = "storage";
16+
reg = <0x000100000 DT_SIZE_K(48)>;
17+
};
18+
};
2119
};

0 commit comments

Comments
 (0)