Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Waveshare ESP32-S3-Touch-LCD-4.3 #747

Merged
merged 1 commit into from
May 30, 2024
Merged
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
86 changes: 86 additions & 0 deletions user_setups/esp32s3/ws_esp32_s3_touch_lcd_4p3.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
;***************************************************;
; Waveshare ESP32-S3-Touch-LCD-4.3 ;
; - 16-bit RGB TFT ;
; - GT911 touch controller ;
;***************************************************;


[ws_esp32_s3_touch]
extends = arduino_esp32s3_v2, flash_8mb
board = esp32-s3-devkitc-1
board_build.arduino.memory_type = qio_opi

build_flags =
${arduino_esp32s3_v2.build_flags}
${esp32s3.ps_ram}
;-DARDUINO_USB_CDC_ON_BOOT
;-DUSE_USB_CDC_CONSOLE

;region -- ArduinoGFX build options ------------------------
-D HASP_USE_ARDUINOGFX=1
-D HASP_LV_USE_SW_ROTATE=1
;endregion

lib_deps =
${arduino_esp32s3_v2.lib_deps}
${arduinogfx.lib_deps}
Arduino_RPi_DPI_RGBPanel_mod
${goodix.lib_deps}

[env:ws_esp32_s3_touch_lcd_4p3]
extends = ws_esp32_s3_touch

build_flags =
-D HASP_MODEL="Waveshare ESP32-S3-Touch-LCD-4.3"
${ws_esp32_s3_touch.build_flags}
; Bus Settings
-D LV_VDB_SIZE=76800 ; 10% of full framebuffer
-D TFT_WIDTH=800
-D TFT_HEIGHT=480
-D TFT_DE=5
-D TFT_VSYNC=3
-D TFT_HSYNC=46
-D TFT_PCLK=7
-D TFT_B0=14
-D TFT_B1=38
-D TFT_B2=18
-D TFT_B3=17
-D TFT_B4=10
-D TFT_G0=39
-D TFT_G1=0
-D TFT_G2=45
-D TFT_G3=48
-D TFT_G4=47
-D TFT_G5=21
-D TFT_R0=1
-D TFT_R1=2
-D TFT_R2=42
-D TFT_R3=41
-D TFT_R4=40
-D TFT_BCKL=6 ; use GPIO06 as backlight PIN
; Panel Settings
-D TFT_HSYNC_POLARITY=0
-D TFT_HSYNC_FRONT_PORCH=20 ; Maximum HSYNC Front Porch
-D TFT_HSYNC_PULSE_WIDTH=10 ; Typical HSYNC Pulse Width
-D TFT_HSYNC_BACK_PORCH=10 ; Typical HSYNC Back Porch
-D TFT_VSYNC_POLARITY=0
-D TFT_VSYNC_FRONT_PORCH=10 ; Maximum VSYNC Front Porch
-D TFT_VSYNC_PULSE_WIDTH=10 ; Typical VSYNC Pulse Width
-D TFT_VSYNC_BACK_PORCH=10 ; Typical VSYNC Back Porch
-D TFT_PCLK_ACTIVE_NEG=0
-D TFT_PREFER_SPEED=14000000 ; 1/2 of Typical DCLK Frequency
-D TFT_AUTO_FLUSH=1
; Touch Settings
-D TOUCH_WIDTH=800
-D TOUCH_HEIGHT=480
-D TOUCH_DRIVER=0x911
-D TOUCH_SCL=9
-D TOUCH_SDA=8
-D TOUCH_IRQ=-1
-D TOUCH_RST=-1
-D I2C_TOUCH_ADDRESS=0x5d ; or 0x5D
-D I2C_TOUCH_FREQUENCY=400000
-D BACKLIGHT_FREQUENCY=1000 ;adopted frerquency for MP3302DJ-LF-Z (200 to 1000Hz) ->higher is better for sound!
lib_deps =
${sunton-esp32-s3-tft.lib_deps}
${goodix.lib_deps}