LCD 1602 Driver with ESP32 I2C 1.1
This is a complete driver for LCD 1602 using I2C with the ESP32
Loading...
Searching...
No Matches
LCD1602 External API:s

All of the external API:s used the for LCD 1602 driver. More...

Topics

 Configurable Defines
 configurable defines for setting up the LCD1602
 External Functions
 External functions for LCD 1602 API.

Typedefs

typedef enum LCD_WRITE_STATUS LCD_WRITE_STATUS
 Enum for returning the result of writing to the LCD.

Enumerations

enum  LCD_WRITE_STATUS { LCD_WRITE_FINISHED , LCD_WRITE_NOT_FINISHED , LCD_WRITE_INTERRUPTED , LCD_TOO_LONG_STRING }
 Enum for returning the result of writing to the LCD. More...

Detailed Description

All of the external API:s used the for LCD 1602 driver.

Example use of this driver

autotoc_md2

#include "lcd_1602.h"
void app_main(void)
{
i2c_master_bus_handle_t bus_handle;
i2c_master_dev_handle_t dev_handle;
i2c_open(&bus_handle, &dev_handle, DEVICE_ADDRESS);
lcd_1602_init(dev_handle);
while(true) {
lcd_1602_send_string(dev_handle, "Hello world\n");
vTaskDelay(pdMS_TO_TICKS(1000));
}
}
#define DEVICE_ADDRESS
Definition lcd_1602.h:49
LCD_WRITE_STATUS lcd_1602_send_string(i2c_master_dev_handle_t handle, char *str)
Writes out data to the LCD.
Definition lcd_1602.c:111
uint8_t lcd_1602_init(i2c_master_dev_handle_t handle)
initializes the LCD 1602 correctly according to the datasheet.
Definition lcd_1602.c:141
uint8_t i2c_open(i2c_master_bus_handle_t *bus_handle, i2c_master_dev_handle_t *dev_handle, const uint8_t address)
initializes the i2c communications and points the handles to correctly initialized variables on the h...
Definition lcd_i2c.c:3

Typedef Documentation

◆ LCD_WRITE_STATUS

Enum for returning the result of writing to the LCD.

Enumeration Type Documentation

◆ LCD_WRITE_STATUS

Enum for returning the result of writing to the LCD.

Enumerator
LCD_WRITE_FINISHED 
LCD_WRITE_NOT_FINISHED 
LCD_WRITE_INTERRUPTED 
LCD_TOO_LONG_STRING 

Definition at line 58 of file lcd_1602.h.

58 {
LCD_WRITE_STATUS
Enum for returning the result of writing to the LCD.
Definition lcd_1602.h:58
@ LCD_WRITE_NOT_FINISHED
Definition lcd_1602.h:60
@ LCD_WRITE_INTERRUPTED
Definition lcd_1602.h:61
@ LCD_TOO_LONG_STRING
Definition lcd_1602.h:62
@ LCD_WRITE_FINISHED
Definition lcd_1602.h:59