-
-
Notifications
You must be signed in to change notification settings - Fork 196
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #831 from marsman7/lovyangfx_tft_offset
add lovyangfx custom offset for tft
- Loading branch information
Showing
3 changed files
with
61 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
;**********************************************************; | ||
; Waveshare ESP32-S3 TFT 1.69inch 240x280 C-Touch ; | ||
; - ST7789V2 TFT SPI 4-WIRE ; | ||
; - CST816s touch controller ; | ||
;**********************************************************; | ||
|
||
[env:waveshare-s3-1_69-ctp] | ||
extends = arduino_esp32s3_v2, flash_16mb | ||
board = esp32-s3-devkitc-1 | ||
board_build.arduino.memory_type = qio_opi | ||
|
||
build_flags = | ||
-D HASP_MODEL="Waveshare micro TFT" | ||
${arduino_esp32s3_v2.build_flags} | ||
${esp32s3.ps_ram} | ||
; -D USE_USB_CDC_CONSOLE=1 | ||
; -D ARDUINO_USB_MODE=1 | ||
; -D ARDUINO_USB_CDC_ON_BOOT=1 | ||
|
||
# --- Display settings --- | ||
-D LGFX_USE_V1=1 ; for lovyangfx driver | ||
-D HASP_USE_LGFX_TOUCH=1 ; for lovyangfx driver | ||
-D ST7789_DRIVER=1 | ||
-D SPI_FREQUENCY=80000000 | ||
-D TFT_ROTATION=0 ; 0=0, 1=90, 2=180 or 3=270 degree | ||
-D TFT_WIDTH=240 | ||
-D TFT_HEIGHT=280 | ||
-D TFT_OFFSET_Y=20 | ||
-D TFT_MOSI=7 | ||
-D TFT_SCLK=6 | ||
-D TFT_CS=5 | ||
-D TFT_DC=4 | ||
-D TFT_RST=8 | ||
-D TFT_BL=15 | ||
-D TFT_BCKL=15 | ||
; -D TFT_INVERSION_ON | ||
; -D TFT_RGB_ORDER TFT_BGR | ||
|
||
# --- Touch settings --- | ||
-D TOUCH_DRIVER=0x0816 | ||
-D TOUCH_SDA=11 | ||
-D TOUCH_SCL=10 | ||
-D TOUCH_RST=13 | ||
-D TOUCH_IRQ=14 | ||
-D TOUCH_CS=-1 | ||
-D I2C_TOUCH_FREQUENCY=400000 | ||
-D I2C_TOUCH_ADDRESS=0x15 | ||
|
||
lib_deps = | ||
${arduino_esp32s3_v2.lib_deps} | ||
${lovyangfx.lib_deps} | ||
|
||
upload_protocol = esp-builtin |