diff --git a/boards/pimoroni/pico_plus2/Kconfig.defconfig b/boards/pimoroni/pico_plus2/Kconfig.defconfig new file mode 100644 index 000000000000000..35cdf92705462f1 --- /dev/null +++ b/boards/pimoroni/pico_plus2/Kconfig.defconfig @@ -0,0 +1,9 @@ +# Copyright (c) 2024 TOKITA Hiroshi +# SPDX-License-Identifier: Apache-2.0 + +if BOARD_PICO_PLUS2 + +config USB_SELF_POWERED + default n + +endif # BOARD_PICO_PLUS2 diff --git a/boards/pimoroni/pico_plus2/Kconfig.pico_plus2 b/boards/pimoroni/pico_plus2/Kconfig.pico_plus2 new file mode 100644 index 000000000000000..cd30fda60aeac56 --- /dev/null +++ b/boards/pimoroni/pico_plus2/Kconfig.pico_plus2 @@ -0,0 +1,5 @@ +# Copyright (c) 2024 TOKITA Hiroshi +# SPDX-License-Identifier: Apache-2.0 + +config BOARD_PICO_PLUS2 + select SOC_RP2350B_M33 if BOARD_PICO_PLUS2_RP2350B_M33 diff --git a/boards/pimoroni/pico_plus2/board.cmake b/boards/pimoroni/pico_plus2/board.cmake new file mode 100644 index 000000000000000..feae063129ac7ac --- /dev/null +++ b/boards/pimoroni/pico_plus2/board.cmake @@ -0,0 +1,18 @@ +# SPDX-License-Identifier: Apache-2.0 + +if("${RPI_PICO_DEBUG_ADAPTER}" STREQUAL "") + set(RPI_PICO_DEBUG_ADAPTER "cmsis-dap") +endif() + +board_runner_args(openocd --cmd-pre-init "source [find interface/${RPI_PICO_DEBUG_ADAPTER}.cfg]") +board_runner_args(openocd --cmd-pre-init "source [find target/rp2350.cfg]") + +# The adapter speed is expected to be set by interface configuration. +# The Raspberry Pi's OpenOCD fork doesn't, so match their documentation at +# https://www.raspberrypi.com/documentation/microcontrollers/debug-probe.html#debugging-with-swd +board_runner_args(openocd --cmd-pre-init "set_adapter_speed_if_not_set 5000") + +board_runner_args(uf2 "--board-id=RP2350") + +include(${ZEPHYR_BASE}/boards/common/openocd.board.cmake) +include(${ZEPHYR_BASE}/boards/common/uf2.board.cmake) diff --git a/boards/pimoroni/pico_plus2/board.yml b/boards/pimoroni/pico_plus2/board.yml new file mode 100644 index 000000000000000..71acca8e80e8899 --- /dev/null +++ b/boards/pimoroni/pico_plus2/board.yml @@ -0,0 +1,6 @@ +board: + name: pico_plus2 + full_name: Pimoroni Pico Plus2 + vendor: pimoroni + socs: + - name: rp2350b diff --git a/boards/pimoroni/pico_plus2/doc/index.rst b/boards/pimoroni/pico_plus2/doc/index.rst new file mode 100644 index 000000000000000..b385e4f71dcc2ff --- /dev/null +++ b/boards/pimoroni/pico_plus2/doc/index.rst @@ -0,0 +1,215 @@ +.. zephyr:board:: pico_plus2 + +Overview +******** + +The Raspberry Pi Pico and Pico W are small, low-cost, versatile boards from +Raspberry Pi. They are equipped with an RP2040 SoC, an on-board LED, +a USB connector, and an SWD interface. The Pico W additionally contains an +Infineon CYW43439 2.4 GHz Wi-Fi/Bluetooth module. The USB bootloader allows the +ability to flash without any adapter, in a drag-and-drop manner. +It is also possible to flash and debug the boards with their SWD interface, +using an external adapter. + +Hardware +******** + +- Dual Cortex-M33 or Hazard3 processors at up to 150MHz +- 520KB of SRAM, and 4MB of on-board flash memory +- USB 1.1 with device and host support +- Low-power sleep and dormant modes +- Drag-and-drop programming using mass storage over USB +- 26 multi-function GPIO pins including 3 that can be used for ADC +- 2 SPI, 2 I2C, 2 UART, 3 12-bit 500ksps Analogue to Digital - Converter (ADC), 24 controllable PWM channels +- 2 Timer with 4 alarms, 1 AON Timer +- Temperature sensor +- 3 Programmable IO (PIO) blocks, 12 state machines total for custom peripheral support + +.. figure:: img/rpi_pico.jpg + :align: center + :alt: Raspberry Pi Pico + + Raspberry Pi Pico (above) and Pico W (below) + (Images courtesy of Raspberry Pi) + +Supported Features +================== + +The ``pico_plus2/rp2350b/m33`` board target supports the following +hardware features: + +.. list-table:: + :header-rows: 1 + + * - Peripheral + - Kconfig option + - Devicetree compatible + * - NVIC + - N/A + - :dtcompatible:`arm,v8m-nvic` + * - ADC + - :kconfig:option:`CONFIG_ADC` + - :dtcompatible:`raspberrypi,pico-adc` + * - Clock controller + - :kconfig:option:`CONFIG_CLOCK_CONTROL` + - :dtcompatible:`raspberrypi,pico-clock-controller` + * - Counter + - :kconfig:option:`CONFIG_COUNTER` + - :dtcompatible:`raspberrypi,pico-timer` + * - DMA + - :kconfig:option:`CONFIG_DMA` + - :dtcompatible:`raspberrypi,pico-dma` + * - GPIO + - :kconfig:option:`CONFIG_GPIO` + - :dtcompatible:`raspberrypi,pico-gpio` + * - HWINFO + - :kconfig:option:`CONFIG_HWINFO` + - N/A + * - I2C + - :kconfig:option:`CONFIG_I2C` + - :dtcompatible:`snps,designware-i2c` + * - PWM + - :kconfig:option:`CONFIG_PWM` + - :dtcompatible:`raspberrypi,pico-pwm` + * - SPI + - :kconfig:option:`CONFIG_SPI` + - :dtcompatible:`raspberrypi,pico-spi` + * - UART + - :kconfig:option:`CONFIG_SERIAL` + - :dtcompatible:`raspberrypi,pico-uart` + * - UART (PIO) + - :kconfig:option:`CONFIG_SERIAL` + - :dtcompatible:`raspberrypi,pico-uart-pio` + + +Programming and Debugging +************************* + +Flashing +======== + +Using OpenOCD +------------- + +To use CMSIS-DAP, You must configure **udev**. + +Create a file in /etc/udev.rules.d with any name, and write the line below. + +.. code-block:: bash + + ATTRS{idVendor}=="2e8a", ATTRS{idProduct}=="000c", MODE="660", GROUP="plugdev", TAG+="uaccess" + +This example is valid for the case that the user joins to `plugdev` groups. + +The Raspberry Pi Pico has an SWD interface that can be used to program +and debug the on board RP2040. This interface can be utilized by OpenOCD. +To use it with the RP2040, OpenOCD version 0.12.0 or later is needed. + +If you are using a Debian based system (including RaspberryPi OS, Ubuntu. and more), +using the `pico_setup.sh`_ script is a convenient way to set up the forked version of OpenOCD. + +Depending on the interface used (such as JLink), you might need to +checkout to a branch that supports this interface, before proceeding. +Build and install OpenOCD as described in the README. + +Here is an example of building and flashing the :zephyr:code-sample:`blinky` application. + +.. zephyr-app-commands:: + :zephyr-app: samples/basic/blinky + :board: rpi_pico + :goals: build flash + :gen-args: -DOPENOCD=/usr/local/bin/openocd -DOPENOCD_DEFAULT_PATH=/usr/local/share/openocd/scripts -DRPI_PICO_DEBUG_ADAPTER=cmsis-dap + +Set the environment variables **OPENOCD** to `/usr/local/bin/openocd` +and **OPENOCD_DEFAULT_PATH** to `/usr/local/share/openocd/scripts`. This should work +with the OpenOCD that was installed with the default configuration. +This configuration also works with an environment that is set up by the `pico_setup.sh`_ script. + +**RPI_PICO_DEBUG_ADAPTER** specifies what debug adapter is used for debugging. + +If **RPI_PICO_DEBUG_ADAPTER** was not assigned, `cmsis-dap` is used by default. +The other supported adapters are `raspberrypi-swd`, `jlink` and `blackmagicprobe`. +How to connect `cmsis-dap` and `raspberrypi-swd` is described in `Getting Started with Raspberry Pi Pico`_. +Any other SWD debug adapter maybe also work with this configuration. + +The value of **RPI_PICO_DEBUG_ADAPTER** is cached, so it can be omitted from +`west flash` and `west debug` if it was previously set while running `west build`. + +**RPI_PICO_DEBUG_ADAPTER** is used in an argument to OpenOCD as `"source [find interface/${RPI_PICO_DEBUG_ADAPTER}.cfg]"`. +Thus, **RPI_PICO_DEBUG_ADAPTER** needs to be assigned the file name of the debug adapter. + +You can also flash the board with the following +command that directly calls OpenOCD (assuming a SEGGER JLink adapter is used): + +.. code-block:: console + + $ openocd -f interface/jlink.cfg -c 'transport select swd' -f target/rp2040.cfg -c "adapter speed 2000" -c 'targets rp2040.core0' -c 'program path/to/zephyr.elf verify reset exit' + +Using UF2 +--------- + +If you don't have an SWD adapter, you can flash the Raspberry Pi Pico with +a UF2 file. By default, building an app for this board will generate a +`build/zephyr/zephyr.uf2` file. If the Pico is powered on with the `BOOTSEL` +button pressed, it will appear on the host as a mass storage device. The +UF2 file should be drag-and-dropped to the device, which will flash the Pico. + +Debugging +========= + +The SWD interface can also be used to debug the board. To achieve this, you can +either use SEGGER JLink or OpenOCD. + +Using SEGGER JLink +------------------ + +Use a SEGGER JLink debug probe and follow the instruction in +:ref:`Building, Flashing and Debugging`. + + +Using OpenOCD +------------- + +Install OpenOCD as described for flashing the board. + +Here is an example for debugging the :zephyr:code-sample:`blinky` application. + +.. zephyr-app-commands:: + :zephyr-app: samples/basic/blinky + :board: rpi_pico + :maybe-skip-config: + :goals: debug + :gen-args: -DOPENOCD=/usr/local/bin/openocd -DOPENOCD_DEFAULT_PATH=/usr/local/share/openocd/scripts -DRPI_PICO_DEBUG_ADAPTER=raspberrypi-swd + +As with flashing, you can specify the debug adapter by specifying **RPI_PICO_DEBUG_ADAPTER** +at `west build` time. No needs to specify it at `west debug` time. + +You can also debug with OpenOCD and gdb launching from command-line. +Run the following command: + +.. code-block:: console + + $ openocd -f interface/jlink.cfg -c 'transport select swd' -f target/rp2040.cfg -c "adapter speed 2000" -c 'targets rp2040.core0' + +On another terminal, run: + +.. code-block:: console + + $ gdb-multiarch + +Inside gdb, run: + +.. code-block:: console + + (gdb) tar ext :3333 + (gdb) file path/to/zephyr.elf + +You can then start debugging the board. + +.. target-notes:: + +.. _pico_setup.sh: + https://raw.githubusercontent.com/raspberrypi/pico-setup/master/pico_setup.sh + +.. _Getting Started with Raspberry Pi Pico: + https://datasheets.raspberrypi.com/pico/getting-started-with-pico.pdf diff --git a/boards/pimoroni/pico_plus2/pico_plus2-pinctrl.dtsi b/boards/pimoroni/pico_plus2/pico_plus2-pinctrl.dtsi new file mode 100644 index 000000000000000..4fac42ca4415783 --- /dev/null +++ b/boards/pimoroni/pico_plus2/pico_plus2-pinctrl.dtsi @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2024 TOKITA Hiroshi + * SPDX-License-Identifier: Apache-2.0 + */ + +#include + +&pinctrl { + uart0_default: uart0_default { + group1 { + pinmux = ; + }; + group2 { + pinmux = ; + input-enable; + }; + }; + + i2c0_default: i2c0_default { + group1 { + pinmux = , ; + input-enable; + input-schmitt-enable; + }; + }; + + spi0_default: spi0_default { + group1 { + pinmux = , , ; + }; + group2 { + pinmux = ; + input-enable; + }; + }; + + pwm_ch4b_default: pwm_ch4b_default { + group1 { + pinmux = ; + }; + }; + + adc_default: adc_default { + group1 { + pinmux = , , , ; + input-enable; + }; + }; +}; diff --git a/boards/pimoroni/pico_plus2/pico_plus2.dtsi b/boards/pimoroni/pico_plus2/pico_plus2.dtsi new file mode 100644 index 000000000000000..5d89be80d61df1f --- /dev/null +++ b/boards/pimoroni/pico_plus2/pico_plus2.dtsi @@ -0,0 +1,174 @@ +/* + * Copyright (c) 2024 TOKITA Hiroshi + * + * SPDX-License-Identifier: Apache-2.0 + */ + +#include + +#include +#include +#include + +#include "pico_plus2-pinctrl.dtsi" + +/ { + chosen { + zephyr,sram = &sram0; + zephyr,flash = &flash0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + zephyr,code-partition = &code_partition; + }; + + aliases { + watchdog0 = &wdt0; + led0 = &led0; + pwm-led0 = &pwm_led0; + sw0 = &user_sw; + }; + + leds { + compatible = "gpio-leds"; + led0: led_0 { + gpios = <&gpio0 25 GPIO_ACTIVE_HIGH>; + label = "LED"; + }; + }; + + pwm_leds { + compatible = "pwm-leds"; + status = "disabled"; + pwm_led0: pwm_led_0 { + pwms = <&pwm 9 PWM_MSEC(20) PWM_POLARITY_NORMAL>; + label = "PWM_LED"; + }; + }; + + buttons { + compatible = "gpio-keys"; + user_sw: user_sw { + gpios = <&gpio0 45 (GPIO_ACTIVE_LOW)>; + zephyr,code = ; + }; + }; + + pico_header: connector { + compatible = "raspberrypi,pico-header"; + #gpio-cells = <2>; + gpio-map-mask = <0xffffffff 0xffffffc0>; + gpio-map-pass-thru = <0 0x3f>; + gpio-map = <0 0 &gpio0 0 0>, /* GP0 */ + <1 0 &gpio0 1 0>, /* GP1 */ + <2 0 &gpio0 2 0>, /* GP2 */ + <3 0 &gpio0 3 0>, /* GP3 */ + <4 0 &gpio0 4 0>, /* GP4 */ + <5 0 &gpio0 5 0>, /* GP5 */ + <6 0 &gpio0 6 0>, /* GP6 */ + <7 0 &gpio0 7 0>, /* GP7 */ + <8 0 &gpio0 8 0>, /* GP8 */ + <9 0 &gpio0 9 0>, /* GP9 */ + <10 0 &gpio0 10 0>, /* GP10 */ + <11 0 &gpio0 11 0>, /* GP11 */ + <12 0 &gpio0 12 0>, /* GP12 */ + <13 0 &gpio0 13 0>, /* GP13 */ + <14 0 &gpio0 14 0>, /* GP14 */ + <15 0 &gpio0 15 0>, /* GP15 */ + <16 0 &gpio0 16 0>, /* GP16 */ + <17 0 &gpio0 17 0>, /* GP17 */ + <18 0 &gpio0 18 0>, /* GP18 */ + <19 0 &gpio0 19 0>, /* GP19 */ + <20 0 &gpio0 20 0>, /* GP20 */ + <21 0 &gpio0 21 0>, /* GP21 */ + <22 0 &gpio0 22 0>, /* GP22 */ + <26 0 &gpio0 26 0>, /* GP26 */ + <27 0 &gpio0 27 0>, /* GP27 */ + <28 0 &gpio0 28 0>; /* GP28 */ + }; +}; + +&flash0 { + reg = <0x10000000 DT_SIZE_M(16)>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + /* Reserved memory for an image definition block. The block is much + * smaller than 256 bytes, but in practice the linker places the vector + * table at a much larger alignment offset. + */ + image_def: partition@0 { + label = "image_def"; + reg = <0x00000000 0x100>; + read-only; + }; + + /* + * Usable flash. Starts at 0x100, after the image definition block. + * The partition size is 16MB minus the 0x100 bytes taken by the + * image definition. + */ + code_partition: partition@100 { + label = "code-partition"; + reg = <0x100 (DT_SIZE_M(16) - 0x100)>; + read-only; + }; + }; +}; + +&uart0 { + current-speed = <115200>; + status = "okay"; + pinctrl-0 = <&uart0_default>; + pinctrl-names = "default"; +}; + +&gpio0_lo { + status = "okay"; +}; + +&gpio0_hi { + status = "okay"; +}; + +&spi0 { + clock-frequency = ; + pinctrl-0 = <&spi0_default>; + pinctrl-names = "default"; +}; + +&i2c0 { + clock-frequency = ; + pinctrl-0 = <&i2c0_default>; + pinctrl-names = "default"; + status = "okay"; +}; + +&adc { + pinctrl-0 = <&adc_default>; + pinctrl-names = "default"; + status = "okay"; +}; + +&pwm { + pinctrl-0 = <&pwm_ch4b_default>; + pinctrl-names = "default"; + divider-int-0 = <255>; +}; + +&timer0 { + status = "okay"; +}; + +zephyr_udc0: &usbd { + status = "okay"; +}; + + +pico_spi: &spi0 {}; +pico_i2c0: &i2c0 {}; +pico_i2c1: &i2c1 {}; +pico_serial: &uart0 {}; +stemma_qt_i2c: &i2c0 {}; diff --git a/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33.dts b/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33.dts new file mode 100644 index 000000000000000..425c2237f7350dd --- /dev/null +++ b/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33.dts @@ -0,0 +1,22 @@ +/* + * Copyright (c) 2024 TOKITA Hiroshi + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; + +/* The build system assumes that there's a cpucluster-specific file. + * + * This file provides composition of the device tree: + * 1. The common features of the SoC + * 2. Core-specific configuration. + * 3. Board-specific configuration. + */ +#include +#include + +/* there's nothing specific to the Cortex-M33 cores vs the (not yet + * implemented) Hazard3 cores. + */ +#include "pico_plus2.dtsi" diff --git a/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33.yaml b/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33.yaml new file mode 100644 index 000000000000000..1bde160f14ad594 --- /dev/null +++ b/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33.yaml @@ -0,0 +1,21 @@ +identifier: pico_plus2/rp2350b/m33 +name: Pimoroni Pico Plus2 (Cortex-M33) +type: mcu +arch: arm +flash: 16384 +ram: 8192 +toolchain: + - zephyr + - gnuarmemb + - xtools +supported: + - adc + - clock + - counter + - dma + - gpio + - hwinfo + - i2c + - pwm + - spi + - uart diff --git a/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33_defconfig b/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33_defconfig new file mode 100644 index 000000000000000..8bd68e3511391d1 --- /dev/null +++ b/boards/pimoroni/pico_plus2/pico_plus2_rp2350b_m33_defconfig @@ -0,0 +1,14 @@ +# This configuration is orthogonal to whether the Cortex-M33 or Hazard3 cores +# are in use, but Zephyr does not support providing a qualifier-agnostic +# _defconfig file. +CONFIG_BUILD_OUTPUT_HEX=y +CONFIG_BUILD_OUTPUT_UF2=y +CONFIG_CLOCK_CONTROL=y +CONFIG_CONSOLE=y +CONFIG_GPIO=y +CONFIG_RESET=y +CONFIG_SERIAL=y +CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC=150000000 +CONFIG_UART_CONSOLE=y +CONFIG_UART_INTERRUPT_DRIVEN=y +CONFIG_USE_DT_CODE_PARTITION=y diff --git a/boards/pimoroni/pico_plus2/support/openocd.cfg b/boards/pimoroni/pico_plus2/support/openocd.cfg new file mode 100644 index 000000000000000..82666bb53314ce7 --- /dev/null +++ b/boards/pimoroni/pico_plus2/support/openocd.cfg @@ -0,0 +1,11 @@ +# Copyright (c) 2024 TOKITA Hiroshi +# SPDX-License-Identifier: Apache-2.0 + +# Checking and set 'adapter speed'. +# Set the adaptor speed, if unset, and given as an argument. +proc set_adapter_speed_if_not_set { speed } { + puts "checking adapter speed..." + if { [catch {adapter speed} ret] } { + adapter speed $speed + } +} diff --git a/dts/bindings/vendor-prefixes.txt b/dts/bindings/vendor-prefixes.txt index ee115b920f6fd36..e8e7ce7df442227 100644 --- a/dts/bindings/vendor-prefixes.txt +++ b/dts/bindings/vendor-prefixes.txt @@ -510,6 +510,7 @@ pervasive Pervasive Displays, Inc. phicomm PHICOMM Co., Ltd. phytec PHYTEC picochip Picochip Ltd +pimoroni Pimoroni Ltd. pine64 Pine64 pineriver Shenzhen PineRiver Designs Co., Ltd. pixart PixArt Imaging Inc. diff --git a/samples/drivers/adc/adc_dt/boards/pico_plus2_rp2350a_m33.overlay b/samples/drivers/adc/adc_dt/boards/pico_plus2_rp2350a_m33.overlay new file mode 100644 index 000000000000000..abf2d227844b99f --- /dev/null +++ b/samples/drivers/adc/adc_dt/boards/pico_plus2_rp2350a_m33.overlay @@ -0,0 +1,24 @@ +/* + * SPDX-License-Identifier: Apache-2.0 + * + * Copyright (c) 2024 TOKITA Hiroshi + */ + +/ { + zephyr,user { + io-channels = <&adc 0>; + }; +}; + +&adc { + #address-cells = <1>; + #size-cells = <0>; + + channel@0 { + reg = <0>; + zephyr,gain = "ADC_GAIN_1"; + zephyr,reference = "ADC_REF_INTERNAL"; + zephyr,acquisition-time = ; + zephyr,resolution = <12>; + }; +}; diff --git a/samples/drivers/counter/alarm/src/main.c b/samples/drivers/counter/alarm/src/main.c index deb64e21540e112..8881b1675a32130 100644 --- a/samples/drivers/counter/alarm/src/main.c +++ b/samples/drivers/counter/alarm/src/main.c @@ -52,7 +52,10 @@ struct counter_alarm_cfg alarm_cfg; #elif defined(CONFIG_COUNTER_SNPS_DW) #define TIMER DT_NODELABEL(timer0) #elif defined(CONFIG_COUNTER_TIMER_RPI_PICO) +#ifdef CONFIG_SOC_SERIES_RP2040 #define TIMER DT_NODELABEL(timer) +#elif CONFIG_SOC_SERIES_RP2350 +#define TIMER DT_NODELABEL(timer0) #elif defined(CONFIG_COUNTER_TIMER_MAX32) #define TIMER DT_NODELABEL(counter0) #elif defined(CONFIG_COUNTER_RA_AGT) diff --git a/samples/drivers/led/pwm/boards/pico_plus2_rp2350a_m33.overlay b/samples/drivers/led/pwm/boards/pico_plus2_rp2350a_m33.overlay new file mode 100644 index 000000000000000..565dcd6fbbab9ee --- /dev/null +++ b/samples/drivers/led/pwm/boards/pico_plus2_rp2350a_m33.overlay @@ -0,0 +1,15 @@ +/ { + leds { + status = "disabled"; + }; + + pwm_leds { + status = "okay"; + }; +}; + +&pwm { + status = "okay"; + divider-frac-4 = <15>; + divider-int-4 = <255>; +}; diff --git a/samples/sensor/die_temp_polling/boards/pico_plus2_rp2350a_m33.conf b/samples/sensor/die_temp_polling/boards/pico_plus2_rp2350a_m33.conf new file mode 100644 index 000000000000000..488a81dca52041f --- /dev/null +++ b/samples/sensor/die_temp_polling/boards/pico_plus2_rp2350a_m33.conf @@ -0,0 +1 @@ +CONFIG_ADC=y diff --git a/samples/sensor/die_temp_polling/boards/pico_plus2_rp2350a_m33.overlay b/samples/sensor/die_temp_polling/boards/pico_plus2_rp2350a_m33.overlay new file mode 100644 index 000000000000000..38f5ece1c98a1be --- /dev/null +++ b/samples/sensor/die_temp_polling/boards/pico_plus2_rp2350a_m33.overlay @@ -0,0 +1,9 @@ +/* + * SPDX-License-Identifier: Apache-2.0 + * + * Copyright (c) 2024 TOKITA Hiroshi + */ + +&die_temp { + status = "okay"; +}; diff --git a/tests/drivers/dma/loop_transfer/boards/pico_plus2_rp2350a_m33.overlay b/tests/drivers/dma/loop_transfer/boards/pico_plus2_rp2350a_m33.overlay new file mode 100644 index 000000000000000..35ee84e3c4ea8eb --- /dev/null +++ b/tests/drivers/dma/loop_transfer/boards/pico_plus2_rp2350a_m33.overlay @@ -0,0 +1,9 @@ +/* + * Copyright (c) 2023 Tokita, Hiroshi + * + * SPDX-License-Identifier: Apache-2.0 + */ + +tst_dma0: &dma { + status = "okay"; +}; diff --git a/tests/drivers/spi/spi_loopback/boards/pico_plus2_rp2350a_m33.conf b/tests/drivers/spi/spi_loopback/boards/pico_plus2_rp2350a_m33.conf new file mode 100644 index 000000000000000..53e8607eb619f32 --- /dev/null +++ b/tests/drivers/spi/spi_loopback/boards/pico_plus2_rp2350a_m33.conf @@ -0,0 +1 @@ +CONFIG_SPI_PL022_DMA=y diff --git a/tests/drivers/spi/spi_loopback/boards/pico_plus2_rp2350a_m33.overlay b/tests/drivers/spi/spi_loopback/boards/pico_plus2_rp2350a_m33.overlay new file mode 100644 index 000000000000000..c6f4ecb40b6188e --- /dev/null +++ b/tests/drivers/spi/spi_loopback/boards/pico_plus2_rp2350a_m33.overlay @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2022 TOKITA Hiroshi + * + * SPDX-License-Identifier: Apache-2.0 + */ + +#include + +&dma { + status = "okay"; +}; + +&spi0 { + cs-gpios = <&gpio0 17 GPIO_ACTIVE_LOW>; + + dmas = <&dma 0 RPI_PICO_DMA_SLOT_SPI0_TX 0>, <&dma 1 RPI_PICO_DMA_SLOT_SPI0_RX 0>; + dma-names = "tx", "rx"; + + slow@0 { + compatible = "test-spi-loopback-slow"; + reg = <0>; + spi-max-frequency = <500000>; + }; + fast@0 { + compatible = "test-spi-loopback-fast"; + reg = <0>; + spi-max-frequency = <16000000>; + }; +};