Hardware Reference
In-Depth Information
mdy[9]
5
0x30
1
(cur_time[6]
..
4);
/* year */
mdy[10]
5
0x30
1
(cur_time[6] & 0x0F);
mdy[11]
5
0;
/* NULL character */
}
else {
/* 24-hour mode */
hms[0]
5
0x30
1
((cur_time[2] & 0x30)
..
4); /* hours */
hms[1]
5
0x30
1
(cur_time[2] & 0x0F);
hms[2]
5
':';
hms[3]
5
0x30
1
(cur_time[1]
..
4);
/* minutes */
hms[4]
5
0x30
1
(cur_time[1] & 0x0F);
hms[5]
5
':';
hms[6]
5
0x30
1
((cur_time[0] & 0x70)
..
4); /* seconds */
hms[7]
5
0x30
1
(cur_time[0] & 0x0F);
hms[8]
5
':';
switch(temp3) {
/* convert to day of week */
case 1:
hms[9]
5
'S';
hms[10]
5
'U';
break;
case 2:
hms[9]
5
'M';
hms[10]
5
'O';
break;
case 3: hms[9]
5
'T';
hms[10]
5
'U';
break;
case 4: hms[9]
5
'W';
hms[10]
5
'E';
break;
case 5: hms[9]
5
'T';
hms[10]
5
'H';
break;
case 6: hms[9]
5
'F';
hms[10]
5
'R';
break;
case 7: hms[9]
5
'S';
hms[10]
5
'A' ;
break;
default: hms[9]
5
0x20;
/* space */
hms[10]
5
0x20;
break;
}
hms[11]
5
0; /* NULL character */
mdy[0]
5
0x30
1
(cur_time[5]
..
4);
/* month */
mdy[1]
5
0x30
1
(cur_time[5] & 0x0F);
mdy[2]
5
':';
mdy[3]
5
0x30
1
(cur_time[4]
..
4);
/* date */
mdy[4]
5
0x30
1
(cur_time[4] & 0x0F);
mdy[5]
5
':';
mdy[6]
5
0x30
1
(cur_time[6]
..
4);
/* year */
Search WWH ::
Custom Search