Skip to content

Commit

Permalink
Develop into 2.0.6 (#133)
Browse files Browse the repository at this point in the history
* Prepared new version 2.0.4

* Updated boards

* Updated platformio.ini

* Added extern for touch_calibration_data

* New build system for CI

* Updated PCLK_HZ

* UPdated variables for ST7789

* Update Variables GC9A01

* Updated ILI9341

* LVGL to ^8.3.9

* Typos

* DST7262 variables

* Typos and ST7701 variables

* ST7701_LINE_CONFIG

* ST7796 variables

* SPI_DMA_CHANNEL

* CST816S variables

* GT911 variables

* XPT2046 variables

* Typo

* esp_lcd_panel_io_3wire_spi_config_t

* Updated boards

* Updated boards

* BOARD_HAS_

* Update board

* rename with interfaces

* Added Interface type to boards for LCD/TOUCH

* All boards

* wip ESP32-24232s022

* Updated 2432S022C

* Updated boards
Added warning for st7789_i80

* Added 8048S070R

* Updated boards

* Do not invert colors

* Added IPS Setting

* rename, include strength

* Removed v11 version

* Added logging

* logging

* Removed touch_config flags

* Removed not required backlight set

* Added strength

* GT911, fix for non matching touch resolutions

* UPdated boards

* Updated boards

* GT911 vendorId

* updated boards

* Update board

* Boards to main

* Updated boards

* UPdate boards

* %d->%f

* Added logging for vendor config initialization

* Two decimals

* Updated boards

* Data bits are upper D8-D15

* Updated boards

* Updated boards

* Added PlatformIo badge

* Use LVGL pixel buffer size and malloc flags for json (#124)

* Updated boards

* Added spi_bus_config_t flags, intr flags and max_size

* Small changes esp3228S022

* Update version to 2.0.5

* Minor changes to st7789_i80

* BCKL to GPIO_BCKL

* Typo miso_io_num

* Changed location of tuning off the display when initializing

* Updated boards

* Updated boards
  • Loading branch information
rzeldent authored Feb 19, 2024
1 parent d3c19d9 commit f995993
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 9 deletions.
10 changes: 5 additions & 5 deletions src/esp32_smartdisplay.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ void smartdisplay_lcd_set_backlight(float duty)
if (duty < 0.0)
duty = 0.0f;
#if ESP_ARDUINO_VERSION_MAJOR >= 3
ledcWrite(BCKL, duty * PWM_MAX_BCKL);
ledcWrite(GPIO_BCKL, duty * PWM_MAX_BCKL);
#else
ledcWrite(PWM_CHANNEL_BCKL, duty * PWM_MAX_BCKL);
#endif
Expand Down Expand Up @@ -235,14 +235,14 @@ void smartdisplay_init()

lv_init();
// Setup backlight
pinMode(BCKL, OUTPUT);
pinMode(GPIO_BCKL, OUTPUT);
digitalWrite(GPIO_BCKL, LOW);
#if ESP_ARDUINO_VERSION_MAJOR >= 3
ledcAttach(BCKL, PWM_FREQ_BCKL, PWM_BITS_BCKL);
ledcAttach(GPIO_BCKL, PWM_FREQ_BCKL, PWM_BITS_BCKL);
#else
ledcSetup(PWM_CHANNEL_BCKL, PWM_FREQ_BCKL, PWM_BITS_BCKL);
ledcAttachPin(BCKL, PWM_CHANNEL_BCKL);
ledcAttachPin(GPIO_BCKL, PWM_CHANNEL_BCKL);
#endif
digitalWrite(BCKL, LOW);
// Setup TFT display
lv_disp_drv_init(&disp_drv);
disp_drv.hor_res = LCD_WIDTH;
Expand Down
2 changes: 1 addition & 1 deletion src/lvgl_gc9a01_spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ void lvgl_lcd_init(lv_disp_drv_t *drv)
// Create SPI bus
const spi_bus_config_t spi_bus_config = {
.mosi_io_num = GC9A01_SPI_BUS_MOSI_IO_NUM,
.mosi_io_num = GC9A01_SPI_BUS_MISO_IO_NUM,
.miso_io_num = GC9A01_SPI_BUS_MISO_IO_NUM,
.sclk_io_num = GC9A01_SPI_BUS_SCLK_IO_NUM,
.quadwp_io_num = GC9A01_SPI_BUS_QUADWP_IO_NUM,
.quadhd_io_num = GC9A01_SPI_BUS_QUADHD_IO_NUM,
Expand Down
8 changes: 5 additions & 3 deletions src/lvgl_st7789_i80.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#ifdef LCD_ST7789_I80

#warning Still under development. Will most probably NOT function!

#include <esp32_smartdisplay.h>
#include <esp_lcd_panel_io.h>
#include <esp_lcd_panel_vendor.h>
Expand Down Expand Up @@ -96,8 +94,12 @@ void lvgl_lcd_init(lv_disp_drv_t *drv)

ESP_ERROR_CHECK(esp_lcd_panel_reset(panel_handle));
ESP_ERROR_CHECK(esp_lcd_panel_init(panel_handle));
// IPS

#ifdef LCD_IPS
// If LCD is IPS invert the colors
ESP_ERROR_CHECK(esp_lcd_panel_invert_color(panel_handle, true));
#endif

drv->user_data = panel_handle;
drv->flush_cb = st7789_lv_flush;
}
Expand Down

0 comments on commit f995993

Please sign in to comment.