1/* 2 * Copyright (c) 2024 The Zephyr Project Contributors 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7&pinctrl { 8 pio0_spi0_default: pio0_spi0_default { 9 /* gpio 17 is used for chip select, not assigned to the PIO */ 10 group1 { 11 pinmux = <PIO0_P18>, <PIO0_P19>; 12 }; 13 group2 { 14 pinmux = <PIO0_P16>; 15 input-enable; 16 }; 17 }; 18}; 19 20&pio0 { 21 status = "okay"; 22 23 pio0_spi0: pio0_spi0 { 24 pinctrl-0 = <&pio0_spi0_default>; 25 pinctrl-names = "default"; 26 27 compatible = "raspberrypi,pico-spi-pio"; 28 status = "okay"; 29 #address-cells = <1>; 30 #size-cells = <0>; 31 clocks = <&clocks RPI_PICO_CLKID_CLK_SYS>; 32 miso-gpios = <&gpio0 16 0>; 33 cs-gpios = <&gpio0 17 GPIO_ACTIVE_LOW>; 34 clk-gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>; 35 mosi-gpios = <&gpio0 19 GPIO_ACTIVE_HIGH>; 36 37 slow@0 { 38 compatible = "test-spi-loopback-slow"; 39 reg = <0>; 40 spi-max-frequency = <500000>; 41 }; 42 fast@0 { 43 compatible = "test-spi-loopback-fast"; 44 reg = <0>; 45 spi-max-frequency = <14000000>; 46 }; 47 }; 48}; 49