led: add basic Charlieplexing scan

This commit is contained in:
Dien-Nhung Nguyen-Phu
2024-05-19 16:22:51 +07:00
parent 7d7389cac5
commit 90cdb61063
4 changed files with 238 additions and 15 deletions

14
src/leddrv.h Normal file
View File

@@ -0,0 +1,14 @@
#ifndef __LEDDRV_H__
#define __LEDDRV_H__
#include "CH58x_common.h"
#define LED_COLS 44
#define LED_ROWS 11
void led_init();
void leds_releaseall();
void led_write2dcol(int dcol, uint16_t col1_val, uint16_t col2_val);
void led_write2row_raw(int row, int which_half, uint32_t val);
#endif /* __LEDDRV_H__ */