if(PORTCbits.RC2==1)
{
PORTD=0xFF;
lcd_init(); // Initialise LCD module
LCD_RS = 1; // Select LCD for character data mode
Delay1KTCYx(1); // 1 ms delay
lcd_write_cmd(0x80);
lcd_write_data('E');
lcd_write_data('N'); // write "A" to LCD
lcd_write_data('T'); // write "B" to LCD
lcd_write_data('R'); // write "C" to LCD
lcd_write_data('Y');
lcd_write_cmd(0xC0); // Move cursor to line 2 position 1
lcd_write_data('D'); // write "1" to LCD
lcd_write_data('E'); // write "2" to LCD
lcd_write_data('N'); // write "3" to LCD
lcd_write_data('I');
lcd_write_data('E');
lcd_write_data('D');
PORTCbits.RC1=1;
int p;
for(p=0;p<2;p++)
{
onetone();
Delay1KTCYx(250);
}
[color=red]
Add code here to check for button beeing released before continuing [/color]
}