-
Notifications
You must be signed in to change notification settings - Fork 627
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[nrf fromlist] soc: nordic: nrf54h: add BICR generation tooling
Add supporting scripts and build-system integration for BICR (Board Information Configuration Registers) generation. Upstream PR #: 81604 Signed-off-by: Gerard Marull-Paretas <[email protected]> (cherry picked from commit 2c4bdd33a0b87e6d5f9c58a59fd3ca554e03366b)
- Loading branch information
Showing
6 changed files
with
1,158 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
if(CONFIG_SOC_NRF54H20_GENERATE_BICR) | ||
set(bicr_json_file ${BOARD_DIR}/bicr.json) | ||
set(bicr_hex_file ${PROJECT_BINARY_DIR}/bicr.hex) | ||
set(svd_file ${ZEPHYR_HAL_NORDIC_MODULE_DIR}/nrfx/mdk/nrf54h20_application.svd) | ||
|
||
if(EXISTS ${bicr_json_file}) | ||
set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS ${bicr_json_file}) | ||
|
||
execute_process( | ||
COMMAND | ||
${Python3_EXECUTABLE} | ||
${CMAKE_CURRENT_LIST_DIR}/bicrgen.py | ||
--svd ${svd_file} | ||
--input ${bicr_json_file} | ||
--output ${bicr_hex_file} | ||
WORKING_DIRECTORY ${BOARD_DIR} | ||
COMMAND_ERROR_IS_FATAL ANY | ||
) | ||
message(STATUS "Generated BICR hex file: ${bicr_hex_file}") | ||
endif() | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Copyright (c) 2024 Nordic Semiconductor | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
config SOC_NRF54H20_GENERATE_BICR | ||
bool "Generate nRF54H20 BICR file" | ||
depends on SOC_NRF54H20_CPUAPP | ||
default y | ||
help | ||
This option generates a BICR file for the board being used. Board | ||
directory must contain a "bicr.json" file for this option to work. |
Oops, something went wrong.