Syntax: BIC {<cond>}{S} <destination>, <operand1>, <operand2>
Operation: destination = operand one AND (NOT (operand two))
Flags: N,Z,(C)
This instruction provides a useful way of clearing certain bits within a data word, while leaving others unchanged. Operand one is the data field to be modified, with the result being placed in the destination register.
Operand two is a 32-bit word called the data mask. A set bit in the bit mask will force the corresponding bit in the data word to be reset when the instruction is executed. A zero bit in the mask will leave the corresponding bit in the data word in its original state.
Examples:
BIC R0,R0,#%1111 ; Clear low 4 bits of R0
BIC R1,R1,R2 ; Clear bits in R1 which were set in R2
BIC R6,R6,R6 ; Clear bits which were set in R6 (R6 = 0)
|
|
|