Chapter 6 Applied Instructions 
6-537 
Example: 
SM450 is ON when the memory card is inserted into the CPU module; SM452 is ON when MTWRIT 
is executed; SM452 is OFF when the execution of MTWRIT is complete. 
 
D0  16#0001 
The file into which the data is written 
The unit of the character is the byte.   
The file name extension is .txt. 
The ASCII codes are adopted. 
The data in D300 is written into the file. 
The data which is written into the file 
D10  16#000A 
The size of the string  which is written into the file is 32 
bytes. 
D1  16#0A00 
After the data is written into the file, the separation mark is 
added after the last byte in the file. 
D30 
D31=16#7473 
D32=16#0031 
The file name is “Test1”. 
Additional remark: 
1.  If the value in C exceeds the range, the operation error occurs, the instruction is not executed, 
SM0 is ON, and the error code in SR0 is 16#2003. 
2.  If the value in S
1
 exceeds the range, the operation error occurs, the instruction is not executed, 
SM0 is ON, and the error code in SR0 is 16#2003. 
3.  If the value in S
3
 exceeds the range, the operation error occurs, the instruction is not executed, 
SM0 is ON, and the error code in SR0 is 16#2003.