| /* |
| * Copyright (c) 2021 Instituto de Pesquisas Eldorado (eldorado.org.br) |
| * Copyright (c) 2022 Espressif Systems (Shanghai) Co., Ltd. |
| * Copyright (c) 2023 The Zephyr Project Contributors |
| * |
| * SPDX-License-Identifier: Apache-2.0 |
| */ |
| /dts-v1/; |
| |
| #include <espressif/esp32s3/esp32s3_fn8.dtsi> |
| #include "heltec_wireless_stick_lite_v3-pinctrl.dtsi" |
| #include <zephyr/dt-bindings/pwm/pwm.h> |
| #include <zephyr/dt-bindings/input/input-event-codes.h> |
| #include <zephyr/dt-bindings/lora/sx126x.h> |
| #include <espressif/partitions_0x0_amp.dtsi> |
| |
| / { |
| model = "Heltec Wireless Stick Lite V3 PROCPU"; |
| compatible = "espressif,esp32s3"; |
| |
| aliases { |
| pwm-0 = &ledc0; |
| pwm-led0 = &pwm_led_white; |
| uart-0 = &uart0; |
| uart-1 = &uart1; |
| i2c-0 = &i2c0; |
| lora0 = &lora0; |
| sw0 = &button0; |
| watchdog0 = &wdt0; |
| }; |
| |
| leds { |
| compatible = "gpio-leds"; |
| |
| vext: vext { |
| gpios = <&gpio0 36 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>; |
| label = "Vext Control"; |
| }; |
| |
| adc: adc { |
| gpios = <&gpio0 37 GPIO_ACTIVE_LOW>; |
| label = "ADC Control"; |
| }; |
| }; |
| |
| pwmleds { |
| compatible = "pwm-leds"; |
| pwm_led_white: pwm_led_gpio0_35 { |
| label = "White PWM LED"; |
| pwms = <&ledc0 0 PWM_MSEC(10) PWM_POLARITY_NORMAL>; |
| }; |
| }; |
| |
| buttons { |
| compatible = "gpio-keys"; |
| button0: button_0 { |
| gpios = <&gpio0 0 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>; |
| label = "USER SW"; |
| zephyr,code = <INPUT_KEY_0>; |
| }; |
| }; |
| |
| vbatt { |
| compatible = "voltage-divider"; |
| io-channels = <&adc1 0>; |
| output-ohms = <100000>; |
| full-ohms = <(100000 + 390000)>; |
| }; |
| |
| chosen { |
| zephyr,sram = &sram0; |
| zephyr,console = &uart0; |
| zephyr,shell-uart = &uart0; |
| zephyr,flash = &flash0; |
| zephyr,code-partition = &slot0_partition; |
| zephyr,bt-hci = &esp32_bt_hci; |
| }; |
| }; |
| |
| &flash0 { |
| reg = <0x0 DT_SIZE_M(4)>; |
| }; |
| |
| &adc1 { |
| status ="okay"; |
| }; |
| |
| &uart0 { |
| status = "okay"; |
| current-speed = <115200>; |
| pinctrl-0 = <&uart0_default>; |
| pinctrl-names = "default"; |
| }; |
| |
| &gpio0 { |
| status = "okay"; |
| }; |
| |
| &gpio1 { |
| status = "okay"; |
| }; |
| |
| &ledc0 { |
| pinctrl-0 = <&ledc0_default>; |
| pinctrl-names = "default"; |
| status = "okay"; |
| #address-cells = <1>; |
| #size-cells = <0>; |
| channel0@0 { |
| reg = <0x0>; |
| timer = <0>; |
| }; |
| }; |
| |
| &i2c0 { |
| clock-frequency = <I2C_BITRATE_STANDARD>; |
| pinctrl-0 = <&i2c0_default>; |
| pinctrl-names = "default"; |
| }; |
| |
| &spi2 { |
| #address-cells = <1>; |
| #size-cells = <0>; |
| status = "okay"; |
| pinctrl-0 = <&spim2_default>; |
| pinctrl-names = "default"; |
| lora0: lora@0 { |
| compatible = "semtech,sx1262"; |
| reg = <0>; |
| reset-gpios = <&gpio0 12 (GPIO_OPEN_DRAIN | GPIO_ACTIVE_LOW)>; |
| busy-gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>; |
| dio1-gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>; |
| dio2-tx-enable; |
| dio3-tcxo-voltage = <SX126X_DIO3_TCXO_1V8>; |
| tcxo-power-startup-delay-ms = <5>; |
| spi-max-frequency = <4000000>; |
| }; |
| }; |
| |
| &twai { |
| pinctrl-0 = <&twai_default>; |
| pinctrl-names = "default"; |
| }; |
| |
| &timer0 { |
| status = "okay"; |
| }; |
| |
| &timer1 { |
| status = "okay"; |
| }; |
| |
| &timer2 { |
| status = "okay"; |
| }; |
| |
| &timer3 { |
| status = "okay"; |
| }; |
| |
| &wdt0 { |
| status = "okay"; |
| }; |
| |
| &trng0 { |
| status = "okay"; |
| }; |
| |
| &uart1 { |
| status = "okay"; |
| current-speed = <115200>; |
| pinctrl-0 = <&uart1_default>; |
| pinctrl-names = "default"; |
| }; |
| |
| &esp32_bt_hci { |
| status = "okay"; |
| }; |