06 Matrix input
MTR/Matrix input
MTR
The instruction to read the input signal (switch) of 8 points multiply by n columns in the time division method of 8 input and (N) output (transistor).
-[MTR (S) (D1) (D2) (N)]
Content, range and data type
Parameter | Content | Range | Data type | Data type (label) |
(S) | The start device (X) number X000, X010, X020 of the row signal input of the matrix is up to the final input X number. 8 consecutively occupied. | The lowest bit number of X can only be 0 | Bit | ANY_BOOL |
(D1) | The starting device (Y) number of the column signal output of the matrix is Y000, Y010, Y020... to the final output Y number. 8 consecutively occupied. | The lowest bit number of Y can only be 0 | Bit | ANY_BOOL |
(D2) | The start device (Y, M, S) number of the ON output destination address is Y000, Y010, Y020..., M000, M010, M020..., S000, S010, S020... until the final Y, M, S number. Y occupies 8*(N) continuously, and the others occupy 10*(N) continuously. | - | Bit | ANY_BOOL |
(N) | Set the number of columns in the matrix input. | 2 to 8 | Unsigned BIN 16 bit | ANY16_U |
Device used
Instruction | Parameter | Devices | Offset modification | Pulse extension | ||||||
X | Y | M | S | SM | K | H | [D] | XXP | ||
MTR | Parameter 1 | ● | ||||||||
Parameter 2 | ● | |||||||||
Parameter 3 | ● | ● | ● | ● | ||||||
Parameter 4 | ● | ● |
Features
This instruction generally uses the normally ON contact SM100.
According to the example in the figure:
M10 will turn ON when Y30 and X30 are connected, M14 will be ON when Y30 and X34 are connected, M26 will be ON when Y31 and X36 are connected
(D2) is recommended to use a minimum of 0, mainly when using an address such as M4, the first start is M4, and then it will continue to occupy M11, which is inconvenient to calculate and view, so it is recommended to use a software with a minimum of 0 element.
Special device used
Devices | Content |
SM229 | SM229 will turn ON after one cycle of execution is completed |
Error code
Error code | Content |
4085H | The read address of (S) and (N) exceeds the device range |
(S) use the numbered device whose low bit is not 0 | |
4086HA | The write address of (D1) and (D2) exceeds the device range |
(D2) use the numbered device whose low bit is not 0 | |
4084H | (N) is not in the range of 2 to 8 |
4089H | Multiple MTR instructions are executed at the same time |