Add HW-069 v1.1 4-digit TM1637 test with SoftSPI touch and LVGL.
CLK on GPIO22, DIO on GPIO27; value/brightness/colon controls and flashable firmware/cyd package. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
21
include/digit.h
Normal file
21
include/digit.h
Normal file
@@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
void digit_init();
|
||||
|
||||
void digit_set_on(bool on);
|
||||
bool digit_is_on();
|
||||
|
||||
/** 显示数值 0..9999(超出钳位) */
|
||||
void digit_set_value(int value);
|
||||
int digit_get_value();
|
||||
|
||||
/** 亮度 0..100,映射到 TM1637 8 档 */
|
||||
void digit_set_brightness(uint8_t percent);
|
||||
uint8_t digit_brightness();
|
||||
|
||||
void digit_set_colon(bool on);
|
||||
bool digit_colon();
|
||||
|
||||
void digit_clear();
|
||||
Reference in New Issue
Block a user