boards: shields: Add Arduino Giga display shield.

Add board support for the Arduino Giga display shield.

Signed-off-by: Ibrahim Abdalkader <i.abdalkader@gmail.com>
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
This commit is contained in:
Ibrahim Abdalkader 2025-02-11 11:06:47 +01:00 committed by Benjamin Cabé
parent 0969dee311
commit 9cea552250
8 changed files with 259 additions and 0 deletions

View File

@ -0,0 +1,27 @@
# Copyright (c) 2025 Arduino SA
# SPDX-License-Identifier: Apache-2.0
if SHIELD_ARDUINO_GIGA_DISPLAY_SHIELD
if LVGL
config INPUT
default y
config LV_Z_BITS_PER_PIXEL
default 16
config LV_DPI_DEF
default 128
config LV_Z_FLUSH_THREAD
default y
choice LV_COLOR_DEPTH
default LV_COLOR_DEPTH_16
endchoice
endif # LVGL
endif # SHIELD_ARDUINO_GIGA_DISPLAY_SHIELD

View File

@ -0,0 +1,5 @@
# Copyright (c) 2025 Arduino SA
# SPDX-License-Identifier: Apache-2.0
config SHIELD_ARDUINO_GIGA_DISPLAY_SHIELD
def_bool $(shields_list_contains,arduino_giga_display_shield)

View File

@ -0,0 +1,9 @@
# Copyright (c) 2025 Arduino SA
# SPDX-License-Identifier: Apache-2.0
CONFIG_MEMC=y
CONFIG_STM32_LTDC_RGB565=y
CONFIG_DISPLAY_INIT_PRIORITY=87
CONFIG_STM32_LTDC_DISABLE_FMC_BANK1=y
CONFIG_INPUT_GT911_INTERRUPT=y
CONFIG_STM32_LTDC_FB_USE_SHARED_MULTI_HEAP=y

View File

@ -0,0 +1,22 @@
# Copyright (c) 2025 Arduino SA
# SPDX-License-Identifier: Apache-2.0
if SHIELD_ARDUINO_GIGA_DISPLAY_SHIELD
if LVGL
# Double frame buffer maintained by lvgl.
config STM32_LTDC_FB_NUM
default 0
config LV_Z_DOUBLE_VDB
default y
config LV_Z_FULL_REFRESH
default y
endchoice
endif # LVGL
endif # SHIELD_ARDUINO_GIGA_DISPLAY_SHIELD

View File

@ -0,0 +1,96 @@
/*
* Copyright (c) 2025 Arduino SA
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/display/panel.h>
/ {
lvgl_pointer {
compatible = "zephyr,lvgl-pointer-input";
input = <&gt911>;
};
aliases {
accel0 = &gt911;
};
chosen {
zephyr,display = &zephyr_lcd_controller;
zephyr,touch = &gt911;
};
};
&sdram1 {
/* Frame buffer memory cache will cause screen flickering. */
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_RAM_NOCACHE) )>;
};
&zephyr_lcd_controller {
status = "okay";
ext-sdram = <&sdram1>;
width = <480>;
height = <800>;
def-back-color-red = <0>;
def-back-color-green = <0>;
def-back-color-blue = <0>;
pixel-format = <PANEL_PIXEL_FORMAT_RGB_565>;
disp-on-gpios = <&gpioc 6 GPIO_ACTIVE_HIGH>;
bl-ctrl-gpios = <&gpiob 12 GPIO_ACTIVE_HIGH>;
/* sitronix, st7701 */
display-timings {
compatible = "zephyr,panel-timing";
hsync-active = <1>;
vsync-active = <0>;
de-active = <0>;
pixelclk-active = <0>;
hback-porch = <40>;
hsync-len = <32>;
hfront-porch = <8>;
vback-porch = <6>;
vsync-len = <8>;
vfront-porch = <9>;
};
};
/* ltdc uses pll3_r as pixel clock */
&pll3 {
status = "okay";
clocks = <&clk_hse>;
div-m = <16>;
mul-n = <110>;
div-p = <2>;
div-q = <2>;
div-r = <4>; /* 27.5 MHz */
};
&zephyr_mipi_dsi {
status = "okay";
pll-ndiv = <125>;
pll-idf = <4>;
pll-odf = <0>;
de-active-high;
largest-packet-size = <0>;
phy-timings = <35 35 35 35 0 10>;
};
&i2c4 {
pinctrl-0 = <&i2c4_scl_pb6 &i2c4_sda_ph12>;
pinctrl-names = "default";
clock-frequency = <I2C_BITRATE_FAST>;
status = "okay";
gt911: gt911@5d {
compatible = "goodix,gt911";
reg = <0x5d>;
alt-addr = <0x14>;
reset-gpios = <&gpioi 2 GPIO_ACTIVE_LOW>;
irq-gpios = <&gpioi 1 GPIO_ACTIVE_HIGH>;
};
};

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

