AH500 Programming Manual Symbol: S : Data source Word Explanation: 1. S : The device into which the setting value is written 2. The operand S occupies seven consecutive devices. 3. When users want to adjust the built-in real-time clock in the CPU module, they can use the instruction to write the correct current time into the built-in real-time clock. 4. When the instruction is executed, the new setting time is instantly written into the real-time clock in the PLC. Therefore, when the instruction is executed, users have to make sure that the new setting time is consistent with the time when the new setting time is written into the real-time clock. Example:
When M0 is ON, the correct current time is written into the built-in real-time clock in the PLC. New setting time Real time clock Additional remark: 1. If the value in S exceeds the range, the operation error occurs, the instruction is not executed, SM is ON, and the error code in SR is 16#2003. 2. If S +6 exceeds the device range, the operation error occurs, the instruction is not executed, SM is ON, and the error code in SR is 16#2003. 3. If users declare the operand S in ISPSoft, the data type will be ARRAY [7] of WORD/INT.
6-366 API Instruction code Operand Function 1601 TWR P S Writing the time Device X Y M S T C HC D L SM SR E PR K 16# “$” DF S Pulse instruction 16-bit instruction (3 steps) 32-bit instruction AH500 AH500 - General data Special data Item Value Item register register D20 Year (A.D.) 00~99 SR391 Year (A.D.) D21 Month 1~12 SR392 Month D22 Day 1~31 SR393 Day D23 Hour 0~23 SR394 Hour D24 Minute 0~59 SR395 Minute D25 Second 0~59 SR396 Second D26 Week 1~7 SR397 Week