33 lines
585 B
C
33 lines
585 B
C
#ifndef LCD_H
|
|
#define LCD_H
|
|
|
|
#include <stdio.h>
|
|
#include <inttypes.h>
|
|
#include "esp_log.h"
|
|
#include "spi.h"
|
|
|
|
#define LCD_CS 7
|
|
#define LCD_DS 6
|
|
|
|
#define USE_HORIZONTAL 2 //设置横屏或者竖屏显示 0或1为竖屏 2或3为横屏
|
|
#define LCD_WW 320
|
|
#define LCD_HH 240
|
|
|
|
typedef struct{
|
|
uint16_t buf[LCD_WW*LCD_HH];
|
|
uint16_t fps_count;
|
|
uint16_t fps;
|
|
}lcd_t;
|
|
|
|
extern lcd_t lcd_main;
|
|
|
|
|
|
void LCD_Address_Set(uint16_t x1,uint16_t y1,uint16_t x2,uint16_t y2);
|
|
void lcd_init();
|
|
|
|
void lcd_clear_buf(uint16_t Color);
|
|
void lcd_send_full_buf();
|
|
void lcd_one_second_task();
|
|
|
|
|
|
#endif |