Heavily documented control library for the uOLED-96-G1 (SGC) by 4D Systems. Will likely work with any of the 4D Systems serial controlled screens. <<info>> All examples in the documentation have been tested to the best of my current abilities, but there are a few functions that I simply do not use. I have created a Lighthouse page for this library. You may submit bug reports or feature requests to [[http://mbed-uoled.lighthouseapp.com|this page]]. If you really do not wish to sign up for a Lighthouse account you may also post any bugs or requests [[/users/Nakor/notebook/uoled-bug-reports/|here]]. <</info>>
Dependents: DS18B20 DS18B20GSM Astromed Astromed_build20121123
Diff: uOLED.cpp
- Revision:
- 30:41a872ad6155
- Parent:
- 29:757036aa73cd
- Child:
- 31:7ad5bf258a1e
--- a/uOLED.cpp Tue Dec 28 21:24:03 2010 +0000 +++ b/uOLED.cpp Sat Jan 08 09:06:11 2011 +0000 @@ -2,10 +2,11 @@ #include "mbed.h" -#define OLED_INITDELAYMS 500 +#define OLED_INITDELAYMS 1200 #define OLED_ACK 0x06 // Ok #define OLED_NAK 0x15 // Error +//uOLED *pSGC; @@ -14,6 +15,8 @@ _reset(reset) { _oled.baud(230400); + + //friend class uOLED_watch; } /******************/ @@ -27,6 +30,8 @@ } + + /******************/ /* Public */ /******************/ @@ -126,6 +131,23 @@ return (_oled.getc() == OLED_ACK); } +bool uOLED::drawImageSD_16bit(char x, char y, char width, char height, char colourMode, char sectorHi, char sectorMid, char sectorLow) +{ + + _oled.putc(0x40); + _oled.putc(0x49); + _oled.putc(x); + _oled.putc(y); + _oled.putc(width); + _oled.putc(height); + _oled.putc(colourMode); + _oled.putc(sectorHi); + _oled.putc(sectorMid); + _oled.putc(sectorLow); + + return (_oled.getc() == OLED_ACK); +} + bool uOLED::drawLine(char x1, char y1, char x2, char y2, short red, short green, short blue) { short color = getRGB(red, green, blue);