Datasheet
SPI_Glcd_Box(62,40,124,56,1); // Draw box
SPI_Glcd_Rectangle(5,5,84,35,1); // Draw rectangle
SPI_Glcd_Line(0, 63, 127, 0,1); // Draw line
Delay2s();
counter := 5;
while (counter < 60) do // Draw horizontal and vertical line
begin
Delay_ms(250);
SPI_Glcd_V_Line(2, 54, counter, 1);
SPI_Glcd_H_Line(2, 120, counter, 1);
counter := counter + 5;
end;
Delay2s();
SPI_Glcd_Fill(0x00); // Clear Glcd
SPI_Glcd_Set_Font(@Character8x7, 8, 8, 32); // Choose font
"Character8x7"
SPI_Glcd_Write_Text('mikroE', 5, 7, 2); // Write string
for counter := 1 to 10 do// Draw circles
SPI_Glcd_Circle(63,32, 3*counter, 1);
Delay2s();
SPI_Glcd_Box(12,20, 70,63, 2); // Draw box
Delay2s();
SPI_Glcd_Fill(0xFF); // Fill Glcd
SPI_Glcd_Set_Font(@Character8x7, 8, 7, 32); // Change font
someText := '8x7 Font';
SPI_Glcd_Write_Text(someText, 5, 1, 2); // Write string
Delay2s();
SPI_Glcd_Set_Font(@System3x6, 3, 5, 32); // Change font
someText := '3X5 CAPITALS ONLY';
SPI_Glcd_Write_Text(someText, 5, 3, 2); // Write string
Delay2s();
SPI_Glcd_Set_Font(@font5x7, 5, 7, 32); // Change font
someText := '5x7 Font';
SPI_Glcd_Write_Text(someText, 5, 5, 2); // Write string
Delay2s();
SPI_Glcd_Set_Font(@FontSystem5x7_v2, 5, 7, 32); // Change font
someText := '5x7 Font (v2)';
SPI_Glcd_Write_Text(someText, 5, 7, 2); // Write string
Delay2s();
end;
end.
413
MIKROELEKTRONIKA - SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Libraries
mikroPASCAL PRO for AVR
CHAPTER 6