PackBitsToWord (FUN)¶
FUNCTION PackBitsToWord : WORD
Function packs 16 Bits “xBit0” .. “xBit15” into a WORD.
Example:
PackBitsToWord(FALSE,FALSE,FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,
FALSE,FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE) = 16#0102
- InOut:
Scope
Name
Type
Comment
Return
PackBitsToWordWORDfunction returns the WORD defined by the BOOL inputs
Input
xBit15BOOLBit 15 of the Word
xBit14BOOLBit 14 of the Word
xBit13BOOLBit 13 of the Word
xBit12BOOLBit 12 of the Word
xBit11BOOLBit 11 of the Word
xBit10BOOLBit 10 of the Word
xBit9BOOLBit 9 of the Word
xBit8BOOLBit 8 of the Word
xBit7BOOLBit 7 of the Word
xBit6BOOLBit 6 of the Word
xBit5BOOLBit 5 of the Word
xBit4BOOLBit 4 of the Word
xBit3BOOLBit 3 of the Word
xBit2BOOLBit 2 of the Word
xBit1BOOLBit 1 of the Word
xBit0BOOLBit 0 of the Word