Galil COMMAND REFRENNCE DMC-1400 Manual De Usuario

Descargar
Página de 235
6 ● & |   
 
 
 
 
 
   DMC-1400 Series Command Reference 
& | 
 
FUNCTION:  Bitwise Logical Operators AND and OR 
DESCRIPTION:   
The operators & and | are typically used with IF, JP, and JS to perform conditional jumps; 
however, they can also be used to perform bitwise logical operations. 
ARGUMENTS: n & m or n | m where 
n and m are signed numbers in the range -2147483648 to 2147483647. 
For IF, JP, and JS, n and m are typically the results of logical expressions such as (x > 2) 
 
 
USAGE:    DEFAULTS: 
While Moving 
Yes 
Default Value 
In a Program 
Yes 
Default Format 
Command Line 
Yes 
 
 
Controller Usage 
ALL 
RELATED COMMANDS: 
Bitwise complement 
If statement 
Jump statement 
Jump subroutine 
EXAMPLES: 
IF (x > 2) & (y = 4) 
  MG “true” 
ENDIF 
;x must be greater than 2 and y equal to 4 for the message to print 
 
 
:MG 1 | 2   
 3.0000 
;'Bitwise operation:  01 OR 10 is 11 = 3