David Meiklejohn wrote: > Ok, so the problem with that is that I'm not checking for AM/PM. I didn't look at your code, but my immediate knee jerk reaction is that keeping AM/PM flags around is a bad design choice. Use 24 hour time internally. Whether you then display 24 hour or 12 hour time with AM/PM is only a matter of the display logic. > So finally to the point. Does anyone know an elegant way to compare > (XOR) two bits in the same register, using midrange PIC instructions? Why does it need to be elegant? The extra cycles are irrelevant. Write it to make the most sense when someone reads the code. This includes giving symbolic names to the bits. ******************************************************************** Embed Inc, Littleton Massachusetts, http://www.embedinc.com/products (978) 742-9014. Gold level PIC consultants since 2000. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist