annotate lcd.h @ 50:d7207a9d3c3b

Add write support. LFN still broken though. Make sure we wait for the card to be done after a read or write (didn't seem to break reading but hosed writes).
author Daniel O'Connor <darius@dons.net.au>
date Fri, 05 Apr 2013 00:08:31 +1030
parents be0a1ac64d97
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
8
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
1 void lcd_init(void);
9
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
2 void lcd_writereg(uint16_t index, uint16_t val);
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
3 uint16_t lcd_readreg(uint16_t index);
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
4 uint16_t lcd_readdata(int first);
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
5 void lcd_writedata(uint16_t val);
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
6 void lcd_startgram(uint16_t x, uint16_t y);
8
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
7 void lcd_setpwm(uint16_t val);
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
8 void lcd_pixel(uint16_t x, uint16_t y, uint16_t colour);
9
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
9 void lcd_circle(uint16_t x0, uint16_t y0, uint16_t radius, uint8_t fill, uint16_t colour);
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
10 void lcd_ellipse(int xc, int yc, int rx, int ry, uint8_t fill, uint16_t colour);
8
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
11 void lcd_line(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, uint16_t colour);
9
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
12 void lcd_stripes(void);
be0a1ac64d97 - Add ellipse drawing.
Daniel O'Connor <darius@dons.net.au>
parents: 8
diff changeset
13 uint16_t lcd_parsecol(char c);
4
2c87e30c982d Add LCD init, touch screen writing etc..
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
14
8
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
15 #define LCD_HEIGHT 240
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
16 #define LCD_WIDTH 320
4
2c87e30c982d Add LCD init, touch screen writing etc..
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
17
8
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
18 #define RGB24_565(R, G, B) (((((R) >> 3) & 0x1f) << 11) | ((((G) >> 2) & 0x3f) << 5) | (((B) >> 3) & 0x1f))
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
19 #define LCD_WHITE RGB24_565(255, 255, 255)
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
20 #define LCD_BLACK RGB24_565(0, 0, 0)
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
21 #define LCD_RED RGB24_565(255, 0, 0)
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
22 #define LCD_GREEN RGB24_565(0, 255, 0)
58d76cf522ff Split out code into separate files.
Daniel O'Connor <darius@dons.net.au>
parents: 7
diff changeset
23 #define LCD_BLUE RGB24_565(0, 0, 255)