Zephyr on Make Pi R2040
code:shell
$ cp -R boards/raspberrypi/rpi_pico boards/raspberrypi/maker-pi-rp2040/
$ boards/raspberrypi/maker-pi-rp2040/
$ for i in rpi_pico*
do
mv $i echo $i|sed -e 's/rpi_pico/maker-pi-rp2040/'
done
# Raspberry Pi Pico W用の定義を削除
$ rm *_w*
% grep rpi_pico *
board.cmake:# This configuration allows selecting what debug adapter debugging rpi_pico
board.cmake:# e.g.) west build -b rpi_pico -- -DRPI_PICO_DEBUG_ADAPTER=raspberrypi-swd
board.yml: name: rpi_pico
grep: doc: Is a directory
grep: maker-pi-rp2040: Is a directory
maker-pi-rp2040-common.dtsi:#include <raspberrypi/rpi_pico/rp2040.dtsi>
maker-pi-rp2040-common.dtsi:#include "rpi_pico-pinctrl.dtsi"
maker-pi-rp2040.dts:#include "rpi_pico-common.dtsi"
maker-pi-rp2040.yaml:identifier: rpi_pico
grep: support: Is a directory
$ mv Kconfig.rpi_pico Kconfig.maker-pi-rp2040
code:.diff
$ diff -u board.yml.org board.yml
--- board.yml.org 2025-01-14 11:22:52.000000000 +0900
+++ board.yml 2025-01-14 11:23:30.000000000 +0900
@@ -1,6 +1,6 @@
board:
- name: rpi_pico
- full_name: Raspberry Pi Pico
+ name: maker-pi-rp2040
+ full_name: Maker Pi RP2040
vendor: raspberrypi
socs:
- name: rp2040
code:.diff
$ diff -u maker-pi-rp2040-common.dtsi.org maker-pi-rp2040-common.dtsi
--- maker-pi-rp2040-common.dtsi.org 2025-01-14 11:25:24.000000000 +0900
+++ maker-pi-rp2040-common.dtsi 2025-01-14 11:26:12.000000000 +0900
@@ -7,7 +7,7 @@
#include <raspberrypi/rpi_pico/rp2040.dtsi> -#include "rpi_pico-pinctrl.dtsi"
+#include "maker-pi-rp2040-pinctrl.dtsi"
code:.diff
diff -u maker-pi-rp2040.yaml.org maker-pi-rp2040.yaml
--- maker-pi-rp2040.yaml.org 2025-01-14 11:27:04.000000000 +0900
+++ maker-pi-rp2040.yaml 2025-01-14 11:27:43.000000000 +0900
@@ -1,5 +1,5 @@
-identifier: rpi_pico
-name: RaspberryPi-Pico
+identifier: maker-pi-rp2040
+name: Maker-Pi-RP2040
type: mcu
arch: arm
flash: 2048
code:.diff
diff -u maker-pi-rp2040.dts.org maker-pi-rp2040.dts
--- maker-pi-rp2040.dts.org 2025-01-14 11:30:43.000000000 +0900
+++ maker-pi-rp2040.dts 2025-01-14 11:31:04.000000000 +0900
@@ -6,7 +6,7 @@
/dts-v1/;
-#include "rpi_pico-common.dtsi"
+#include "maker-pi-rp2040-common.dtsi"
/ {
leds {
code:err.sh
$ west build -p always -b maker-pi-rp2040 samples/basic/blinky
-- west build: making build dir /Users/mutoh/work/zephyrproject/zephyr/build pristine
-- west build: generating a build system
Loading Zephyr default modules (Zephyr base).
-- Application: /Users/mutoh/work/zephyrproject/zephyr/samples/basic/blinky
-- CMake version: 3.31.2
-- Found Python3: /Users/mutoh/work/zephyrproject/.venv/bin/python3.13 (found suitable version "3.13.1", minimum required is "3.10") found components: Interpreter
-- Cache files will be written to: /Users/mutoh/Library/Caches/zephyr
-- Zephyr version: 4.0.99 (/Users/mutoh/work/zephyrproject/zephyr)
-- Found west (found suitable version "1.3.0", minimum required is "0.14.0")
-- Board: maker-pi-rp2040, qualifiers: rp2040
-- ZEPHYR_TOOLCHAIN_VARIANT not set, trying to locate Zephyr SDK
-- Found host-tools: zephyr 0.17.0 (/Users/mutoh/zephyr-sdk-0.17.0)
-- Found toolchain: zephyr 0.17.0 (/Users/mutoh/zephyr-sdk-0.17.0)
-- Found Dtc: /usr/local/bin/dtc (found suitable version "1.7.2", minimum required is "1.4.6")
-- Found BOARD.dts: /Users/mutoh/work/zephyrproject/zephyr/boards/raspberrypi/maker-pi-rp2040/maker-pi-rp2040.dts
-- Generated zephyr.dts: /Users/mutoh/work/zephyrproject/zephyr/build/zephyr/zephyr.dts
-- Generated pickled edt: /Users/mutoh/work/zephyrproject/zephyr/build/zephyr/edt.pickle
-- Generated zephyr.dts: /Users/mutoh/work/zephyrproject/zephyr/build/zephyr/zephyr.dts
-- Generated devicetree_generated.h: /Users/mutoh/work/zephyrproject/zephyr/build/zephyr/include/generated/zephyr/devicetree_generated.h
-- Including generated dts.cmake file: /Users/mutoh/work/zephyrproject/zephyr/build/zephyr/dts.cmake
warning: USE_DT_CODE_PARTITION (defined at soc/st/stm32/Kconfig.defconfig:69,
soc/sensry/ganymed/sy1xx/Kconfig.defconfig:58, soc/renesas/smartbond/da1469x/Kconfig.defconfig:28,
Kconfig.zephyr:91) was assigned the value 'y' but got the value 'n'. Check these unsatisfied
dependencies: (SOC_FAMILY_STM32 || (SOC_SERIES_SY1XX && SOC_SERIES_SY1XX && SOC_FAMILY_GANYMED) ||
(SOC_SERIES_DA1469X && SOC_FAMILY_RENESAS_SMARTBOND) || HAS_FLASH_LOAD_OFFSET) (=n). See
USE_DT_CODE_PARTITION in the menuconfig/guiconfig interface. The Application Development Primer,
Setting Configuration Values, and Kconfig - Tips and Best Practices sections of
the manual might be helpful too.
warning: MICROBIT_DISPLAY (defined at drivers/display/Kconfig.microbit:6) was as signed the value 'y'
but got the value 'n'. Check these unsatisfied dependencies: (BOARD_BBC_MICROBIT ||BOARD_BBC_MICROBIT_V2) (=n). See
MICROBIT_DISPLAY in the menuconfig/guiconfig interface. The Application Development Primer, Setting
Configuration Values, and Kconfig - Tips and Best Practices sections of the manual might be helpful too.
warning: BOARD_RPI_PICO (defined at boards/raspberrypi/maker-pi-rp2040/Kconfig.maker-pi-rp2040:4, boards/raspberrypi/maker-pi-rp2040/Kconfig:4) defined without a type
Parsing /Users/mutoh/work/zephyrproject/zephyr/Kconfig
Loaded configuration '/Users/mutoh/work/zephyrproject/zephyr/boards/raspberrypi/maker-pi-rp2040/maker-pi-rp2040_defconfig'
Merged configuration '/Users/mutoh/work/zephyrproject/zephyr/samples/basic/blinky/prj.conf'
error: Aborting due to Kconfig warnings
CMake Error at /Users/mutoh/work/zephyrproject/zephyr/cmake/modules/kconfig.cmake:396 (message):
command failed with return code: 1
Call Stack (most recent call first):
/Users/mutoh/work/zephyrproject/zephyr/cmake/modules/zephyr_default.cmake:133 (include)
/Users/mutoh/work/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:66 (include)
/Users/mutoh/work/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92(include_boilerplate)
CMakeLists.txt:4 (find_package)
-- Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: /usr/local/bin/cmake -DWEST_PYTHON=/Users/mutoh/work/zephyrproject/.venv/bin/python3.13 -B/Users/mutoh/work/zephyrproject/zephyr/build -GNinja -DBOARD=maker-pi-rp2040 -S/Users/mutoh/work/zephyrproject/zephyr/samples/basic/blinky