13 . Real Time Calendar Time Design Examples M11 When any of M11, M14, M17 and M20 is triggered, Y0 will be ON and the bell will ring.. M14 M17 M20 Y0 T0 The ring will last for 1 minute. Y0 will be reset and the bell will stop ringing. Program Description: z The value in D200~D206 and D300~D311 can be set by WPLSoft or HMI. z To avoid the execution error of TWR instruction, the program uses [FMOV K1 D200 K4] instruction at the beginning. This program operates only the data of Hour/Minute/Second in D204~D206 but not the data of Year/Day/Month/Date in D200~D203. For TWR instruction, the setting range: 00~99 for Year, 1~7 for Day(Mon ~Sun), 1~12 for Month and 1~31 for Date.
If the values in D200~D203 are out of the above range, the program will regard it as an operation error and the instruction will not be executed and the Hour/Minute/Second data can’t be written either. Therefore, the program sets the Year/Week/Month/Day to K1 to fit the above range and makes sure TWR instruction can be executed for writing in Hour/Minute/Second data. z D4, D5 and D6 store the Hour/Minute/Second of the current time read form RTC. DVP-PLC Application Examples 13-2 SET Y0 TMR T0 K600 RST Y0