StephanA,
I observed the same behavior that you are seeing using a FMD1616. I found that the Clk:1.0s signal lags behind the RTC in the PLC and gets behind about 4 seconds an hour on my hardware.
The test code that uses only 2 custom functions, SetHourMeter and DisplayTime.
SetHourMeter, forces the hour meter counters to the time 00:00:00 and the RTC time to 00:00:00.
' SetHourMeter Initialze counters and RCT to 00:00:00
'
' This is done becuase the initial value of a counter is "-1" and
' by forcing the intial state to "0" I do not need to special case the "-1"
' value.
'
CtrPV[Seconds] = 0
CtrPV[Minutes] = 0
CtrPV[Hours] = 0
' Set RTC to 00:00:00
'
TIME[1] = 0
TIME[2] = 0
TIME[3] = 0
[/color]
The DisplayTime custom function displays the current Hour Meter time and the RTC time on the LCD display in the format:
HH:MM:SS Hour Meter
HH:MM:SS RTC
' Display hour display on LCD.
'
' First Line is the hour meter display using the Clk:1.0s
' Second Line of the display is the elapsed time using the RTC hardware
'
SetLCD 1,1, STR$(CtrPV[Hours],2)+":"+STR$(CtrPV[Minutes],2)+":"+STR$(CtrPV[Seconds],2)+" Hour Meter"
SetLCD 2,1, STR$(TIME[1],2)+":"+STR$(TIME[2],2)+":"+STR$(TIME[3],2)+" RTC"
[/color]
The ladder logic follows: