AH500 Programming Manual API 2117 Symbol: S 1 : String Word S 2 : Number of characters which are deleted Word The characters in S 1 starting from the character indicated by the value in S 3 are deleted. S 3 : Word D : Device in which the execution result is stored Word Explanation: 1. The characters in S 1 starting from the character indicated by the value in S 3 are deleted, the number of characters which are deleted is indicated by the value in S 2 , and the result is stored in D . 2. The four characters starting from the third character in the string “12 3456 7890” in S 1 are deleted, and the result “127890” is stored in D .
b15 b0 b7 b8 b15 b0 b7 b8 S1 D +1 S1 +2 S1 +1 D +2 D +3 S1 After the instruction is executed +2 D +4 S1 +5 S1 4 S2 3 3. If the value in S 2 is larger than the number of characters which can be deleted in the string in S 1 , the characters in S 1 starting from the character indicated by the value in S 3 to the last character in S 1 are deleted, and 16#00 is stored in D .
S3 6-490 Operand Function $DEL P S , S , S , D 1 2 3 Deleting the characters in the string Device X Y M S T C HC D L SM SR E PR K 16# “$” DF S 1 S 2 S 3 D Pulse instruction 16-bit instruction (9 steps) 32-bit instruction AH500 AH500 - 16#32(2) 16#31(1) 16#34(4) 16#33(3) 16#36(6) 16#35(5) 16#38(8) 16#37(7) 16#30(0) 16#39(9) Ignored 16#00 16#32(2) 16#31(1) 16#38(8) 16#37(7) 16#30(0) 16#39(9) 16#0000