Datasheet
/*
* If PORTA_0 is pressed, toggle the display between graphic
panel 0 and graphic 1
*/
if(!PINA0) {
panel++ ;
panel &= 1 ;
SPI_T6963C_displayGrPanel(panel) ;
Delay_ms(300) ;
}
/*
* If PORTA_1 is pressed, display only graphic panel
*/
else if(!PINA1) {
SPI_T6963C_graphics(1) ;
SPI_T6963C_text(0) ;
Delay_ms(300) ;
}
/*
* If PORTA_2 is pressed, display only text panel
*/
else if(!PINA2) {
SPI_T6963C_graphics(0) ;
SPI_T6963C_text(1) ;
Delay_ms(300) ;
}
/*
* If PORTA_3 is pressed, display text and graphic panels
*/
else if(!PINA3) {
SPI_T6963C_graphics(1) ;
SPI_T6963C_text(1) ;
Delay_ms(300) ;
}
/*
* If PORTA_4 is pressed, change cursor
*/
else if(!PINA4) {
curs++ ;
if(curs == 3) curs = 0 ;
switch(curs) {
case 0:
// no cursor
SPI_T6963C_cursor(0) ;
break ;
503
MIKROELEKTRONIKA - SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Libraries
mikroC PRO for AVR
CHAPTER 6