Прошло 2 года.
This commit is contained in:
4
lib/epdiy/examples/calibration_helper/CMakeLists.txt
Normal file
4
lib/epdiy/examples/calibration_helper/CMakeLists.txt
Normal file
@@ -0,0 +1,4 @@
|
||||
cmake_minimum_required(VERSION 3.16.0)
|
||||
set(EXTRA_COMPONENT_DIRS "../../")
|
||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||
project(vcom_calibration_helper)
|
||||
@@ -0,0 +1,3 @@
|
||||
set(app_sources "main.c")
|
||||
|
||||
idf_component_register(SRCS ${app_sources} REQUIRES epdiy)
|
||||
42
lib/epdiy/examples/calibration_helper/main/main.c
Normal file
42
lib/epdiy/examples/calibration_helper/main/main.c
Normal file
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* Simple helper program enabling EPD power to allow for easier VCOM calibration.
|
||||
*
|
||||
* This is only needed for boards V5 or lower!
|
||||
**/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include "esp_heap_caps.h"
|
||||
#include "esp_log.h"
|
||||
#include "freertos/FreeRTOS.h"
|
||||
#include "freertos/task.h"
|
||||
#include "sdkconfig.h"
|
||||
|
||||
#include "epdiy.h"
|
||||
|
||||
// choose the default demo board depending on the architecture
|
||||
#ifdef CONFIG_IDF_TARGET_ESP32
|
||||
#define DEMO_BOARD epd_board_v6
|
||||
#elif defined(CONFIG_IDF_TARGET_ESP32S3)
|
||||
#define DEMO_BOARD epd_board_v7
|
||||
#endif
|
||||
|
||||
void enable_vcom() {
|
||||
epd_init(&DEMO_BOARD, &ED097TC2, EPD_LUT_64K);
|
||||
ESP_LOGI("main", "waiting for one second before poweron...");
|
||||
vTaskDelay(1000);
|
||||
ESP_LOGI("main", "enabling VCOMM...");
|
||||
epd_poweron();
|
||||
ESP_LOGI(
|
||||
"main",
|
||||
"VCOMM enabled. You can now adjust the on-board trimmer to the VCOM value specified on the "
|
||||
"display."
|
||||
);
|
||||
while (1) {
|
||||
vTaskDelay(1000);
|
||||
};
|
||||
}
|
||||
|
||||
void app_main() {
|
||||
enable_vcom();
|
||||
}
|
||||
1500
lib/epdiy/examples/calibration_helper/sdkconfig.defaults.esp32
Normal file
1500
lib/epdiy/examples/calibration_helper/sdkconfig.defaults.esp32
Normal file
File diff suppressed because it is too large
Load Diff
1455
lib/epdiy/examples/calibration_helper/sdkconfig.defaults.esp32s3
Normal file
1455
lib/epdiy/examples/calibration_helper/sdkconfig.defaults.esp32s3
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user