Skip to content

Commit

Permalink
add st7789 spi lcd graphic driver.
Browse files Browse the repository at this point in the history
  • Loading branch information
Vandoul authored and mysterywolf committed Jul 8, 2023
1 parent bc18837 commit f894426
Show file tree
Hide file tree
Showing 3 changed files with 75 additions and 0 deletions.
1 change: 1 addition & 0 deletions peripherals/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ source "$PKGS_DIR/packages/peripherals/aip650/Kconfig"
source "$PKGS_DIR/packages/peripherals/fingerprint/Kconfig"
source "$PKGS_DIR/packages/peripherals/bt_ecb02c/Kconfig"
source "$PKGS_DIR/packages/peripherals/uat/Kconfig"
source "$PKGS_DIR/packages/peripherals/st7789/Kconfig"

if RT_VER_NUM > 0x40101
source "$PKGS_DIR/packages/peripherals/spi-tools/Kconfig"
Expand Down
42 changes: 42 additions & 0 deletions peripherals/st7789/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@

# Kconfig file for package ST7789
menuconfig PKG_USING_ST7789
depends on RT_VER_NUM >= 0x50000
bool "TFT-LCD ST7789 SPI Graphic driver."
default n

if PKG_USING_ST7789

config PKG_ST_7789_SPI_BUS_NAME
string "spi bus name"
default "spi0"

config PKG_ST_7789_SPI_DEVICE_NAME
string "spi device name"
default "spi00"

config PKG_ST_7789_WIDTH
int "Width of the LCD display"
default 240

config PKG_ST_7789_HEIGHT
int "Height of the LCD display"
default 320

config PKG_ST_7789_DC_PIN
int "DC pin connected to the LCD display"
default -1

config PKG_ST_7789_RES_PIN
int "RESET pin connected to the LCD display"
default -1

config PKG_ST_7789_CS_PIN
int "CS pin connected to the LCD display"
default -1

config PKG_ST_7789_BLK_PIN
int "Backlight pin connected to the LCD display"
default -1

endif
32 changes: 32 additions & 0 deletions peripherals/st7789/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"name": "st7789",
"description": "TFT-LCD ST7789 SPI Graphic driver.",
"description_zh": "TFT-LCD ST7789 SPI 图形驱动",
"enable": "PKG_USING_ST7789",
"keywords": [
"st7789"
],
"category": "peripherals",
"author": {
"name": "Vandoul",
"email": "[email protected]",
"github": "Vandoul"
},
"license": "Apache-2.0",
"repository": "https://github.com/Vandoul/ST7789.git",
"icon": "unknown",
"homepage": "https://github.com/Vandoul/ST7789.git#readme",
"doc": "unknown",
"site": [{
"version": "v1.0.0",
"URL": "https://github.com/Vandoul/ST7789/archive/v1.0.0.zip",
"filename": "ST7789-1.0.0.zip"
},
{
"version": "latest",
"URL": "https://github.com/Vandoul/ST7789.git",
"filename": "Null for git package",
"VER_SHA": "master"
}
]
}

0 comments on commit f894426

Please sign in to comment.