1234567891011121314151617181920212223242526272829303132333435 |
- #ifndef _DISPLAY_H_
- #define _DISPLAY_H_
- #include <stdlib.h>
- #include "pico/stdlib.h"
- #include "sd1306.h"
- #include "font8x8.h"
- // extern uint8_t display_buffer[];
- void display_init(void);
- void display_main(void);
- bool display_clear(void);
- bool display_putstr(char *str, uint8_t col_x, uint8_t col_y, bool reverse);
- typedef struct {
- uint16_t command;
- void *data;
- } display_cmd_t;
- typedef struct {
- uint8_t col;
- uint8_t row;
- bool reverse;
- char str[OLED_WIDTH/FONT_WIDTH + 1];
- } putstr_t;
- #define DISPLAY_CMD_NONE 0x0000
- #define DISPLAY_CMD_CLEAR 0x0001
- #define DISPLAY_CMD_PUTSTR 0x0002
- #endif
|