There are some applications where we may want to create custom fonts, such as special characters, symbols or logos on the LCD. This project will show how to create the symbol of an arrow pointing upwards on the LCD, and then display ‘Up arrow - <symbol of up arrow>’ on the first row of the LCD.
mikroC Pro for PIC compiler provides a tool that makes the creation of custom fonts very easy. The steps for creating a font of any shape are given below:
The block diagram of the project is as in Figure 11.1.
The circuit diagram of the project is as in Figure 11.2.
The PDL of this project is very simple and is given in Figure 11.14.
The program is named LCD4.C and the program listing of the project is shown in Figure 11.15. At the beginning of the project, the connections between the microcontroller and the LCD are defined using sbit statements. PORT B is configured as a digital output port. The LCD is initialised, cleared and the cursor is turned OFF. Then the Lcd_Out function is called to display the text ‘Up arrow – ’, starting at row 1 and column 1 of the LCD. Function CustomChar is generated by the compiler and this function displays the created font at the specified row and column positions.
Figure 11.16 shows a picture of the LCD display.
3.21.105.193