View File

@ -0,0 +1,53 @@
.. _arduino_giga_display_shield:
Arduino GIGA Display Shield
###########################
Overview
********
The Arduino GIGA Display Shield is an extension for the Arduino GIGA R1 WiFi board.
It provides a convenient way to add a display to your projects by offering connectors
for various display modules, including DSI and DPI interfaces.
Additionally, it exposes connectors for the camera interface and includes a microSD card slot.
The front of the shield is equipped with the KD040WVFID026-01-C025A panel, a 3.97-inch
TFT display with a resolution of 480*800 pixels. The panel also features a capacitive
multi-touch screen with a GT911 controller accessible over I2C.
The shield can be connected to the Arduino GIGA R1 WiFi board via the high-density connectors.
More information about the shield can be found at `Arduino GIGA Display Shield website`_.
.. figure:: img/ASX00039_00.default_1000x750.webp
:align: center
Arduino GIGA Display Shield
Requirements
************
This shield can only be used with the Arduino GIGA R1 WiFi board, which provides the
necessary connectors and interfaces for display and camera modules.
The board must define node aliases for the required peripherals (e.g., I2C, SPI, DSI)
to properly interface with the shield.
Programming
***********
Include ``--shield arduino_giga_display_shield`` when you invoke ``west build``
for projects utilizing this shield. For example:
.. zephyr-app-commands::
:zephyr-app: samples/subsys/display/lvgl
:board: arduino_giga_r1_wifi
:shield: arduino_giga_display_shield
:goals: build
References
**********
.. target-notes::
.. _Arduino GIGA Display Shield website:
https://docs.arduino.cc/hardware/giga-display-shield/

View File

@ -0,0 +1,47 @@
/*
* Copyright (c) 2025 Arduino SA
*
* SPDX-License-Identifier: Apache-2.0
*/
&zephyr_mipi_dsi {
st7701: st7701@0 {
status = "okay";
compatible = "sitronix,st7701";
reg = <0x0>;
height = <800>;
width = <480>;
data-lanes = <2>;
pixel-format = <MIPI_DSI_PIXFMT_RGB565>;
rotation = <0>;
gip-e0 = [E0 00 00 02];
gip-e1 = [E1 08 00 0A 00 07 00 09 00 00 33 33];
gip-e2 = [E2 00 00 00 00 00 00 00 00 00 00 00 00 00];
gip-e3 = [E3 00 00 33 33];
gip-e4 = [E4 44 44];
gip-e5 = [E5 0E 60 A0 A0 10 60 A0 A0 0A 60 A0 A0 0C 60 A0 A0];
gip-e6 = [E6 00 00 33 33];
gip-e7 = [E7 44 44];
gip-e8 = [E8 0D 60 A0 A0 0F 60 A0 A0 09 60 A0 A0 0B 60 A0 A0];
gip-eb = [EB 02 01 E4 E4 44 00 40];
gip-ec = [EC 02 01];
gip-ed = [ED AB 89 76 54 01 FF FF FF FF FF FF 10 45 67 98 BA];
gip-ed = [ED AB 89 76 54 01 FF FF FF FF FF FF 10 45 67 98 BA];
pvgamctrl = [B0 40 C9 91 0D 12 07 02 09 09 1F 04 50 0F E4 29 DF];
nvgamctrl = [B1 40 CB D0 11 92 07 00 08 07 1C 06 53 12 63 EB DF];
display-timings {
compatible = "zephyr,panel-timing";
hsync-active = <1>;
vsync-active = <0>;
de-active = <0>;
pixelclk-active = <0>;
hback-porch = <40>;
hsync-len = <32>;
hfront-porch = <8>;
vback-porch = <6>;
vsync-len = <8>;
vfront-porch = <9>;
};
};
};