Below are the codes I using to display dates and times and basically I used the function "write(hr1,hr0,min1,min0,sec1,sec0);" to display the time and "day_compute(day);" to display what the day for the input date. For simplicity, I just show the input send to LCD between these 2 functions. I want the time to display on the 1st line of the screen and day to display on the 2nd line of the screen, what command line should I add in between this 2 so it will separate the day to the 2nd line?Refered to the datasheet but still not able to understand how to do that.
void LCD_set();
void main()
{
TRISA=0x00;
TRISD=0x00
while(1)
{
initialize();
write(hr1,hr0,min1,min0,sec1,sec0);
day_compute(day);
}
void initialize()
{
PORTD=0x00;
LCD_set();
PORTD=0x0C;
LCD_set();
PORTD=0x06;
LCD_set();
PORTD=0x80;
LCD_set();
}