Replace lcd project
This commit is contained in:
parent
356d8ccd9a
commit
e9d5ef46d1
@ -1,20 +0,0 @@
|
||||
## IDF Component Manager Manifest File
|
||||
dependencies:
|
||||
## Required IDF version
|
||||
idf:
|
||||
version: '>=5.3.2'
|
||||
# # Put list of dependencies here
|
||||
# # For components maintained by Espressif:
|
||||
# component: "~1.0.0"
|
||||
# # For 3rd party components:
|
||||
# username/component: ">=1.0.0,<2.0.0"
|
||||
# username2/component2:
|
||||
# version: "~1.0.0"
|
||||
# # For transient dependencies `public` flag can be set.
|
||||
# # `public` flag doesn't have an effect dependencies of the `main` component.
|
||||
# # All dependencies of `main` are public by default.
|
||||
# public: true
|
||||
espressif/arduino-esp32: ^3.1.1
|
||||
lvgl/lvgl: "^8"
|
||||
esp_lcd_sh1107: "^1"
|
||||
esp_lvgl_port: "*"
|
@ -1,133 +0,0 @@
|
||||
#include <esp_lcd_io_i2c.h>
|
||||
#include "driver/i2c_master.h"
|
||||
#include "esp_lcd_panel_ssd1306.h"
|
||||
#include "esp_lvgl_port.h"
|
||||
|
||||
#include "HardwareSerial.h"
|
||||
#include "WiFi.h"
|
||||
|
||||
static const char *TAG = "lcd-panel";
|
||||
|
||||
// https://www.digikey.com/en/products/detail/winstar-display/WEA012864DWPP3N00003/20533255
|
||||
// According to SSD1306 datasheet
|
||||
// Bit number used to represent command and parameter
|
||||
#define SCREEN_WIDTH 128 // OLED display width, in pixels
|
||||
#define SCREEN_HEIGHT 64 // OLED display height, in pixels
|
||||
#define LCD_H_RES SCREEN_WIDTH
|
||||
#define LCD_V_RES SCREEN_HEIGHT
|
||||
#define I2C_HW_ADDR 0x3C
|
||||
#define LCD_PIXEL_CLOCK_HZ (400 * 1000)
|
||||
#define LCD_CMD_BITS 8
|
||||
#define LCD_PARAM_BITS 8
|
||||
#define PIN_NUM_RST -1
|
||||
// Pin may vary based on your schematic
|
||||
#define SDA_PIN GPIO_NUM_21
|
||||
#define SCL_PIN GPIO_NUM_22
|
||||
|
||||
#include "Wire.h"
|
||||
#include "HardwareI2C.h"
|
||||
#include "hal/lv_hal_disp.h"
|
||||
#include "core/lv_obj.h"
|
||||
|
||||
void setup()
|
||||
{
|
||||
Serial.begin(115200);
|
||||
Wire.begin();
|
||||
ESP_LOGI(TAG, "Initialize I2C bus");
|
||||
Serial.println("Initialize I2C bus");
|
||||
i2c_master_bus_handle_t i2c_bus = nullptr;
|
||||
i2c_master_bus_config_t bus_config = {
|
||||
.i2c_port = I2C_STATUS_READ,
|
||||
.sda_io_num = SDA_PIN,
|
||||
.scl_io_num = SCL_PIN,
|
||||
.clk_source = I2C_CLK_SRC_DEFAULT,
|
||||
.glitch_ignore_cnt = 7,
|
||||
.intr_priority = 0,
|
||||
.trans_queue_depth = 0,
|
||||
.flags = {
|
||||
.enable_internal_pullup = true,
|
||||
}
|
||||
};
|
||||
ESP_ERROR_CHECK(i2c_new_master_bus(&bus_config, &i2c_bus));
|
||||
|
||||
ESP_LOGI(TAG, "Install panel IO");
|
||||
Serial.println("Install panel IO");
|
||||
esp_lcd_panel_io_handle_t io_handle = nullptr;
|
||||
esp_lcd_panel_io_i2c_config_t io_config = {
|
||||
.dev_addr = I2C_HW_ADDR,
|
||||
.control_phase_bytes = 1,
|
||||
.dc_bit_offset = 6,
|
||||
.lcd_cmd_bits = LCD_CMD_BITS,
|
||||
.lcd_param_bits = LCD_PARAM_BITS,
|
||||
.scl_speed_hz = LCD_PIXEL_CLOCK_HZ,
|
||||
};
|
||||
ESP_LOGI(TAG, "Install SSD1306 panel driver");
|
||||
ESP_ERROR_CHECK(esp_lcd_new_panel_io_i2c(i2c_bus, &io_config, &io_handle));
|
||||
|
||||
esp_lcd_panel_handle_t panel_handle = nullptr;
|
||||
esp_lcd_panel_dev_config_t panel_config = {
|
||||
.reset_gpio_num = PIN_NUM_RST,
|
||||
.bits_per_pixel = 1,
|
||||
};
|
||||
|
||||
esp_lcd_panel_ssd1306_config_t ssd1306_config = {
|
||||
.height = LCD_V_RES,
|
||||
};
|
||||
panel_config.vendor_config = &ssd1306_config;
|
||||
ESP_LOGI(TAG, "Install SSD1306 panel driver");
|
||||
Serial.println("Install SSD1306 panel driver");
|
||||
ESP_ERROR_CHECK(
|
||||
esp_lcd_new_panel_ssd1306(io_handle, &panel_config, &panel_handle));
|
||||
|
||||
ESP_LOGI(TAG, "Initialize LVGL");
|
||||
Serial.println("Initialize LVGL");
|
||||
const lvgl_port_cfg_t lvgl_cfg = ESP_LVGL_PORT_INIT_CONFIG();
|
||||
lvgl_port_init(&lvgl_cfg);
|
||||
|
||||
const lvgl_port_display_cfg_t disp_cfg = {
|
||||
.io_handle = io_handle,
|
||||
.panel_handle = panel_handle,
|
||||
.buffer_size = LCD_H_RES * LCD_V_RES,
|
||||
.double_buffer = true,
|
||||
.hres = LCD_H_RES,
|
||||
.vres = LCD_V_RES,
|
||||
.monochrome = true,
|
||||
.rotation = {
|
||||
.swap_xy = false,
|
||||
.mirror_x = false,
|
||||
.mirror_y = false,
|
||||
},
|
||||
.flags = {
|
||||
.sw_rotate = false,
|
||||
}
|
||||
};
|
||||
lv_disp_t *disp = lvgl_port_add_disp(&disp_cfg);
|
||||
|
||||
ESP_LOGI(TAG, "Display Scroll Text");
|
||||
Serial.println("Display Scroll Text");
|
||||
// Lock the mutex due to the LVGL APIs are not thread-safe
|
||||
if (lvgl_port_lock(0)) {
|
||||
Serial.println("Display Scroll Text mutex aquired");
|
||||
/* Rotation of the screen */
|
||||
lv_disp_set_rotation(disp, LV_DISP_ROT_NONE);
|
||||
|
||||
//
|
||||
// TODO: Set text here
|
||||
lv_obj_t *scr = lv_disp_get_scr_act(disp);
|
||||
lv_obj_t *label = lv_label_create(scr);
|
||||
// Circular scroll
|
||||
lv_label_set_long_mode(label, LV_LABEL_LONG_SCROLL_CIRCULAR);
|
||||
lv_label_set_text(label, "Hello world!");
|
||||
// Size of the screen
|
||||
// If you use rotation 90 or 270, please set disp->driver->ver_res
|
||||
lv_obj_set_width(label, lv_disp_get_physical_hor_res(disp));
|
||||
lv_obj_align(label, LV_ALIGN_TOP_MID, 0, 0);
|
||||
|
||||
// Release the mutex
|
||||
lvgl_port_unlock();
|
||||
}
|
||||
}
|
||||
|
||||
void loop()
|
||||
{
|
||||
}
|
@ -1,4 +0,0 @@
|
||||
#ifndef MAIN_H
|
||||
#define MAIN_H
|
||||
|
||||
#endif // MAIN_H
|
5
esp/cpp/07_lcd-panel/main/idf_component.yml
Normal file
5
esp/cpp/07_lcd-panel/main/idf_component.yml
Normal file
@ -0,0 +1,5 @@
|
||||
## IDF Component Manager Manifest File
|
||||
dependencies:
|
||||
espressif/arduino-esp32: ^3.1.1
|
||||
lvgl/lvgl: "9.2.0"
|
||||
esp_lcd_sh1107: "^1"
|
237
esp/cpp/07_lcd-panel/main/main.cpp
Normal file
237
esp/cpp/07_lcd-panel/main/main.cpp
Normal file
@ -0,0 +1,237 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2021-2024 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: CC0-1.0
|
||||
*/
|
||||
|
||||
#include <cstdio>
|
||||
#include <unistd.h>
|
||||
#include <sys/lock.h>
|
||||
|
||||
#include "main.h"
|
||||
|
||||
#include "freertos/FreeRTOS.h"
|
||||
#include "freertos/task.h"
|
||||
#include "esp_timer.h"
|
||||
#include "esp_lcd_panel_io.h"
|
||||
#include "esp_lcd_panel_ops.h"
|
||||
#include "esp_err.h"
|
||||
#include "esp_log.h"
|
||||
#include "driver/i2c_master.h"
|
||||
#include "lvgl.h"
|
||||
#include "esp_lcd_panel_vendor.h"
|
||||
|
||||
#define I2C_BUS_PORT 0
|
||||
#define LVGL_TICK_PERIOD_MS 5
|
||||
#define LVGL_TASK_STACK_SIZE (4 * 1024)
|
||||
#define LVGL_TASK_PRIORITY 2
|
||||
#define LVGL_PALETTE_SIZE 8
|
||||
|
||||
static const char *TAG = "lcd-panel";
|
||||
|
||||
// https://www.digikey.com/en/products/detail/winstar-display/WEA012864DWPP3N00003/20533255
|
||||
// According to SSD1306 datasheet
|
||||
// Bit number used to represent command and parameter
|
||||
#define SCREEN_WIDTH 128 // OLED display width, in pixels
|
||||
#define SCREEN_HEIGHT 64 // OLED display height, in pixels
|
||||
#define LCD_H_RES SCREEN_WIDTH
|
||||
#define LCD_V_RES SCREEN_HEIGHT
|
||||
#define I2C_HW_ADDR 0x3C
|
||||
#define LCD_PIXEL_CLOCK_HZ (400 * 1000)
|
||||
#define LCD_CMD_BITS 8
|
||||
#define LCD_PARAM_BITS 8
|
||||
|
||||
// Pin may vary based on your schematic
|
||||
#define PIN_SDA GPIO_NUM_21
|
||||
#define PIN_SCL GPIO_NUM_22
|
||||
#define PIN_RST -1
|
||||
|
||||
// To use LV_COLOR_FORMAT_I1, we need an extra buffer to hold the converted data
|
||||
static uint8_t oled_buffer[LCD_H_RES * LCD_V_RES / 8];
|
||||
// LVGL library is not thread-safe, this example will call LVGL APIs from different tasks, so use a mutex to protect it
|
||||
static _lock_t lvgl_api_lock;
|
||||
|
||||
static bool example_notify_lvgl_flush_ready(esp_lcd_panel_io_handle_t io_panel,
|
||||
esp_lcd_panel_io_event_data_t *edata,
|
||||
void *user_ctx)
|
||||
{
|
||||
auto *disp = (lv_display_t *) user_ctx;
|
||||
lv_display_flush_ready(disp);
|
||||
return false;
|
||||
}
|
||||
|
||||
static void example_lvgl_flush_cb(lv_display_t *disp, const lv_area_t *area,
|
||||
uint8_t *px_map)
|
||||
{
|
||||
auto panel_handle = (esp_lcd_panel_handle_t) lv_display_get_user_data(disp);
|
||||
|
||||
// This is necessary because LVGL reserves 2 x 4 bytes in the buffer, as these are assumed to be used as a palette. Skip the palette here
|
||||
// More information about the monochrome, please refer to https://docs.lvgl.io/9.2/porting/display.html#monochrome-displays
|
||||
px_map += LVGL_PALETTE_SIZE;
|
||||
|
||||
uint16_t hor_res = lv_display_get_physical_horizontal_resolution(disp);
|
||||
int x1 = area->x1;
|
||||
int x2 = area->x2;
|
||||
int y1 = area->y1;
|
||||
int y2 = area->y2;
|
||||
|
||||
for (int y = y1; y <= y2; y++) {
|
||||
for (int x = x1; x <= x2; x++) {
|
||||
/* The order of bits is MSB first
|
||||
MSB LSB
|
||||
bits 7 6 5 4 3 2 1 0
|
||||
pixels 0 1 2 3 4 5 6 7
|
||||
Left Right
|
||||
*/
|
||||
bool chroma_color = (px_map[(hor_res >> 3) * y + (x >> 3)] &
|
||||
1 << (7 - x % 8));
|
||||
|
||||
/* Write to the buffer as required for the display.
|
||||
* It writes only 1-bit for monochrome displays mapped vertically.*/
|
||||
uint8_t *buf = oled_buffer + hor_res * (y >> 3) + (x);
|
||||
if (chroma_color) {
|
||||
(*buf) &= ~(1 << (y % 8));
|
||||
} else {
|
||||
(*buf) |= (1 << (y % 8));
|
||||
}
|
||||
}
|
||||
}
|
||||
// pass the draw buffer to the driver
|
||||
ESP_ERROR_CHECK(
|
||||
esp_lcd_panel_draw_bitmap(panel_handle, x1, y1, x2 + 1, y2 + 1,
|
||||
oled_buffer));
|
||||
}
|
||||
|
||||
static void example_increase_lvgl_tick(void *arg)
|
||||
{
|
||||
/* Tell LVGL how many milliseconds has elapsed */
|
||||
lv_tick_inc(LVGL_TICK_PERIOD_MS);
|
||||
}
|
||||
|
||||
static void example_lvgl_port_task(void *arg)
|
||||
{
|
||||
ESP_LOGI(TAG, "Starting LVGL task");
|
||||
uint32_t time_till_next_ms = 0;
|
||||
while (1) {
|
||||
_lock_acquire(&lvgl_api_lock);
|
||||
time_till_next_ms = lv_timer_handler();
|
||||
_lock_release(&lvgl_api_lock);
|
||||
usleep(1000 * time_till_next_ms);
|
||||
}
|
||||
}
|
||||
|
||||
void setup()
|
||||
{
|
||||
ESP_LOGI(TAG, "Initialize I2C bus");
|
||||
i2c_master_bus_handle_t i2c_bus = nullptr;
|
||||
i2c_master_bus_config_t bus_config = {
|
||||
.i2c_port = I2C_BUS_PORT,
|
||||
.sda_io_num = PIN_SDA,
|
||||
.scl_io_num = PIN_SCL,
|
||||
.clk_source = I2C_CLK_SRC_DEFAULT,
|
||||
.glitch_ignore_cnt = 7,
|
||||
.flags {
|
||||
.enable_internal_pullup = true,
|
||||
},
|
||||
};
|
||||
ESP_ERROR_CHECK(i2c_new_master_bus(&bus_config, &i2c_bus));
|
||||
|
||||
ESP_LOGI(TAG, "Install panel IO");
|
||||
esp_lcd_panel_io_handle_t io_handle = nullptr;
|
||||
esp_lcd_panel_io_i2c_config_t io_config = {
|
||||
.dev_addr = I2C_HW_ADDR,
|
||||
.control_phase_bytes = 1, // According to SSD1306 datasheet
|
||||
.dc_bit_offset = 6, // According to SSD1306 datasheet
|
||||
.lcd_cmd_bits = LCD_CMD_BITS, // According to SSD1306 datasheet
|
||||
.lcd_param_bits = LCD_CMD_BITS, // According to SSD1306 datasheet
|
||||
.scl_speed_hz = LCD_PIXEL_CLOCK_HZ,
|
||||
};
|
||||
ESP_ERROR_CHECK(esp_lcd_new_panel_io_i2c(i2c_bus, &io_config, &io_handle));
|
||||
|
||||
ESP_LOGI(TAG, "Install SSD1306 panel driver");
|
||||
esp_lcd_panel_handle_t panel_handle = nullptr;
|
||||
esp_lcd_panel_dev_config_t panel_config = {
|
||||
.reset_gpio_num = PIN_RST,
|
||||
.bits_per_pixel = 1,
|
||||
};
|
||||
esp_lcd_panel_ssd1306_config_t ssd1306_config = {
|
||||
.height = LCD_V_RES,
|
||||
};
|
||||
panel_config.vendor_config = &ssd1306_config;
|
||||
ESP_ERROR_CHECK(
|
||||
esp_lcd_new_panel_ssd1306(io_handle, &panel_config, &panel_handle));
|
||||
|
||||
ESP_ERROR_CHECK(esp_lcd_panel_reset(panel_handle));
|
||||
ESP_ERROR_CHECK(esp_lcd_panel_init(panel_handle));
|
||||
ESP_ERROR_CHECK(esp_lcd_panel_disp_on_off(panel_handle, true));
|
||||
|
||||
ESP_LOGI(TAG, "Initialize LVGL");
|
||||
lv_init();
|
||||
// create a lvgl display
|
||||
lv_display_t *display = lv_display_create(LCD_H_RES, LCD_V_RES);
|
||||
// associate the i2c panel handle to the display
|
||||
lv_display_set_user_data(display, panel_handle);
|
||||
// create draw buffer
|
||||
void *buf = nullptr;
|
||||
ESP_LOGI(TAG, "Allocate separate LVGL draw buffers");
|
||||
// LVGL reserves 2 x 4 bytes in the buffer, as these are assumed to be used as a palette.
|
||||
size_t draw_buffer_sz = LCD_H_RES * LCD_V_RES / 8 + LVGL_PALETTE_SIZE;
|
||||
buf = heap_caps_calloc(1, draw_buffer_sz,
|
||||
MALLOC_CAP_INTERNAL | MALLOC_CAP_8BIT);
|
||||
assert(buf);
|
||||
|
||||
// LVGL9 suooprt new monochromatic format.
|
||||
lv_display_set_color_format(display, LV_COLOR_FORMAT_I1);
|
||||
// initialize LVGL draw buffers
|
||||
lv_display_set_buffers(display, buf, nullptr, draw_buffer_sz,
|
||||
LV_DISPLAY_RENDER_MODE_FULL);
|
||||
lv_display_set_rotation(display, LV_DISPLAY_ROTATION_90);
|
||||
// set the callback which can copy the rendered image to an area of the display
|
||||
lv_display_set_flush_cb(display, example_lvgl_flush_cb);
|
||||
|
||||
ESP_LOGI(TAG,
|
||||
"Register io panel event callback for LVGL flush ready notification");
|
||||
const esp_lcd_panel_io_callbacks_t cbs = {
|
||||
.on_color_trans_done = example_notify_lvgl_flush_ready,
|
||||
};
|
||||
/* Register done callback */
|
||||
ESP_ERROR_CHECK(
|
||||
esp_lcd_panel_io_register_event_callbacks(io_handle, &cbs, display));
|
||||
|
||||
ESP_LOGI(TAG, "Use esp_timer as LVGL tick timer");
|
||||
const esp_timer_create_args_t lvgl_tick_timer_args = {
|
||||
.callback = &example_increase_lvgl_tick,
|
||||
.name = "lvgl_tick"
|
||||
};
|
||||
esp_timer_handle_t lvgl_tick_timer = nullptr;
|
||||
ESP_ERROR_CHECK(esp_timer_create(&lvgl_tick_timer_args, &lvgl_tick_timer));
|
||||
ESP_ERROR_CHECK(esp_timer_start_periodic(lvgl_tick_timer,
|
||||
LVGL_TICK_PERIOD_MS * 1000));
|
||||
|
||||
ESP_LOGI(TAG, "Create LVGL task");
|
||||
xTaskCreate(example_lvgl_port_task, "LVGL", LVGL_TASK_STACK_SIZE,
|
||||
nullptr, LVGL_TASK_PRIORITY, nullptr);
|
||||
|
||||
ESP_LOGI(TAG, "Display LVGL Scroll Text");
|
||||
// Lock the mutex due to the LVGL APIs are not thread-safe
|
||||
_lock_acquire(&lvgl_api_lock);
|
||||
|
||||
// UI function
|
||||
{
|
||||
lv_obj_t *scr = lv_display_get_screen_active(display);
|
||||
lv_obj_t *label = lv_label_create(scr);
|
||||
// Circular scroll
|
||||
lv_label_set_long_mode(label,
|
||||
LV_LABEL_LONG_WRAP);
|
||||
lv_label_set_text(label,
|
||||
"Hello hello hello hello hello hello hello hello.");
|
||||
// Size of the screen
|
||||
// if you use rotation 90 or 270 use lv_display_get_vertical_resolution
|
||||
lv_obj_set_width(label, lv_display_get_horizontal_resolution(display));
|
||||
lv_obj_align(label, LV_ALIGN_TOP_MID, 0, 0);
|
||||
}
|
||||
|
||||
_lock_release(&lvgl_api_lock);
|
||||
}
|
||||
|
||||
void loop() { }
|
13
esp/cpp/07_lcd-panel/main/main.h
Normal file
13
esp/cpp/07_lcd-panel/main/main.h
Normal file
@ -0,0 +1,13 @@
|
||||
#ifndef MAIN_H
|
||||
#define MAIN_H
|
||||
|
||||
class Display {
|
||||
public:
|
||||
Display();
|
||||
~Display();
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
#endif // MAIN_H
|
Before Width: | Height: | Size: 227 KiB After Width: | Height: | Size: 227 KiB |
@ -2181,67 +2181,95 @@ CONFIG_LV_CONF_SKIP=y
|
||||
# CONFIG_LV_CONF_MINIMAL is not set
|
||||
|
||||
#
|
||||
# Color settings
|
||||
# Color Settings
|
||||
#
|
||||
# CONFIG_LV_COLOR_DEPTH_32 is not set
|
||||
# CONFIG_LV_COLOR_DEPTH_24 is not set
|
||||
CONFIG_LV_COLOR_DEPTH_16=y
|
||||
# CONFIG_LV_COLOR_DEPTH_8 is not set
|
||||
# CONFIG_LV_COLOR_DEPTH_1 is not set
|
||||
CONFIG_LV_COLOR_DEPTH=16
|
||||
# CONFIG_LV_COLOR_16_SWAP is not set
|
||||
# CONFIG_LV_COLOR_SCREEN_TRANSP is not set
|
||||
CONFIG_LV_COLOR_MIX_ROUND_OFS=128
|
||||
CONFIG_LV_COLOR_CHROMA_KEY_HEX=0x00FF00
|
||||
# end of Color settings
|
||||
# end of Color Settings
|
||||
|
||||
#
|
||||
# Memory settings
|
||||
# Memory Settings
|
||||
#
|
||||
# CONFIG_LV_MEM_CUSTOM is not set
|
||||
CONFIG_LV_MEM_SIZE_KILOBYTES=32
|
||||
CONFIG_LV_MEM_ADDR=0x0
|
||||
CONFIG_LV_MEM_BUF_MAX_NUM=16
|
||||
# CONFIG_LV_MEMCPY_MEMSET_STD is not set
|
||||
# end of Memory settings
|
||||
CONFIG_LV_USE_BUILTIN_MALLOC=y
|
||||
# CONFIG_LV_USE_CLIB_MALLOC is not set
|
||||
# CONFIG_LV_USE_MICROPYTHON_MALLOC is not set
|
||||
# CONFIG_LV_USE_RTTHREAD_MALLOC is not set
|
||||
# CONFIG_LV_USE_CUSTOM_MALLOC is not set
|
||||
CONFIG_LV_USE_BUILTIN_STRING=y
|
||||
# CONFIG_LV_USE_CLIB_STRING is not set
|
||||
# CONFIG_LV_USE_CUSTOM_STRING is not set
|
||||
CONFIG_LV_USE_BUILTIN_SPRINTF=y
|
||||
# CONFIG_LV_USE_CLIB_SPRINTF is not set
|
||||
# CONFIG_LV_USE_CUSTOM_SPRINTF is not set
|
||||
CONFIG_LV_MEM_SIZE_KILOBYTES=64
|
||||
CONFIG_LV_MEM_POOL_EXPAND_SIZE_KILOBYTES=0
|
||||
CONFIG_LV_MEM_ADR=0x0
|
||||
# end of Memory Settings
|
||||
|
||||
#
|
||||
# HAL Settings
|
||||
#
|
||||
CONFIG_LV_DISP_DEF_REFR_PERIOD=30
|
||||
CONFIG_LV_INDEV_DEF_READ_PERIOD=30
|
||||
# CONFIG_LV_TICK_CUSTOM is not set
|
||||
CONFIG_LV_DEF_REFR_PERIOD=33
|
||||
CONFIG_LV_DPI_DEF=130
|
||||
# end of HAL Settings
|
||||
|
||||
#
|
||||
# Feature configuration
|
||||
# Operating System (OS)
|
||||
#
|
||||
CONFIG_LV_OS_NONE=y
|
||||
# CONFIG_LV_OS_PTHREAD is not set
|
||||
# CONFIG_LV_OS_FREERTOS is not set
|
||||
# CONFIG_LV_OS_CMSIS_RTOS2 is not set
|
||||
# CONFIG_LV_OS_RTTHREAD is not set
|
||||
# CONFIG_LV_OS_WINDOWS is not set
|
||||
# CONFIG_LV_OS_MQX is not set
|
||||
# CONFIG_LV_OS_CUSTOM is not set
|
||||
CONFIG_LV_USE_OS=0
|
||||
# end of Operating System (OS)
|
||||
|
||||
#
|
||||
# Drawing
|
||||
# Rendering Configuration
|
||||
#
|
||||
CONFIG_LV_DRAW_COMPLEX=y
|
||||
CONFIG_LV_SHADOW_CACHE_SIZE=0
|
||||
CONFIG_LV_CIRCLE_CACHE_SIZE=4
|
||||
CONFIG_LV_LAYER_SIMPLE_BUF_SIZE=24576
|
||||
CONFIG_LV_IMG_CACHE_DEF_SIZE=0
|
||||
CONFIG_LV_GRADIENT_MAX_STOPS=2
|
||||
CONFIG_LV_GRAD_CACHE_DEF_SIZE=0
|
||||
# CONFIG_LV_DITHER_GRADIENT is not set
|
||||
CONFIG_LV_DISP_ROT_MAX_BUF=10240
|
||||
# end of Drawing
|
||||
CONFIG_LV_DRAW_BUF_STRIDE_ALIGN=1
|
||||
CONFIG_LV_DRAW_BUF_ALIGN=4
|
||||
CONFIG_LV_DRAW_LAYER_SIMPLE_BUF_SIZE=24576
|
||||
CONFIG_LV_USE_DRAW_SW=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_RGB565=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_RGB565A8=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_RGB888=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_XRGB8888=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_ARGB8888=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_L8=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_AL88=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_A8=y
|
||||
CONFIG_LV_DRAW_SW_SUPPORT_I1=y
|
||||
CONFIG_LV_DRAW_SW_DRAW_UNIT_CNT=1
|
||||
# CONFIG_LV_USE_DRAW_ARM2D_SYNC is not set
|
||||
# CONFIG_LV_USE_NATIVE_HELIUM_ASM is not set
|
||||
CONFIG_LV_DRAW_SW_COMPLEX=y
|
||||
# CONFIG_LV_USE_DRAW_SW_COMPLEX_GRADIENTS is not set
|
||||
CONFIG_LV_DRAW_SW_SHADOW_CACHE_SIZE=0
|
||||
CONFIG_LV_DRAW_SW_CIRCLE_CACHE_SIZE=4
|
||||
CONFIG_LV_DRAW_SW_ASM_NONE=y
|
||||
# CONFIG_LV_DRAW_SW_ASM_NEON is not set
|
||||
# CONFIG_LV_DRAW_SW_ASM_HELIUM is not set
|
||||
# CONFIG_LV_DRAW_SW_ASM_CUSTOM is not set
|
||||
CONFIG_LV_USE_DRAW_SW_ASM=0
|
||||
# CONFIG_LV_USE_DRAW_VGLITE is not set
|
||||
# CONFIG_LV_USE_DRAW_PXP is not set
|
||||
# CONFIG_LV_USE_DRAW_DAVE2D is not set
|
||||
# CONFIG_LV_USE_DRAW_SDL is not set
|
||||
# CONFIG_LV_USE_DRAW_VG_LITE is not set
|
||||
# CONFIG_LV_USE_VECTOR_GRAPHIC is not set
|
||||
# end of Rendering Configuration
|
||||
|
||||
#
|
||||
# GPU
|
||||
# Feature Configuration
|
||||
#
|
||||
# CONFIG_LV_USE_GPU_ARM2D is not set
|
||||
# CONFIG_LV_USE_GPU_STM32_DMA2D is not set
|
||||
# CONFIG_LV_USE_GPU_RA6M3_G2D is not set
|
||||
# CONFIG_LV_USE_GPU_SWM341_DMA2D is not set
|
||||
# CONFIG_LV_USE_GPU_NXP_PXP is not set
|
||||
# CONFIG_LV_USE_GPU_NXP_VG_LITE is not set
|
||||
# CONFIG_LV_USE_GPU_SDL is not set
|
||||
# end of GPU
|
||||
|
||||
#
|
||||
# Logging
|
||||
@ -2261,29 +2289,40 @@ CONFIG_LV_ASSERT_HANDLER_INCLUDE="assert.h"
|
||||
# end of Asserts
|
||||
|
||||
#
|
||||
# Others
|
||||
# Debug
|
||||
#
|
||||
# CONFIG_LV_USE_PERF_MONITOR is not set
|
||||
# CONFIG_LV_USE_MEM_MONITOR is not set
|
||||
# CONFIG_LV_USE_REFR_DEBUG is not set
|
||||
# CONFIG_LV_SPRINTF_CUSTOM is not set
|
||||
# CONFIG_LV_SPRINTF_USE_FLOAT is not set
|
||||
CONFIG_LV_USE_USER_DATA=y
|
||||
# CONFIG_LV_ENABLE_GC is not set
|
||||
# end of Others
|
||||
# CONFIG_LV_USE_LAYER_DEBUG is not set
|
||||
# CONFIG_LV_USE_PARALLEL_DRAW_DEBUG is not set
|
||||
# end of Debug
|
||||
|
||||
#
|
||||
# Compiler settings
|
||||
# Others
|
||||
#
|
||||
# CONFIG_LV_ENABLE_GLOBAL_CUSTOM is not set
|
||||
CONFIG_LV_CACHE_DEF_SIZE=0
|
||||
CONFIG_LV_IMAGE_HEADER_CACHE_DEF_CNT=0
|
||||
CONFIG_LV_GRADIENT_MAX_STOPS=2
|
||||
CONFIG_LV_COLOR_MIX_ROUND_OFS=128
|
||||
# CONFIG_LV_OBJ_STYLE_CACHE is not set
|
||||
# CONFIG_LV_USE_OBJ_ID is not set
|
||||
# CONFIG_LV_USE_OBJ_PROPERTY is not set
|
||||
# end of Others
|
||||
# end of Feature Configuration
|
||||
|
||||
#
|
||||
# Compiler Settings
|
||||
#
|
||||
# CONFIG_LV_BIG_ENDIAN_SYSTEM is not set
|
||||
CONFIG_LV_ATTRIBUTE_MEM_ALIGN_SIZE=1
|
||||
# CONFIG_LV_ATTRIBUTE_FAST_MEM_USE_IRAM is not set
|
||||
# CONFIG_LV_USE_LARGE_COORD is not set
|
||||
# end of Compiler settings
|
||||
# end of Feature configuration
|
||||
# CONFIG_LV_USE_FLOAT is not set
|
||||
# CONFIG_LV_USE_MATRIX is not set
|
||||
# CONFIG_LV_USE_PRIVATE_API is not set
|
||||
# end of Compiler Settings
|
||||
|
||||
#
|
||||
# Font usage
|
||||
# Font Usage
|
||||
#
|
||||
|
||||
#
|
||||
@ -2310,16 +2349,16 @@ CONFIG_LV_FONT_MONTSERRAT_14=y
|
||||
# CONFIG_LV_FONT_MONTSERRAT_44 is not set
|
||||
# CONFIG_LV_FONT_MONTSERRAT_46 is not set
|
||||
# CONFIG_LV_FONT_MONTSERRAT_48 is not set
|
||||
# CONFIG_LV_FONT_MONTSERRAT_12_SUBPX is not set
|
||||
# CONFIG_LV_FONT_MONTSERRAT_28_COMPRESSED is not set
|
||||
# CONFIG_LV_FONT_DEJAVU_16_PERSIAN_HEBREW is not set
|
||||
# CONFIG_LV_FONT_SIMSUN_14_CJK is not set
|
||||
# CONFIG_LV_FONT_SIMSUN_16_CJK is not set
|
||||
# CONFIG_LV_FONT_UNSCII_8 is not set
|
||||
# CONFIG_LV_FONT_UNSCII_16 is not set
|
||||
# CONFIG_LV_FONT_CUSTOM is not set
|
||||
# end of Enable built-in fonts
|
||||
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_8 is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_10 is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_12 is not set
|
||||
CONFIG_LV_FONT_DEFAULT_MONTSERRAT_14=y
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_16 is not set
|
||||
@ -2339,79 +2378,73 @@ CONFIG_LV_FONT_DEFAULT_MONTSERRAT_14=y
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_44 is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_46 is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_48 is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_12_SUBPX is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_MONTSERRAT_28_COMPRESSED is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_DEJAVU_16_PERSIAN_HEBREW is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_SIMSUN_14_CJK is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_SIMSUN_16_CJK is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_UNSCII_8 is not set
|
||||
# CONFIG_LV_FONT_DEFAULT_UNSCII_16 is not set
|
||||
# CONFIG_LV_FONT_FMT_TXT_LARGE is not set
|
||||
# CONFIG_LV_USE_FONT_COMPRESSED is not set
|
||||
# CONFIG_LV_USE_FONT_SUBPX is not set
|
||||
CONFIG_LV_USE_FONT_PLACEHOLDER=y
|
||||
# end of Font usage
|
||||
# end of Font Usage
|
||||
|
||||
#
|
||||
# Text Settings
|
||||
#
|
||||
CONFIG_LV_TXT_ENC_UTF8=y
|
||||
# CONFIG_LV_TXT_ENC_ASCII is not set
|
||||
CONFIG_LV_TXT_BREAK_CHARS=" ,.;:-_"
|
||||
CONFIG_LV_TXT_BREAK_CHARS=" ,.;:-_)}"
|
||||
CONFIG_LV_TXT_LINE_BREAK_LONG_LEN=0
|
||||
CONFIG_LV_TXT_COLOR_CMD="#"
|
||||
# CONFIG_LV_USE_BIDI is not set
|
||||
# CONFIG_LV_USE_ARABIC_PERSIAN_CHARS is not set
|
||||
# end of Text Settings
|
||||
|
||||
#
|
||||
# Widget usage
|
||||
# Widget Usage
|
||||
#
|
||||
CONFIG_LV_WIDGETS_HAS_DEFAULT_VALUE=y
|
||||
CONFIG_LV_USE_ANIMIMG=y
|
||||
CONFIG_LV_USE_ARC=y
|
||||
CONFIG_LV_USE_BAR=y
|
||||
CONFIG_LV_USE_BTN=y
|
||||
CONFIG_LV_USE_BTNMATRIX=y
|
||||
CONFIG_LV_USE_CANVAS=y
|
||||
CONFIG_LV_USE_CHECKBOX=y
|
||||
CONFIG_LV_USE_DROPDOWN=y
|
||||
CONFIG_LV_USE_IMG=y
|
||||
CONFIG_LV_USE_LABEL=y
|
||||
CONFIG_LV_LABEL_TEXT_SELECTION=y
|
||||
CONFIG_LV_LABEL_LONG_TXT_HINT=y
|
||||
CONFIG_LV_USE_LINE=y
|
||||
CONFIG_LV_USE_ROLLER=y
|
||||
CONFIG_LV_ROLLER_INF_PAGES=7
|
||||
CONFIG_LV_USE_SLIDER=y
|
||||
CONFIG_LV_USE_SWITCH=y
|
||||
CONFIG_LV_USE_TEXTAREA=y
|
||||
CONFIG_LV_TEXTAREA_DEF_PWD_SHOW_TIME=1500
|
||||
CONFIG_LV_USE_TABLE=y
|
||||
# end of Widget usage
|
||||
|
||||
#
|
||||
# Extra Widgets
|
||||
#
|
||||
CONFIG_LV_USE_ANIMIMG=y
|
||||
CONFIG_LV_USE_BUTTON=y
|
||||
CONFIG_LV_USE_BUTTONMATRIX=y
|
||||
CONFIG_LV_USE_CALENDAR=y
|
||||
# CONFIG_LV_CALENDAR_WEEK_STARTS_MONDAY is not set
|
||||
CONFIG_LV_USE_CALENDAR_HEADER_ARROW=y
|
||||
CONFIG_LV_USE_CALENDAR_HEADER_DROPDOWN=y
|
||||
# CONFIG_LV_USE_CALENDAR_CHINESE is not set
|
||||
CONFIG_LV_USE_CANVAS=y
|
||||
CONFIG_LV_USE_CHART=y
|
||||
CONFIG_LV_USE_COLORWHEEL=y
|
||||
CONFIG_LV_USE_IMGBTN=y
|
||||
CONFIG_LV_USE_CHECKBOX=y
|
||||
CONFIG_LV_USE_DROPDOWN=y
|
||||
CONFIG_LV_USE_IMAGE=y
|
||||
CONFIG_LV_USE_IMAGEBUTTON=y
|
||||
CONFIG_LV_USE_KEYBOARD=y
|
||||
CONFIG_LV_USE_LABEL=y
|
||||
CONFIG_LV_LABEL_TEXT_SELECTION=y
|
||||
CONFIG_LV_LABEL_LONG_TXT_HINT=y
|
||||
CONFIG_LV_LABEL_WAIT_CHAR_COUNT=3
|
||||
CONFIG_LV_USE_LED=y
|
||||
CONFIG_LV_USE_LINE=y
|
||||
CONFIG_LV_USE_LIST=y
|
||||
CONFIG_LV_USE_MENU=y
|
||||
CONFIG_LV_USE_METER=y
|
||||
CONFIG_LV_USE_MSGBOX=y
|
||||
CONFIG_LV_USE_ROLLER=y
|
||||
CONFIG_LV_USE_SCALE=y
|
||||
CONFIG_LV_USE_SLIDER=y
|
||||
CONFIG_LV_USE_SPAN=y
|
||||
CONFIG_LV_SPAN_SNIPPET_STACK_SIZE=64
|
||||
CONFIG_LV_USE_SPINBOX=y
|
||||
CONFIG_LV_USE_SPINNER=y
|
||||
CONFIG_LV_USE_SWITCH=y
|
||||
CONFIG_LV_USE_TEXTAREA=y
|
||||
CONFIG_LV_TEXTAREA_DEF_PWD_SHOW_TIME=1500
|
||||
CONFIG_LV_USE_TABLE=y
|
||||
CONFIG_LV_USE_TABVIEW=y
|
||||
CONFIG_LV_USE_TILEVIEW=y
|
||||
CONFIG_LV_USE_WIN=y
|
||||
# end of Extra Widgets
|
||||
# end of Widget Usage
|
||||
|
||||
#
|
||||
# Themes
|
||||
@ -2420,7 +2453,7 @@ CONFIG_LV_USE_THEME_DEFAULT=y
|
||||
# CONFIG_LV_THEME_DEFAULT_DARK is not set
|
||||
CONFIG_LV_THEME_DEFAULT_GROW=y
|
||||
CONFIG_LV_THEME_DEFAULT_TRANSITION_TIME=80
|
||||
CONFIG_LV_USE_THEME_BASIC=y
|
||||
CONFIG_LV_USE_THEME_SIMPLE=y
|
||||
# CONFIG_LV_USE_THEME_MONO is not set
|
||||
# end of Themes
|
||||
|
||||
@ -2434,34 +2467,70 @@ CONFIG_LV_USE_GRID=y
|
||||
#
|
||||
# 3rd Party Libraries
|
||||
#
|
||||
CONFIG_LV_FS_DEFAULT_DRIVE_LETTER=0
|
||||
# CONFIG_LV_USE_FS_STDIO is not set
|
||||
# CONFIG_LV_USE_FS_POSIX is not set
|
||||
# CONFIG_LV_USE_FS_WIN32 is not set
|
||||
# CONFIG_LV_USE_FS_FATFS is not set
|
||||
# CONFIG_LV_USE_FS_MEMFS is not set
|
||||
# CONFIG_LV_USE_FS_LITTLEFS is not set
|
||||
# CONFIG_LV_USE_PNG is not set
|
||||
# CONFIG_LV_USE_FS_ARDUINO_ESP_LITTLEFS is not set
|
||||
# CONFIG_LV_USE_FS_ARDUINO_SD is not set
|
||||
# CONFIG_LV_USE_LODEPNG is not set
|
||||
# CONFIG_LV_USE_LIBPNG is not set
|
||||
# CONFIG_LV_USE_BMP is not set
|
||||
# CONFIG_LV_USE_SJPG is not set
|
||||
# CONFIG_LV_USE_TJPGD is not set
|
||||
# CONFIG_LV_USE_LIBJPEG_TURBO is not set
|
||||
# CONFIG_LV_USE_GIF is not set
|
||||
# CONFIG_LV_BIN_DECODER_RAM_LOAD is not set
|
||||
# CONFIG_LV_USE_RLE is not set
|
||||
# CONFIG_LV_USE_QRCODE is not set
|
||||
# CONFIG_LV_USE_BARCODE is not set
|
||||
# CONFIG_LV_USE_FREETYPE is not set
|
||||
# CONFIG_LV_USE_TINY_TTF is not set
|
||||
# CONFIG_LV_USE_RLOTTIE is not set
|
||||
# CONFIG_LV_USE_THORVG is not set
|
||||
# CONFIG_LV_USE_LZ4 is not set
|
||||
# CONFIG_LV_USE_FFMPEG is not set
|
||||
# end of 3rd Party Libraries
|
||||
|
||||
#
|
||||
# Others
|
||||
#
|
||||
CONFIG_LV_USE_SNAPSHOT=y
|
||||
# CONFIG_LV_USE_SNAPSHOT is not set
|
||||
# CONFIG_LV_USE_SYSMON is not set
|
||||
# CONFIG_LV_USE_PROFILER is not set
|
||||
# CONFIG_LV_USE_MONKEY is not set
|
||||
# CONFIG_LV_USE_GRIDNAV is not set
|
||||
# CONFIG_LV_USE_FRAGMENT is not set
|
||||
# CONFIG_LV_USE_IMGFONT is not set
|
||||
# CONFIG_LV_USE_MSG is not set
|
||||
CONFIG_LV_USE_OBSERVER=y
|
||||
# CONFIG_LV_USE_IME_PINYIN is not set
|
||||
# CONFIG_LV_USE_FILE_EXPLORER is not set
|
||||
# end of Others
|
||||
|
||||
#
|
||||
# Devices
|
||||
#
|
||||
# CONFIG_LV_USE_SDL is not set
|
||||
# CONFIG_LV_USE_X11 is not set
|
||||
# CONFIG_LV_USE_WAYLAND is not set
|
||||
# CONFIG_LV_USE_LINUX_FBDEV is not set
|
||||
# CONFIG_LV_USE_NUTTX is not set
|
||||
# CONFIG_LV_USE_LINUX_DRM is not set
|
||||
# CONFIG_LV_USE_TFT_ESPI is not set
|
||||
# CONFIG_LV_USE_EVDEV is not set
|
||||
# CONFIG_LV_USE_LIBINPUT is not set
|
||||
# CONFIG_LV_USE_ST7735 is not set
|
||||
# CONFIG_LV_USE_ST7789 is not set
|
||||
# CONFIG_LV_USE_ST7796 is not set
|
||||
# CONFIG_LV_USE_ILI9341 is not set
|
||||
# CONFIG_LV_USE_GENERIC_MIPI is not set
|
||||
# CONFIG_LV_USE_RENESAS_GLCDC is not set
|
||||
# CONFIG_LV_USE_OPENGLES is not set
|
||||
# CONFIG_LV_USE_QNX is not set
|
||||
# end of Devices
|
||||
|
||||
#
|
||||
# Examples
|
||||
#
|
||||
@ -2473,9 +2542,12 @@ CONFIG_LV_BUILD_EXAMPLES=y
|
||||
#
|
||||
# CONFIG_LV_USE_DEMO_WIDGETS is not set
|
||||
# CONFIG_LV_USE_DEMO_KEYPAD_AND_ENCODER is not set
|
||||
# CONFIG_LV_USE_DEMO_BENCHMARK is not set
|
||||
# CONFIG_LV_USE_DEMO_RENDER is not set
|
||||
# CONFIG_LV_USE_DEMO_SCROLL is not set
|
||||
# CONFIG_LV_USE_DEMO_STRESS is not set
|
||||
# CONFIG_LV_USE_DEMO_MUSIC is not set
|
||||
# CONFIG_LV_USE_DEMO_FLEX_LAYOUT is not set
|
||||
# CONFIG_LV_USE_DEMO_MULTILANG is not set
|
||||
# end of Demos
|
||||
# end of LVGL configuration
|
||||
# end of Component config
|
Loading…
x
Reference in New Issue
Block a user