24 righe
576 B
C
24 righe
576 B
C
#ifndef _LEDBAR_H
|
|
#define _LEDBAR_H
|
|
|
|
#include <stdint.h>
|
|
|
|
#define LEDBAR_ROWS 7
|
|
#define LEDBAR_COLS 128
|
|
|
|
const uint8_t LEDBAR_PIN_ROWS[LEDBAR_ROWS] = { 8, 7, 6, 5, 4, 3, 2 };
|
|
const uint8_t LEDBAR_PIN_STROBE = 9;
|
|
|
|
typedef enum {
|
|
LEDBAR_FRONTBUF,
|
|
LEDBAR_BACKBUF
|
|
} ledbar_buf_t;
|
|
|
|
void ledbar_init(void);
|
|
void ledbar_wait_vsync(void);
|
|
void ledbar_swap_buf(void);
|
|
void ledbar_clear(ledbar_buf_t buf);
|
|
void ledbar_setchar(ledbar_buf_t buf, int16_t col, uint8_t ch);
|
|
void ledbar_settext(ledbar_buf_t buf, int16_t col, const char* text, uint8_t spacing = 1);
|
|
|
|
#endif // _LEDBAR_H
|