Merge pull request #23 from mateusz-szafraniec/master

workaround for WEH001602 (WS0010 based) OLED display
master
marcoschwartz 7 years ago committed by GitHub
commit 311e58c97d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 6
      LiquidCrystal_I2C.cpp
  2. 2
      LiquidCrystal_I2C.h
  3. BIN
      LiquidCrystal_I2C.o
  4. 2
      library.properties

@ -52,6 +52,11 @@ LiquidCrystal_I2C::LiquidCrystal_I2C(uint8_t lcd_Addr,uint8_t lcd_cols,uint8_t l
_backlightval = LCD_NOBACKLIGHT;
}
void LiquidCrystal_I2C::oled_init(){
_oled = true;
init_priv();
}
void LiquidCrystal_I2C::init(){
init_priv();
}
@ -127,6 +132,7 @@ void LiquidCrystal_I2C::begin(uint8_t cols, uint8_t lines, uint8_t dotsize) {
void LiquidCrystal_I2C::clear(){
command(LCD_CLEARDISPLAY);// clear display, set cursor position to zero
delayMicroseconds(2000); // this command takes a long time!
if (_oled) setCursor(0,0);
}
void LiquidCrystal_I2C::home(){

@ -88,6 +88,7 @@ public:
#endif
void command(uint8_t);
void init();
void oled_init();
////compatibility API function aliases
void blink_on(); // alias for blink()
@ -121,6 +122,7 @@ private:
uint8_t _displaycontrol;
uint8_t _displaymode;
uint8_t _numlines;
bool _oled = false;
uint8_t _cols;
uint8_t _rows;
uint8_t _backlightval;

Binary file not shown.

@ -1,5 +1,5 @@
name=LiquidCrystal_I2C
version=1.1.2
version=1.1.4
author=Frank de Brabander
maintainer=Marco Schwartz <marcolivier.schwartz@gmail.com>
sentence=A library for I2C LCD displays.

Loading…
Cancel
Save