How to use the FROM instruction
The FROM instruction is used to transfer data from the buffer of a special function module to
the PLC CPU. Note that this is a copy operation – the contents of the data in the module buffer
are not changed.
쐃
Head address of the special function module on base unit. The address can be entered as
decimal or hexadecimal constant (16#).
쐇
Starting address in buffer.You can use a constant or a data register containing the value.
쐋
Number of data units to be transferred
쐏
Data destination in the PLC CPU
The example above uses FROM to transfer data from a special function module with the head
address X/Y040. The instruction reads the contents of buffer address 9 and writes it to data
register D0.
How to use the TO instruction
The TO instruction transfers data from the PLC CPU to the buffer of a special function module.
Note that this is a copy operation, it does not change the data in the source location.
쐃
Data source in the PLC CPU
쐇
Head address of the special function module on base unit. The address can be entered as
decimal or hexadecimal constant.
쐋
Starting address in buffer
쐏
Number of data units to be transferred
In the example above the contents of data register D3 is copied to the buffer address 32 of the
special function module with the head address 1 (X/Y010).
6–20 MITSUBISHI ELECTRIC
Instructions for Moving Data More Advanced Programming
Ladder Diagram
MELSEC Instruction List
FROM H4
K9
D0
K1
IEC Instruction List
FROM_M 16#4, 9 , 1 , D0
Ladder Diagram
MELSEC Instruction List
TO H1
K32
D3
K1
IEC Instruction List
FROM_M D3, 16#1, 32, 1