Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions boards/m5stack/m5stack_cores3/Kconfig.defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,20 @@

if BOARD_M5STACK_CORES3_ESP32S3_PROCPU || BOARD_M5STACK_CORES3_ESP32S3_PROCPU_SE

config DISPLAY
default y

config INPUT
default y

if MIPI_DBI

config MIPI_DBI_INIT_PRIORITY
default 82

Check warning on line 17 in boards/m5stack/m5stack_cores3/Kconfig.defconfig

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/Kconfig.defconfig:17 please, no spaces at the start of a line

config MIPI_DBI_SPI_3WIRE
default y

Check warning on line 20 in boards/m5stack/m5stack_cores3/Kconfig.defconfig

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/Kconfig.defconfig:20 please, no spaces at the start of a line

endif # MIPI_DBI

endif # BOARD_M5STACK_CORES3_ESP32S3_PROCPU || BOARD_M5STACK_CORES3_ESP32S3_PROCPU_SE
21 changes: 21 additions & 0 deletions boards/m5stack/m5stack_cores3/doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,27 @@ application.
:board: m5stack_cores3/esp32s3/procpu/se
:goals: flash

Display
=======

The on-board ILI9342C LCD can be exercised with the LVGL sample application.

.. tabs::

.. group-tab:: M5Stack CoreS3

.. zephyr-app-commands::
:zephyr-app: samples/subsys/display/lvgl
:board: m5stack_cores3/esp32s3/procpu
:goals: build

.. group-tab:: M5Stack CoreS3 SE

.. zephyr-app-commands::
:zephyr-app: samples/subsys/display/lvgl
:board: m5stack_cores3/esp32s3/procpu/se
:goals: build

The baud rate of 921600bps is set by default. If experiencing issues when flashing,
try using different values by using ``--esp-baud-rate <BAUD>`` option during
``west flash`` (e.g. ``west flash --esp-baud-rate 115200``).
Expand Down
101 changes: 64 additions & 37 deletions boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -6,39 +6,66 @@

#include <espressif/esp32s3/esp32s3_wroom_n16r8.dtsi>
#include <espressif/partitions_0x0_amp.dtsi>
#include <dt-bindings/spi/spi.h>
#include <zephyr/dt-bindings/display/ili9xxx.h>
#include "m5stack_cores3-pinctrl.dtsi"
#include "m5stack_mbus_connectors.dtsi"
#include "grove_connectors.dtsi"

/ {
chosen {
zephyr,sram = &sram1;
zephyr,console = &usb_serial;
zephyr,shell-uart = &usb_serial;
zephyr,flash = &flash0;
zephyr,code-partition = &slot0_partition;
zephyr,rtc = &bm8563_rtc;
zephyr,bt-hci = &esp32_bt_hci;
zephyr,touch = &ft6336_touch;
};

aliases {
uart-0 = &uart0;
uart-1 = &uart1;
uart-2 = &uart2;
i2c-0 = &i2c0;
i2c-1 = &i2c1;
watchdog0 = &wdt0;
rtc = &bm8563_rtc;
sdhc0 = &sd0;
led0 = &axp2101_led;
fuel-gauge0 = &fuel_gauge;
};

lvgl_pointer {
compatible = "zephyr,lvgl-pointer-input";
input = <&ft6336_touch>;
};
chosen {

Check warning on line 16 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:16 please, no spaces at the start of a line

Check failure on line 16 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:16 code indent should use tabs where possible
zephyr,sram = &sram1;

Check warning on line 17 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:17 please, no spaces at the start of a line

Check failure on line 17 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:17 code indent should use tabs where possible
zephyr,console = &usb_serial;

Check warning on line 18 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:18 please, no spaces at the start of a line

Check failure on line 18 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:18 code indent should use tabs where possible
zephyr,shell-uart = &usb_serial;

Check warning on line 19 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:19 please, no spaces at the start of a line

Check failure on line 19 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:19 code indent should use tabs where possible
zephyr,flash = &flash0;

Check warning on line 20 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:20 please, no spaces at the start of a line

Check failure on line 20 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:20 code indent should use tabs where possible
zephyr,code-partition = &slot0_partition;

Check warning on line 21 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:21 please, no spaces at the start of a line

Check failure on line 21 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:21 code indent should use tabs where possible
zephyr,rtc = &bm8563_rtc;

Check warning on line 22 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:22 please, no spaces at the start of a line

Check failure on line 22 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:22 code indent should use tabs where possible
zephyr,bt-hci = &esp32_bt_hci;

Check warning on line 23 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:23 please, no spaces at the start of a line

Check failure on line 23 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:23 code indent should use tabs where possible
zephyr,touch = &ft6336_touch;

Check failure on line 24 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:24 code indent should use tabs where possible
zephyr,display = &ili9342c;

Check failure on line 25 in boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

CODE_INDENT

boards/m5stack/m5stack_cores3/m5stack_cores3_procpu_common.dtsi:25 code indent should use tabs where possible
};

aliases {
uart-0 = &uart0;
uart-1 = &uart1;
uart-2 = &uart2;
i2c-0 = &i2c0;
i2c-1 = &i2c1;
watchdog0 = &wdt0;
rtc = &bm8563_rtc;
sdhc0 = &sd0;
led0 = &axp2101_led;
fuel-gauge0 = &fuel_gauge;
display = &ili9342c;
};

lvgl_pointer {
compatible = "zephyr,lvgl-pointer-input";
input = <&ft6336_touch>;
};

mipi_dbi {
compatible = "zephyr,mipi-dbi-spi";
spi-dev = <&spi2>;
write-only;
reset-gpios = <&aw9523b_gpio 13 GPIO_ACTIVE_LOW>;
#address-cells = <1>;
#size-cells = <0>;

ili9342c: ili9342c@0 {
compatible = "ilitek,ili9342c";
reg = <0>;
mipi-max-frequency = <40000000>;
duplex = <SPI_HALF_DUPLEX>;
mipi-mode = "MIPI_DBI_MODE_SPI_3WIRE";
vin-supply = <&vcc_bl>;
pixel-format = <ILI9XXX_PIXEL_FORMAT_RGB565>;
display-inversion;
width = <320>;
height = <240>;
rotation = <0>;
};
};
};

&usb_serial {
Expand Down Expand Up @@ -209,15 +236,15 @@
};

&spi2 {
status = "okay";
#address-cells = <1>;
#size-cells = <0>;
status = "okay";
pinctrl-0 = <&spim2_default>;
pinctrl-names = "default";
clock-frequency = <20000000>;
cs-gpios = <&gpio0 3 GPIO_ACTIVE_LOW>, /* LCD */
<&gpio0 4 GPIO_ACTIVE_LOW>; /* TF-CARD */
status = "okay";
#address-cells = <1>;
#size-cells = <0>;
pinctrl-0 = <&spim2_default>;
pinctrl-names = "default";
dma-enabled;
clock-frequency = <40000000>;
cs-gpios = <&gpio0 3 GPIO_ACTIVE_LOW>, /* LCD */
<&gpio0 4 GPIO_ACTIVE_LOW>; /* TF-CARD */

sd0: sd@1 {
compatible = "zephyr,sdhc-spi-slot";
Expand Down
Loading