Skip to content

Commit 4fabe4b

Browse files
committed
fixup! fixup! boards/seeedstudio-xiao-esp32s3: initial support
1 parent 62e09dc commit 4fabe4b

File tree

7 files changed

+79
-110
lines changed

7 files changed

+79
-110
lines changed

boards/seeedstudio-xiao-esp32s3/Kconfig

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,11 @@
1-
# Copyright (c) 2024 TUDresden
2-
# 2024 Isikcan 'Jon' Yilmaz - TUDresden
3-
#
4-
# This file is subject to the terms and conditions of the GNU Lesser
5-
# General Public License v2.1. See the file LICENSE in the top level
6-
# directory for more details.
1+
# SPDX-FileCopyrightText: 2024 Technische Universität Dresden
2+
# SPDX-FileCopyrightText: 2024 Isikcan 'Jon' Yilmaz
3+
# SPDX-License-Identifier: LGPL-2.1-only
74

85
config BOARD
9-
default "esp32s3-seeedstudio" if BOARD_ESP32S3_SEEEDSTUDIO
6+
default "seeedstudio-xiao-esp32s3" if BOARD_SEEEDSTUDIO-XIAO-ESP32S3
107

11-
config BOARD_ESP32S3_SEEEDSTUDIO
8+
config BOARD_SEEEDSTUDIO-XIAO-ESP32S3
129
bool
1310
default y
1411
select BOARD_COMMON_ESP32S3

boards/seeedstudio-xiao-esp32s3/Makefile.features

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# the board uses a ESP32-S3 with a 16MB QSPI Flash and a 8MB QSPI PSRAM
1+
# the board uses a ESP32-S3 with an 8MB QSPI Flash and an 8MB QSPI PSRAM
22
CPU_MODEL = esp32s3
33
FEATURES_PROVIDED += esp_spi_ram
44

@@ -16,3 +16,4 @@ FEATURES_PROVIDED += periph_usbdev
1616
FEATURES_PROVIDED += esp_jtag
1717
FEATURES_PROVIDED += highlevel_stdio
1818
FEATURES_PROVIDED += tinyusb_device
19+
FEATURES_PROVIDED += xiao_shield

boards/seeedstudio-xiao-esp32s3/Makefile.include

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# The board uses a ESP32-S3 with a 16MB QSPI Flash and a 8MB QSPI PSRAM
2-
FLASH_SIZE ?= 16
1+
# The board uses an ESP32-S3 with a 8MB QSPI Flash and an 8MB QSPI PSRAM
2+
FLASH_SIZE ?= 8
33

44
PORT_LINUX ?= /dev/ttyACM0
55

boards/seeedstudio-xiao-esp32s3/doc.txt renamed to boards/seeedstudio-xiao-esp32s3/doc.md

