ContentsIndex
Math Macros
Math
Macros
Macro 
Description 
bit 
Computes the value of the specified bit (bit 0 is 1, bit 1 is 2, bit 2 is 4, etc.). 
Clears (writes a 0 to) a bit of a numeric variable. 
Reads a bit of a number. 
Sets (writes a 1 to) a bit of a numeric variable. 
Writes a bit of a numeric variable. 
Extracts the high-order (leftmost) byte of a word (or the second lowest byte of a larger data type). 
Extracts the high-order (leftmost) byte of a word (or the second lowest byte of a larger data type). 
abs 
Computes the absolute value of a number. 
Constrains a number to be within a range. 
max 
Calculates the maximum of two numbers. 
min 
Calculates the minimum of two numbers.