1/ { 2 aliases { 3 magn0 = &tmag5170; 4 }; 5}; 6 7&pinctrl { 8 pio0_spi0_default: pio0_spi0_default { 9 /* gpio 9 is used for chip select, not assigned to the PIO */ 10 group1 { 11 pinmux = <PIO0_P10>, <PIO0_P11>; 12 }; 13 group2 { 14 pinmux = <PIO0_P8>; 15 input-enable; 16 }; 17 }; 18 19}; 20 21&pio0 { 22 status = "okay"; 23 24 pio0_spi0: pio0_spi0 { 25 pinctrl-0 = <&pio0_spi0_default>; 26 pinctrl-names = "default"; 27 28 compatible = "raspberrypi,pico-spi-pio"; 29 status = "okay"; 30 #address-cells = <1>; 31 #size-cells = <0>; 32 clocks = <&clocks RPI_PICO_CLKID_CLK_SYS>; 33 miso-gpios = <&gpio0 8 0>; 34 cs-gpios = <&gpio0 9 GPIO_ACTIVE_LOW>; 35 clk-gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>; 36 mosi-gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>; 37 tmag5170: tmag5170@0 { 38 compatible = "ti,tmag5170"; 39 reg = <0>; 40 operating-mode = <3>; 41 spi-max-frequency = <1000000>; /* conservatively set to 1MHz */ 42 }; 43 }; 44}; 45