Exercises

6.1 Draw a circuit diagram to show the typical connection of an LCD to a microcontroller when the LCD is used in 4-bit interface mode.

6.2 Explain the functions of the LCD pins.

6.3 Describe how a user defined character can be created for an LCD. What data should be loaded into the CGRAM to create a ‘ + ’ symbol?

6.4 Describe the steps required to initialise an LCD for operation in 4-bit mode.

6.5 What are the advantages of using an LCD in 4-bit mode?

6.6 What are the advantages of using an LCD in 8-bit mode?

6.7 Draw a flowchart to show the steps required to initialise an LCD in 4-bit mode.

6.8 Modify the program given in Figure 6.10 by adding a function to home the cursor.

6.9 What LCD functions are available in the mikroC Pro for PIC language? Show the program code required to display text ‘Computer’, starting from column 3 of the second row.

6.10 Write the mikroC Pro for PIC program code required to clear only the top row of a 2 × 16 LCD.

6.11 Write a mikroC Pro for PIC program code to display texts ‘LED’ and ‘LCD’ in rows 1 and 2 of a 2 × 16 LCD, respectively.

Get Using LEDs, LCDs and GLCDs in Microcontroller Projects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.