Lines changed: 25 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,28 @@
1-
/*
2-
* Copyright (C) 2024 Isikcan 'Jon' Yilmaz
3-
*
4-
* This file is subject to the terms and conditions of the GNU Lesser
5-
* General Public License v2.1. See the file LICENSE in the top level
6-
* directory for more details.
7-
*/
8-
9-
/**
10-
* @defgroup boards_esp32s3_seeedstudio ESP32 Seeed Studio XIAO Board
11-
* @ingroup boards_esp32s3
12-
* @brief Support for the Seeed Studio Xiao ESP32S3
13-
* @author Isikcan 'Jon' Yilmaz <[email protected]>
14-
15-
\section esp32s3_seeedstudio Seeed Studio Xiao ESP32
1+
<!--
2+
SPDX-FileCopyrightText: 2024 Isikcan 'Jon' Yilmaz
3+
SPDX-License-Identifier: LGPL-2.1-only
4+
-->
5+
6+
@defgroup boards_seeedstudio-xiao-esp32s3 Seeed Studio XIAO ESP32S3 Board
7+
@ingroup boards_esp32s3
8+
@brief Support for the Seeed Studio Xiao ESP32S3
9+
@author Isikcan 'Jon' Yilmaz <[email protected]>
10+
11+
\section esp32s3_seeedstudio Seeed Studio Xiao ESP32S3
1612

1713
## Table of Contents {#esp32s3_seeedstudio_toc}
1814

19-
1. [Overview](#esp32s3_seeedstudio_overview)
20-
2. [Hardware](#esp32s3_seeedstudio_hardware)
21-
1. [MCU](#esp32s3_seeedstudio_mcu)
22-
2. [Board Configuration](#esp32s3_seeedstudio_board_configuration)
23-
3. [Board Pinout](#esp32s3_seeedstudio_pinout)
24-
3. [Flashing the Device](#esp32s3_seeedstudio_flashing)
25-
4. [Using STDIO](#esp32s3_seeedstudio_stdio)
15+
-# [Overview](#esp32s3_seeedstudio_overview)
16+
-# [Hardware](#esp32s3_seeedstudio_hardware)
17+
-# [MCU](#esp32s3_seeedstudio_mcu)
18+
-# [Board Configuration](#esp32s3_seeedstudio_board_configuration)
19+
-# [Board Pinout](#esp32s3_seeedstudio_pinout)
20+
-# [Flashing the Device](#esp32s3_seeedstudio_flashing)
21+
-# [Using STDIO](#esp32s3_seeedstudio_stdio)
2622

2723
## Overview {#esp32s3_seeedstudio_overview}
2824

29-
The Seeed Studio ESP32S3 is one of the ESP32-S3 boards from Seeed Studio.
25+
The Seeed Studio Xiao ESP32S3 is one of the ESP32-S3 boards from Seeed Studio.
3026
\image html https://files.seeedstudio.com/wiki/SeeedStudio-XIAO-ESP32S3/img/xiaoesp32s3.jpg "Seeed Studio ESP32S3" width=800px
3127

3228
Vendor's info page for the board [here](https://wiki.seeedstudio.com/xiao_esp32s3_getting_started/)
@@ -61,7 +57,8 @@ see section \ref esp32_mcu_esp32 "ESP32 SoC Series".
6157

6258
### Board Configuration {#esp32s3_seeedstudio_board_configuration}
6359

64-
Seeed Studio Xiao ESP32S3 boards have no special hardware on board, besides a yellow LED connected to GPIO21.
60+
Seeed Studio Xiao ESP32S3 boards have no special hardware on board,
61+
besides a yellow LED connected to GPIO21.
6562

6663
The default board configuration provides:
6764

@@ -78,7 +75,8 @@ boards, see section \ref esp32_peripherals "Common Peripherals".
7875

7976
### Board Pinout {#esp32s3_seeedstudio_pinout}
8077

81-
The following figure shows the pinout as configured by board definition (excluding the camera module).
78+
The following figure shows the pinout as configured by board definition
79+
(excluding the camera module).
8280

8381
@image html https://files.seeedstudio.com/wiki/SeeedStudio-XIAO-ESP32S3/img/2.jpg "Seeed Studio Xiao ESP32S3 Pinout" width=900px
8482

@@ -93,7 +91,7 @@ Since the board does not have a USB-to-Serial chip, the easiest way to flash
9391
the board is using the USB Serial/JTAG interface. Just connect the board to
9492
your host computer and use the following command:
9593
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
96-
BOARD=esp32s3-seeedstudio make flash ...
94+
BOARD=seeedstudio-xiao-esp32s3 make flash ...
9795
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
9896

9997
@note Usually the make system resets the board before flashing to enable the
@@ -130,7 +128,5 @@ via the USB CDC ACM interface.
130128
Alternatively, the UART interface could be used with an external USB-to-Serial
131129
adapter. Simply add `stdio_uart` to the list of used modules for this purpose:
132130
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
133-
BOARD=esp32s3-seeedstudio USEMODULE=stdio_uart make flash ...
131+
BOARD=seeedstudio-xiao-esp32s3 USEMODULE=stdio_uart make flash ...
134132
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
135-
136-
*/

boards/seeedstudio-xiao-esp32s3/include/board.h

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
/*
2-
* Copyright (C) 2024 Isikcan 'Jon' Yilmaz
3-
*
4-
* This file is subject to the terms and conditions of the GNU Lesser
5-
* General Public License v2.1. See the file LICENSE in the top level
6-
* directory for more details.
2+
* SPDX-FileCopyrightText: 2024 Isikcan 'Jon' Yilmaz
3+
* SPDX-License-Identifier: LGPL-2.1-only
74
*/
85

6+
#pragma once
7+
98
/**
10-
* @ingroup boards_esp32s3_seeedstudio
9+
* @ingroup boards_seeedstudio-xiao-esp32s3
1110
* @brief Board definitions for Seeed Studio Xiao ESP32S3 board
1211
* @{
1312
*
@@ -21,9 +20,6 @@
2120
* @author Isikcan 'Jon' Yilmaz <[email protected]>
2221
*/
2322

24-
#ifndef BOARD_H
25-
#define BOARD_H
26-
2723
#include <stdint.h>
2824

2925
/**
@@ -47,13 +43,13 @@
4743
* Since the GPIO of the button is pulled up with an external resistor, the
4844
* mode for the GPIO pin has to be GPIO_IN.
4945
*/
50-
#define BTN0_MODE GPIO_IN_PU
46+
#define BTN0_MODE GPIO_IN
5147

