Read/Write(RW): This signal is used to write the data/cmd to LCD and reads the busy flag of LCD.įor write operation the RW should be LOW and for read operation the R/W should be HIGH.Įnable(EN): This pin is used to send the enable trigger to LCD.Īfter sending the data/cmd, Selecting the data/cmd register, Selecting the Write operation. After that the LCD decodes the data for generating the 5x7 pattern and finally displays on the LCD. If the RS signal is HIGH then the LCD interprets the 8-bit info as data and copies it to data register. If the RS signal is LOW then the LCD interprets the 8-bit info as Command and writes it Command register and performs the action as per the command. This signal is used to differentiate the data/cmd received by the LCD.
![arduino lcd library commands arduino lcd library commands](https://hacksterio.s3.amazonaws.com/uploads/attachments/1017426/2d251279-835f-43ab-8edd-a44987f538ee_DaakxEtskD.jpeg)
Command can be issued to LCD by writing it to Command register of LCD. Any data that needs to be displayed on the LCD has to be written to the data register of LCD.
![arduino lcd library commands arduino lcd library commands](https://howtomechatronics.com/wp-content/uploads/2015/07/Featured-Photo-02.jpg)
Register Select(RS): The LCD has two register namely a Data register and Command register. It also provides the provision to send the the data/cmd in chunks of 4-bit, which is used when there are limited number of GPIO lines on the microcontroller. Let us look at a pin diagram of a commercially available LCD like JHD162 which uses a HD44780 controller and then describe its operation.Īpart from the voltage supply connections the important pins from the programming perspective are the data lines(8-bit Data bus), Register select, Read/Write and Enable pin.ĭata Bus: As shown in the above figure and table, an alpha numeric lcd has a 8-bit data bus referenced as D0-D7.Īs it is a 8-bit data bus, we can send the data/cmd to LCD in bytes.