I need to display the date and time from a string of data I have of hex numbers(hh:mm:ss mm/dd/yy). I received each section of the data in an integer array. The problem is that when any of the data is less than 10, it only displays it as 5 for example. Where as I need it to display 05, I assume this is possible but not sure how.
// Update Read Time
sprintf(ctemp,"%d:%d:%d %d/%d/%d",RxPacket[6],RxPacket[7],RxPacket[8],RxPacket[4],RxPacket[3],RxPacket[5]);
Thanks.