I think your becoming a good case for the snippets are us award
but if you intention is to just to set/reset 24 h mode on the chip

Code:
 If(PortC.5 = 1) & (PortC.6 = 1) then Pause 1500
  If (PortC.5 = 1) & (PortC.6 = 1) then
   'IF hourly mode = AM
   I2CRead SDApin,SCLpin,$D0,$02,[RTCHour]  
   RTCHour.6 = ! RTCHour.6
   I2cwrite SDApin,SCLpin,$D0,$02,[RTCHour]     
  endif
 endif