root / trunk / code / projects / colonet / testing / dongle / robot_receiver / oled.h @ 13
History | View | Annotate | Download (1.79 KB)
1 |
#ifndef _OLED_H_
|
---|---|
2 |
#define _OLED_H_
|
3 |
#ifdef FFPP
|
4 |
|
5 |
#define C_BLUE 0x001f |
6 |
#define C_GREEN 0x07e0 |
7 |
#define C_RED 0xf800 |
8 |
|
9 |
|
10 |
// inialize OLED and SPI
|
11 |
void OLED_init(void); |
12 |
|
13 |
// reset Controller
|
14 |
void Reset_SSD1339(void); |
15 |
|
16 |
// write command or data
|
17 |
void write_c(unsigned char out_command); |
18 |
void write_d(unsigned char out_data); |
19 |
|
20 |
// these write data to the OLED on 8 bit data bus, depends on MCU
|
21 |
void LCD_out(unsigned char cmd); |
22 |
|
23 |
// these functions set / clear pins for OLED control lines. they accecpt a 0 or 1
|
24 |
//void RD(char stat);
|
25 |
//void RW(char stat);
|
26 |
void DC(char stat); |
27 |
void RES(char stat); |
28 |
void CS(char stat); |
29 |
|
30 |
// a stupid delay
|
31 |
//void delay_ms(int count);
|
32 |
|
33 |
// LPC 2138 MCU initialization
|
34 |
//void Initialize(void);
|
35 |
//void feed(void);
|
36 |
|
37 |
void drawcircle(char col, char row, char radius, int lcolor, int fcolor); |
38 |
|
39 |
void drawrect(char scol, char srow, char ecol, char erow, int lcolor, int fcolor); |
40 |
|
41 |
void drawline(char scol, char srow, char ecol, char erow, int lcolor); |
42 |
|
43 |
void drawcopy(char scol, char srow, char ecol, char erow, char ncol, char nrow) ; |
44 |
|
45 |
void drawfill(char fill); |
46 |
|
47 |
void drawclearwindow(char scol, char srow, char ecol, char erow); |
48 |
|
49 |
inline void drawclear(void) ; |
50 |
|
51 |
void drawscroll(char hoff, char srow, char rows, char speed) ; |
52 |
|
53 |
inline void drawscrollstart(void) ; |
54 |
inline void drawscrollstop(void) ; |
55 |
|
56 |
void drawIR(void); |
57 |
|
58 |
void crazycircle (void) ; |
59 |
|
60 |
void crazyrect (void) ; |
61 |
|
62 |
void OLEDtest (void) ; |
63 |
|
64 |
void OLED_init(void); |
65 |
|
66 |
void Reset_SSD1339(void); |
67 |
|
68 |
void write_c(unsigned char out_command); |
69 |
void write_d(unsigned char out_data); |
70 |
|
71 |
// these functions set / clear pins for LCD control lines. they accecpt a 0 or 1
|
72 |
void DC(char stat); |
73 |
|
74 |
void RES(char stat); |
75 |
void CS(char stat); |
76 |
|
77 |
// send to the LCD
|
78 |
void LCD_out(unsigned char cmd); |
79 |
|
80 |
|
81 |
#endif
|
82 |
#endif
|