Mercurial > ~darius > hgwebdir.cgi > stm32test
view lcd.h @ 13:96c345d304af default tip
Add 1wire code.
1wire.c, 1wire.h and 1wire-config.h are copied avr-lib.
author | Daniel O'Connor <darius@dons.net.au> |
---|---|
date | Wed, 08 Feb 2012 10:37:22 +1030 |
parents | be0a1ac64d97 |
children |
line wrap: on
line source
void lcd_init(void); void lcd_writereg(uint16_t index, uint16_t val); uint16_t lcd_readreg(uint16_t index); uint16_t lcd_readdata(int first); void lcd_writedata(uint16_t val); void lcd_startgram(uint16_t x, uint16_t y); void lcd_setpwm(uint16_t val); void lcd_pixel(uint16_t x, uint16_t y, uint16_t colour); void lcd_circle(uint16_t x0, uint16_t y0, uint16_t radius, uint8_t fill, uint16_t colour); void lcd_ellipse(int xc, int yc, int rx, int ry, uint8_t fill, uint16_t colour); void lcd_line(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, uint16_t colour); void lcd_stripes(void); uint16_t lcd_parsecol(char c); #define LCD_HEIGHT 240 #define LCD_WIDTH 320 #define RGB24_565(R, G, B) (((((R) >> 3) & 0x1f) << 11) | ((((G) >> 2) & 0x3f) << 5) | (((B) >> 3) & 0x1f)) #define LCD_WHITE RGB24_565(255, 255, 255) #define LCD_BLACK RGB24_565(0, 0, 0) #define LCD_RED RGB24_565(255, 0, 0) #define LCD_GREEN RGB24_565(0, 255, 0) #define LCD_BLUE RGB24_565(0, 0, 255)