AGirs
LiquidCrystal_I2C_bm.h
Go to the documentation of this file.
1 
11 #pragma once
12 
13 #include <Arduino.h>
14 
15 class LiquidCrystal_I2C : public Print {
16 public:
17 
18  static constexpr uint8_t LCD_5x10DOTS = 0x04U;
19  static constexpr uint8_t LCD_5x8DOTS = 0x00;
20 
21  LiquidCrystal_I2C(uint8_t i2c_Addr, uint8_t lcd_cols, uint8_t lcd_rows);
22 
23  void begin(uint8_t cols, uint8_t rows, uint8_t charsize = LCD_5x8DOTS);
24  void clear();
25  void home();
26  void noDisplay();
27  void display();
28  void noBlink();
29  void blink();
30  void noCursor();
31  void cursor();
32  void scrollDisplayLeft();
33  void scrollDisplayRight();
34  void printLeft();
35  void printRight();
36  void leftToRight();
37  void rightToLeft();
40  void noBacklight();
41  void backlight();
42  void autoscroll();
43  void noAutoscroll();
44  void createChar(uint8_t, uint8_t[]);
45  void setCursor(uint8_t, uint8_t);
46  void init();
47  size_t write(uint8_t);
48 
49 #if 0
51  uint8_t status();
52  void setContrast(uint8_t new_val);
53  uint8_t keypad();
54  void setDelay(int, int);
55  void on();
56  void off();
57  uint8_t init_bargraph(uint8_t graphtype);
58  void draw_horizontal_graph(uint8_t row, uint8_t column, uint8_t len, uint8_t pixel_col_end);
59  void draw_vertical_graph(uint8_t row, uint8_t column, uint8_t len, uint8_t pixel_col_end);
60 #endif
61 
62 private:
63  void command(uint8_t);
64  void init_priv();
65  void send(uint8_t, uint8_t);
66  void write4bits(uint8_t);
67  void expanderWrite(uint8_t);
68  void pulseEnable(uint8_t);
69  uint8_t _Addr;
70  uint8_t _displayfunction;
71  uint8_t _displaycontrol;
72  uint8_t _displaymode;
73  uint8_t _numlines;
74  uint8_t _cols;
75  uint8_t _rows;
76  uint8_t _backlightval;
77 };
void rightToLeft()
This is for text that flows Right to Left.
void noAutoscroll()
This will 'left justify' text from the cursor.
void noCursor()
Turns the underline cursor on/off.
void autoscroll()
This will 'right justify' text from the cursor.
LiquidCrystal_I2C(uint8_t i2c_Addr, uint8_t lcd_cols, uint8_t lcd_rows)
Constructior.
void noBacklight()
Turn the (optional) backlight off/on.
void noBlink()
Turn on and off the blinking cursor.
void leftToRight()
This is for text that flows Left to Right.
static constexpr uint8_t LCD_5x10DOTS
void createChar(uint8_t, uint8_t[])
Allows us to fill the first 8 CGRAM locations with custom characters.
void setCursor(uint8_t, uint8_t)
static constexpr uint8_t LCD_5x8DOTS
void begin(uint8_t cols, uint8_t rows, uint8_t charsize=LCD_5x8DOTS)
void noDisplay()
Turn the display on/off (quickly)