1/* 2 * Copyright (c) 2023 Seeed Studio inc. 3 * Copyright (c) 2024 Ian Wakely 4 * 5 * SPDX-License-Identifier: Apache-2.0 6 */ 7 8/dts-v1/; 9 10#include <espressif/esp32s3/esp32s3_wroom_n8.dtsi> 11#include <zephyr/dt-bindings/led/led.h> 12#include <zephyr/dt-bindings/input/input-event-codes.h> 13#include "adafruit_qt_py_esp32s3-pinctrl.dtsi" 14#include "seeed_xiao_connector.dtsi" 15#include <espressif/partitions_0x0_amp.dtsi> 16 17/ { 18 model = "Adafruit QT Py ESP32S3 PROCPU"; 19 compatible = "seeed,xiao-esp32s3"; 20 21 chosen { 22 zephyr,sram = &sram1; 23 zephyr,console = &usb_serial; 24 zephyr,shell-uart = &usb_serial; 25 zephyr,flash = &flash0; 26 zephyr,code-partition = &slot0_partition; 27 zephyr,bt-hci = &esp32_bt_hci; 28 }; 29 30 aliases { 31 i2c-0 = &i2c0; 32 watchdog0 = &wdt0; 33 led-strip = &led_strip; 34 sw0 = &button0; 35 }; 36 37 buttons { 38 compatible = "gpio-keys"; 39 button0: button_0 { 40 gpios = <&gpio0 0 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>; 41 label = "User button"; 42 zephyr,code = <INPUT_KEY_0>; 43 }; 44 }; 45}; 46 47&usb_serial { 48 status = "okay"; 49}; 50 51&uart0 { 52 status = "okay"; 53 current-speed = <115200>; 54 pinctrl-0 = <&uart0_default>; 55 pinctrl-names = "default"; 56}; 57 58&i2c0 { 59 status = "okay"; 60 clock-frequency = <I2C_BITRATE_STANDARD>; 61 pinctrl-0 = <&i2c0_default>; 62 pinctrl-names = "default"; 63}; 64 65&i2c1 { 66 status = "okay"; 67 clock-frequency = <I2C_BITRATE_STANDARD>; 68 pinctrl-0 = <&i2c1_default>; 69 pinctrl-names = "default"; 70}; 71 72&trng0 { 73 status = "okay"; 74}; 75 76&spi2 { 77 #address-cells = <1>; 78 #size-cells = <0>; 79 status = "okay"; 80 pinctrl-0 = <&spim2_default>; 81 pinctrl-names = "default"; 82}; 83 84&spi3 { 85 #address-cells = <1>; 86 #size-cells = <0>; 87 status = "okay"; 88 pinctrl-0 = <&spim3_ws2812_led>; 89 pinctrl-names = "default"; 90 91 line-idle-low; 92 93 led_strip: ws2812@0 { 94 compatible = "worldsemi,ws2812-spi"; 95 96 /* SPI */ 97 reg = <0>; /* ignored, but necessary for SPI bindings */ 98 spi-max-frequency = <6400000>; 99 100 /* WS2812 */ 101 chain-length = <1>; 102 spi-cpha; 103 spi-one-frame = <0xf0>; /* 11110000: 625 ns high and 625 ns low */ 104 spi-zero-frame = <0xc0>; /* 11000000: 312.5 ns high and 937.5 ns low */ 105 color-mapping = <LED_COLOR_ID_GREEN 106 LED_COLOR_ID_RED 107 LED_COLOR_ID_BLUE>; 108 }; 109}; 110 111&gpio0 { 112 status = "okay"; 113}; 114 115&gpio1 { 116 status = "okay"; 117 118 /* 119 * Unlike some of the other Adafruit boards, the neopixel on this board has 120 * its positive side hooked up to a GPIO pin rather than a positive voltage 121 * rail to save on power. This will enable the LED on board initialization. 122 */ 123 neopixel-power-enable { 124 gpio-hog; 125 gpios = <6 GPIO_ACTIVE_HIGH>; 126 output-high; 127 }; 128}; 129 130&wdt0 { 131 status = "okay"; 132}; 133 134&twai { 135 pinctrl-0 = <&twai_default>; 136 pinctrl-names = "default"; 137}; 138 139&timer0 { 140 status = "okay"; 141}; 142 143&timer1 { 144 status = "okay"; 145}; 146 147&esp32_bt_hci { 148 status = "okay"; 149}; 150