Mitsubishi — Chapter 8 Application Instructions API 100-149

9 Application Instructions API 150-199 Remarks: 1. Explanations on the matrix instruction: a) A matix consists of more than 1 consecutive 16-bit registers. The number of registers in the matrix is the length of the array (n). A matrix contains 16 Ч n bits (points) and there is only 1 bit (point) offered for an b) The matrix instruction gathers a series of 16 Ч n bits (b 0 ~ b 16n-1 ) and designates a single point for operation. operand at a time. The point will not be seen as a value. c) The matrix instruction processes the moving, copying, comparing and searching of one-to-many or many-to-many matrix status, which is a very handy and important application instruction.

d) The matrix operation will need a 16-bit register to designate a point among the 16n points in the matrix for the operation. The register is the Pointer (Pr) of the matrix, designated by the user in the instruction. The vaild range of Pr is 0 ~ 16n -1, corresponding to b0 ~ b16n-1 in the matrix. e) There are left displacement, right displacement and rotation in a matrix operation. The bit number decreases from left to right (see the figure below). Left Right Width: 16 bits D0 b15 b0 D1 D2 b31 b47 b16 Length: n b32 Dn-1 b16n-1 f) The matrix width (C) is fixed at 16 bits. g) Pr: matrix pointer. E.g. if Pr is 15, the designated point will be b15. h) Array length (R) is n: n = 1 ~ 256.

Example: The matrix is composed of D0, n = 3; D0 = HAAAA, D1 = H5555, D2 = HAAFF C 15 C 14 C 13 C 12 C 11 C 10 C 9 C 8 C 7 C 6 C 5 C 4 C 3 C 2 C 1 C 0 R 0 D0 R 1 D1 R 2 D2 Example: The matrix is composed of K2X0, n = 3; K2X0 = H37, K2X10 = H68, K2X20 = H45 C 15 C 14 C 13 C 12 C 11 C 10 C 9 C 8 C 7 C 6 C 5 C 4 C 3 C 2 C 1 C 0 R 0 X 0 ~X 7 R 1 X 10 ~X 17 R 2 X 20 ~X 27 Fill “0” into the blank in R0(C 15 -C 8 ), R1(C 15 -C 8 ), and R2(C 15 -C 8 ).

DVP-PLC Application Manual 9-96 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 1 1 0 1 1 1 0 0 0 0 0 0 0 0 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 1 0 1