I have had this phenomena happen on two T100MD-888+ with two different MX-RTC's.
The PLC is used in an application using an optical encoder to drive HSC1 and HSC2 . I am measuring position as well as velocity.In order to test my completed system, I feed a quadrature signal into the unit, and have the following code at 1st.Scan
SETSYSTEM 4,2 'set HSC2 encoder decoding to best for jitter
HSCDEF 2,2,2000000' set count to run Cust Fcn#2 at 27343 feet
' this is 128 ppr = to 1.75 ft
' set counter HSC[2] as a bi-directional quadrature encoder counter
HSCDEF 1,2,2147483647' set upper number to (2^31)-1 bits
'set counter HSC[1] as a pulse counter, no matter what direction
setlcd 0,1, chr$(12) ' hide cursor
J=0 'Used in Rod Rate Measurement using Rung Timing
SETBAUD 1, 4 ' SET COMM1 TO 19200, 8 , N, 1
Custom Function #2 is
' ZERO ENCODER COUNTER SAVE DATA IN BATTERY BACKED MEMORY
IF HSCPV[2]=0 THEN GOTO @40 'Set Value of Encoder Counter to 0
ENDIF
IF V=0 THEN V=1
ENDIF
IF V>=3960 THEN V=1 ' LIMIT OF DATA FILE IN GROUPS OF 4, 4*990=3960
ENDIF
'AT 990 JOBS WILL START RECORDING OF DATA STARTING OVER AT DM[1]
DM[V]=DATE[2] ' MONTH
DM[V+1]=DATE[3] ' DAY
DM[V+2]=DATE[1] ' YEAR
DM[V+3]=HSCPV[1]*10/2399 ' SCALE IN WHOLE METERS
X=DM[3999] 'LOAD OLD TOTAL LOWER 16 BITS
SETHIGH16 X,DM[3998] 'LOAD OLD TOTAL UPPER 16 BITS
X=X+DM[V+3] 'ADD CURRENT CHAIN TRAVEL IN METERS
DM[3998]=GETHIGH16(X) 'WRITE UPPER 16 BITS OF TOTAL METERS TRAVELED
DM[3999]=X ' WRITE LOWER 16 BITS OF TOTAL METERS TRAVELED
DM[3995]=DATE[2] 'CURRENT MONTH FOR LAST TOTAL WRITTEN
DM[3996]=DATE[3] 'CURRENT DATE FOR LAST TOTAL WRITTEN
DM[3997]=DATE[1] 'CURRENT YEAR FOR LAST TOTAL WRITTEN
V=V+4
@40
HSCPV[2]=0 'Set Value of Encoder Counter to 0
HSCPV[1]=0 'Set Value of Encoder Counter to 0
If I leave the unit running continuously 24/7, typically I will see 10 resets per day, but when I return in the morning, the date has reverted to 1/1/1998. I have also had this happen when using On-line monitoring, where one instance it is displaying the correct date, then reverts to 1/1/1998.
Recently, I have run the system for 10 to 15 minutes each day, then removed power. The time and date settings are correct upon repowering the system. So the RTC is functioning properly when not powered.
Is there anything in my code that would lead to this date change?
Could it be a socket/MX-RTC pin problem? If the PLC interrogates the MX-RTC every hour, is the communication specific to a particular pin or pins?
Do you have a recommended way of holding the MX-RTC in the socket, so that it won't come out? It slips in and out of the socket easily.
Your assistance is appreciated.