5248
/**
5349
* @brief Default interrupt flank definition for the button GPIO
5450
*/
5551
#ifndef BTN0_INT_FLANK
56-
#define BTN0_INT_FLANK GPIO_FALLING
52+
# define BTN0_INT_FLANK GPIO_FALLING
5753
#endif
5854

5955
/**
@@ -71,8 +67,8 @@
7167
*/
7268
/** @} */
7369
#ifndef LED0_PIN
74-
#define LED0_PIN GPIO21
75-
#define LED0_ACTIVE (0)
70+
# define LED0_PIN GPIO21
71+
# define LED0_ACTIVE (0)
7672
#endif
7773

7874
/* include common board definitions as last step */
@@ -85,6 +81,4 @@ extern "C" {
8581
#ifdef __cplusplus
8682
} /* end extern "C" */
8783
#endif
88-
89-
#endif /* BOARD_H */
9084
/** @} */

boards/seeedstudio-xiao-esp32s3/include/gpio_params.h

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,12 @@
11
/*
2-
* Copyright (C) 2024 Isikcan 'Jon' Yilmaz
3-
*
4-
* This file is subject to the terms and conditions of the GNU Lesser
5-
* General Public License v2.1. See the file LICENSE in the top level
6-
* directory for more details.
2+
* SPDX-FileCopyrightText: 2024 Isikcan 'Jon' Yilmaz
3+
* SPDX-License-Identifier: LGPL-2.1-only
74
*/
85

9-
#ifndef GPIO_PARAMS_H
10-
#define GPIO_PARAMS_H
6+
#pragma once
117

128
/**
13-
* @ingroup boards_esp32s3_seeedstudio
9+
* @ingroup boards_seeedstudio-xiao-esp32s3
1410
* @brief Board specific configuration of direct mapped GPIOs
1511
* @file
1612
* @author Isikcan 'Jon' Yilmaz <[email protected]>
@@ -46,6 +42,4 @@ static const saul_gpio_params_t saul_gpio_params[] =
4642
#ifdef __cplusplus
4743
}
4844
#endif
49-
50-
#endif /* GPIO_PARAMS_H */
5145
/** @} */
Lines changed: 32 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
/*
2-
* Copyright (C) 2024 Isikcan 'Jon' Yilmaz
3-
*
4-
* This file is subject to the terms and conditions of the GNU Lesser
5-
* General Public License v2.1. See the file LICENSE in the top level
6-
* directory for more details.
2+
* SPDX-FileCopyrightText: 2024 Isikcan 'Jon' Yilmaz
3+
* SPDX-License-Identifier: LGPL-2.1-only
74
*/
85

6+
#pragma once
7+
98
/**
10-
* @ingroup boards_esp32s3_seeedstudio
9+
* @ingroup boards_seeedstudio-xiao-esp32s3
1110
* @brief Peripheral configurations for Seeed Studio Xiao ESP32S3 boards
1211
* @{
1312
*
@@ -18,25 +17,18 @@
1817
* For detailed information about the peripheral configuration for ESP32-S3
1918
* boards, see section \ref esp32_peripherals "Common Peripherals".
2019
*
21-
* @note
22-
* Most definitions can be overridden by an \ref esp32_application_specific_configurations
23-
* "application-specific board configuration" if necessary.
24-
*
2520
* @file
2621
* @author Isikcan 'Jon' Yilmaz <[email protected]>
2722
*/
2823

29-
#ifndef PERIPH_CONF_H
30-
#define PERIPH_CONF_H
31-
3224
#include <stdint.h>
3325

3426
#ifdef __cplusplus
3527
extern "C" {
3628
#endif
3729

3830
/**
39-
* @name ADC and DAC channel configuration
31+
* @name ADC Channel Configuration
4032
* @{
4133
*/
4234
/**
@@ -51,14 +43,15 @@ extern "C" {
5143
* purposes.
5244
*/
5345
#ifndef ADC_GPIOS
54-
#define ADC_GPIOS { GPIO1, GPIO2, GPIO3, GPIO4, GPIO5, GPIO6, GPIO7, GPIO8, GPIO9 }
46+
# define ADC_GPIOS { GPIO1, GPIO2, GPIO3, GPIO4, GPIO5, GPIO6, GPIO7, GPIO8, GPIO9 }
5547
#endif
5648
/** @} */
5749

5850
/**
5951
* @name I2C configuration
6052
*
61-
* For generic boards, only one I2C interface I2C_DEV(0) is defined.
53+
* For the Seeedstudio Xiao ESP32S3 board, only one I2C interface I2C_DEV(0)
54+
* is defined.
6255
*
6356
* The GPIOs listed in the configuration are only initialized as I2C signals
6457
* when module `periph_i2c` is used. Otherwise they are not allocated and
@@ -67,13 +60,13 @@ extern "C" {
6760
* @{
6861
*/
6962
#ifndef I2C0_SPEED
70-
#define I2C0_SPEED I2C_SPEED_FAST /**< I2C bus speed of I2C_DEV(0) */
63+
# define I2C0_SPEED I2C_SPEED_FAST /**< I2C bus speed of I2C_DEV(0) */
7164
#endif
7265
#ifndef I2C0_SCL
73-
#define I2C0_SCL GPIO6 /**< SCL signal of I2C_DEV(0) */
66+
# define I2C0_SCL GPIO6 /**< SCL signal of I2C_DEV(0) */
7467
#endif
7568
#ifndef I2C0_SDA
76-
#define I2C0_SDA GPIO5 /**< SDA signal of I2C_DEV(0) */
69+
# define I2C0_SDA GPIO5 /**< SDA signal of I2C_DEV(0) */
7770
#endif
7871
/** @} */
7972

@@ -95,9 +88,9 @@ extern "C" {
9588
* @brief Declaration of the channels for device PWM_DEV(0),
9689
* at maximum PWM_CHANNEL_NUM_DEV_MAX.
9790
*/
98-
// #ifndef PWM0_GPIOS
99-
// #define PWM0_GPIOS { GPIO12, GPIO13, GPIO14, GPIO15, GPIO16 }
100-
// #endif
91+
#ifndef PWM0_GPIOS
92+
# define PWM0_GPIOS { GPIO21 }
93+
#endif
10194

10295
/**
10396
* @brief Declaration of the channels for device PWM_DEV(1),
@@ -117,23 +110,23 @@ extern "C" {
117110
* by either calling the `spi_init_cs` function or the `spi_acquire`
118111
* function. That is, they are not allocated as SPI signals before and can
119112
* be used for other purposes as long as the SPI interface is not used.
120-
* @{ TODO SPI pins
113+
* @{
121114
*/
122-
// #ifndef SPI0_CTRL
123-
// #define SPI0_CTRL FSPI /**< FSPI is used as SPI_DEV(0) */
124-
// #endif
125-
// #ifndef SPI0_SCK
126-
// #define SPI0_SCK GPIO36 /**< FSPI SCK (pin FSPICLK) */
127-
// #endif
128-
// #ifndef SPI0_MISO
129-
// #define SPI0_MISO GPIO37 /**< FSPI MISO (pin FSPIQ) */
130-
// #endif
131-
// #ifndef SPI0_MOSI
132-
// #define SPI0_MOSI GPIO35 /**< FSPI MOSI (pin FSPID) */
133-
// #endif
134-
// #ifndef SPI0_CS0
135-
// #define SPI0_CS0 GPIO34 /**< FSPI CS0 (pin FSPICS0) */
136-
// #endif
115+
#ifndef SPI0_CTRL
116+
# define SPI0_CTRL FSPI /**< FSPI is used as SPI_DEV(0) */
117+
#endif
118+
#ifndef SPI0_SCK
119+
# define SPI0_SCK GPIO7 /**< FSPI SCK (pin FSPICLK) */
120+
#endif
121+
#ifndef SPI0_MISO
122+
# define SPI0_MISO GPIO8 /**< FSPI MISO (pin FSPIQ) */
123+
#endif
124+
#ifndef SPI0_MOSI
125+
# define SPI0_MOSI GPIO9 /**< FSPI MOSI (pin FSPID) */
126+
#endif
127+
#ifndef SPI0_CS0
128+
# define SPI0_CS0 GPIO3 /**< FSPI CS0 (pin FSPICS0) */
129+
#endif
137130
/** @} */
138131

139132
/**
@@ -143,25 +136,19 @@ extern "C" {
143136
*
144137
* UART_DEV(0) uses fixed standard configuration.<br>
145138
* UART_DEV(1) is not used.<br>
139+
* UART_DEV(2) is not used.
146140
*
147141
* @{
148142
*/
149143
#define UART0_TXD GPIO43 /**< direct I/O pin for UART_DEV(0) TxD, can't be changed */
150144
#define UART0_RXD GPIO44 /**< direct I/O pin for UART_DEV(0) RxD, can't be changed */
151-
152145
/** @} */
153146

154-
/**
155-
* @name Camera configurations and pins
156-
* TODO also mic pins
157-
*/
158-
159147
#ifdef __cplusplus
160148
} /* end extern "C" */
161149
#endif
162150

163151
/* include common peripheral definitions as last step */
164152
#include "periph_conf_common.h"
165153

166-
#endif /* PERIPH_CONF_H */
167154
/** @} */

0 commit comments

Comments
 (0)