Emerson PaCSystems VersaMax Series User Manual page 125

Table of Contents

Advertisement

User Manual
GFK-1503F
Parameters of the Masked Compare Function
Input/ Output
enable
I1
I2
M
BIT
MC
Q
BN
length
Operation of the Masked Compare
If all corresponding bits in strings I1 and I2 match, the function sets the "miscompare"
output MC to 0 and BN to the highest bit number in the input strings. The comparison then
stops. On the next invocation of a Masked Compare Word, it is reset to 0. When the two bits
currently being compared are not the same, the function checks the correspondingly
numbered bit in string M (the mask). If the mask bit is a 1, the comparison continues until it
reaches another miscompare or the end of the input strings.
If a miscompare is detected and the corresponding mask bit is a 0, the function does the
following:
1. Sets the corresponding mask bit in M to 1.
2. Sets the miscompare (MC) output to 1.
3. Updates the output bit string Q to match the new content of mask string M.
4. Sets the bit number output (BN) to the number of the miscompared bit.
5. Stops the comparison.
Instruction Set Reference
Choices
flow
R, AI, AQ
For WORD only: I, Q, M, T, S, G
R, AI, AQ
For WORD only: I, Q, M, T, S, G
R, AI, AQ
For WORD only: I, Q, M, T, SS, SB,
SC, G
I, Q, M, T, S, G, R, AI, AQ, constant Reference for the bit number where the
flow, none
R, AI, AQ
For WORD only: I, Q, M, T, SA, SB,
SC, G
I, Q, M, T, S, G, R, AI, AQ
Constant
Description
Permissive logic to enable the function.
Reference for the first bit string to be
compared.
Reference for the second bit string to be
compared.
Reference for the bit string mask.
next comparison should start.
User logic to determine if a miscompare
has occurred.
Output copy of the mask (M) bit string.
Bit number where the last miscompare
occurred.
The number of words in the bit string. Max.
is 4095 for WORD and 2047 for DWORD.
Chapter 10
Jan 2020
111

Advertisement

Table of Contents
loading

Table of Contents