Skip to content

Commit 0c39d53

Browse files
committed
boards: adafruit: esp32s2_feather: add support
add board support for adafruit_esp32s2_feather board series Signed-off-by: Philipp Steiner <[email protected]>
1 parent 4e4ec9c commit 0c39d53

File tree

43 files changed

+1472
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+1472
-0
lines changed
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# SPDX-License-Identifier: Apache-2.0
2+
3+
zephyr_library()
4+
zephyr_library_sources(board.c)
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Copyright (c) 2023 Google, LLC
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config HEAP_MEM_POOL_ADD_SIZE_BOARD
5+
int
6+
default 4096
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2025 Philipp Steiner <[email protected]>
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config BOARD_ADAFRUIT_FEATHER
5+
select SOC_ESP32S2_R2
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2025 Philipp Steiner <[email protected]>
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config BOARD_ADAFRUIT_FEATHER_TFT
5+
select SOC_ESP32S2_R2
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2025 Philipp Steiner <[email protected]>
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config BOARD_ADAFRUIT_FEATHER_TFT_REVERSE
5+
select SOC_ESP32S2_R2
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Copyright (c) 2025 Philipp Steiner <[email protected]>
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config ENTROPY_GENERATOR
5+
default y
6+
7+
if BOARD_ADAFRUIT_FEATHER_TFT || BOARD_ADAFRUIT_FEATHER_TFT_REVERSE
8+
if DISPLAY
9+
10+
choice ST7789V_PIXEL_FORMAT
11+
default ST7789V_RGB565
12+
endchoice
13+
14+
if LVGL
15+
16+
config LV_Z_BITS_PER_PIXEL
17+
default 16
18+
19+
choice LV_COLOR_DEPTH
20+
default LV_COLOR_DEPTH_16
21+
endchoice
22+
23+
config LV_COLOR_16_SWAP
24+
default y
25+
26+
endif # LVGL
27+
endif # DISPLAY
28+
endif # BOARD_ADAFRUIT_FEATHER_TFT || BOARD_ADAFRUIT_FEATHER_TFT_REVERSE
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd.
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
choice BOOTLOADER
5+
default BOOTLOADER_MCUBOOT
6+
endchoice
7+
8+
choice BOOT_SIGNATURE_TYPE
9+
default BOOT_SIGNATURE_TYPE_NONE
10+
endchoice
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
/*
2+
* Copyright (c) 2025 Philipp Steiner <[email protected]>.
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
#include <zephyr/dt-bindings/pinctrl/esp-pinctrl-common.h>
8+
#include <dt-bindings/pinctrl/esp32s2-pinctrl.h>
9+
#include <zephyr/dt-bindings/pinctrl/esp32s2-gpio-sigmap.h>
10+
11+
&pinctrl {
12+
13+
/* Debug TX (DBG) - This is the hardware UART debug pin */
14+
uart0_default: uart0_default {
15+
group1 {
16+
pinmux = <UART0_TX_GPIO43>;
17+
output-high;
18+
};
19+
};
20+
21+
uart1_default: uart1_default {
22+
group1 {
23+
pinmux = <UART1_TX_GPIO39>;
24+
output-high;
25+
};
26+
group2 {
27+
pinmux = <UART1_RX_GPIO38>;
28+
bias-pull-up;
29+
};
30+
};
31+
32+
spim2_default: spim2_default {
33+
group1 {
34+
pinmux = <SPIM2_MISO_GPIO37>,
35+
<SPIM2_SCLK_GPIO36>,
36+
<SPIM2_CSEL_GPIO7>;
37+
};
38+
group2 {
39+
pinmux = <SPIM2_MOSI_GPIO35>;
40+
output-low;
41+
};
42+
};
43+
44+
spim3_ws2812_led: spim3_ws2812_led {
45+
group1 {
46+
pinmux = <SPIM3_MOSI_GPIO33>;
47+
};
48+
};
49+
50+
i2c0_default: i2c0_default {
51+
group1 {
52+
pinmux = <I2C0_SDA_GPIO3>,
53+
<I2C0_SCL_GPIO4>;
54+
drive-open-drain;
55+
output-high;
56+
};
57+
};
58+
59+
twai_default: twai_default {
60+
group1 {
61+
pinmux = <TWAI_TX_GPIO5>,
62+
<TWAI_RX_GPIO6>;
63+
};
64+
};
65+
};
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
/*
2+
* Copyright (c) 2025 Philipp Steiner <[email protected]>
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
/dts-v1/;
8+
9+
#include "adafruit_feather_esp32s2_common.dtsi"
10+
#include "feather_connector.dtsi"
11+
12+
/ {
13+
model = "Adafruit Feather ESP32-S2";
14+
compatible = "espressif,esp32s2";
15+
};
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/*
2+
* Copyright (c) 2025 Philipp Steiner <[email protected]>
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
/ {
8+
/*
9+
* On-board transistor powers I2C pull-ups and external devices connected
10+
* via the STEMMA QT connector.
11+
*/
12+
i2c_reg: i2c_reg {
13+
label = "I2C Power";
14+
compatible = "power-domain-gpio";
15+
#power-domain-cells = <0>;
16+
enable-gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
17+
};
18+
};

0 commit comments

Comments
 (0)