I2cLCD library that can display cursor.
Fork of I2cLCD by
Diff: I2cLCD.h
- Revision:
- 1:f973d1359998
- Parent:
- 0:b3cc6ae3dfd8
- Child:
- 2:4e32baaf019b
--- a/I2cLCD.h Mon Jun 28 14:20:58 2010 +0000 +++ b/I2cLCD.h Sun Feb 09 09:04:30 2014 +0000 @@ -4,7 +4,8 @@ #include "mbed.h" -class I2cLCD : public Stream { +class I2cLCD : public Stream +{ public: enum IconType { @@ -23,7 +24,7 @@ Antenna = 0x1000, }; - I2cLCD(PinName sda, PinName scl, PinName rp); + I2cLCD(I2C& i2c, PinName rp); #if DOXYGEN_ONLY int putc(int c); int printf(const char* format, ...); @@ -35,7 +36,7 @@ void seticon(IconType type); void clearicon(IconType type); void puticon(int flg); - + protected: virtual int _putc(int value); virtual int _getc(); @@ -44,15 +45,15 @@ void character(int column, int row, int c); void writeCommand( int cmd ); void writeData( int data ); - + DigitalOut _rs; - I2C _i2c; + I2C& _i2c; int _column; int _row; - + char contrast; int icon; - + }; #endif \ No newline at end of file