> How to keep date Well, unless the device has to display time somehow in ASCII or digits, I strongly prefer the Unix date format (unsigned 32 bits, seconds since etc etc). When there is a timezone problem (there is, here), I add a signed integer in 32 bits that expresses the offset to GMT and a ISO 3-char string that expresses the ISO name of the offset to GMT/UTC. I confess that I have only gotten to do this twice so far, but it is a Good Thing imho. It only takes 11 bytes to implement and doing date maths with this is bliss compared to YYMMDD - YYMMDD etc. The date can be transmitted in mangled format over serial, using hex ASCII if there is an 8-bit-uncleanliness problem (we are 8-bit clean because our national character set maps up into >0x80 bytes normally). Hosts have no problem formatting or parsing the date, especially since the time functions are well represented in any C standard library. Note that I use an UNSIGNED second counter, which is good till 2106 or so. The C library functions usually aren't. I also use only the low bits of the offset required to express a +/-12 Hour offset in seconds. This is 17 bits + sign = 18 bits out of 32. This leaves some unused bits and bytes (can be flags etc). The 32-bit alignment is kept for easy addition purposes. A mask removes the flags when doing this. One can implement the binary->ASCII parser even on a PIC if need be, but for simple things like clocks YYMMDDSS is more like it, in packed or unpacked BCD, ready to add ASCII offsets for display (LCD) or not (LEDs etc). hope this helps, Peter