12.07.2015 Views

Logix5000 Controllers General Instructions - SLAC Confluence

Logix5000 Controllers General Instructions - SLAC Confluence

Logix5000 Controllers General Instructions - SLAC Confluence

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Move/Logical <strong>Instructions</strong> (MOV, MVM, BTD, MVMT, BTDT, CLR, SWPB, AND, OR, XOR, NOT, BAND, BOR, BXOR, BNOT) 293Bit Field Distribute (BTD)The BTD instruction copies the specified bits from the Source, shiftsthe bits to the appropriate position, and writes the bits into theDestination.This instruction is available in structured text and function block asBTDT, see page 296.Operands:Relay LadderOperand Type Format DescriptionSource SINT immediate tag that contains the bits to moveINTtagDINTA SINT or INT tag converts to a DINT value by zero-fill.Source bit DINT immediateDestinationSINTINT(0-31 DINT)(0-15 INT)(0-7 SINT)tagnumber of the bit (lowest bit number) fromwhere to start the movemust be within the valid range for the Sourcedata typetag where to move the bitsDestinationbitDINTDINTimmediate(0-31 DINT)(0-15 INT)(0-7 SINT)Length DINT immediate(1-32)the number of the bit (lowest bit number)where to start copying bits from the Sourcemust be within the valid range for theDestination data typenumber of bits to moveDescription:When enabled, the BTD instruction copies a group of bits from theSource to the Destination. The group of bits is identified by the Sourcebit (lowest bit number of the group) and the Length (number of bits tocopy). The Destination bit identifies the lowest bit number bit to startwith in the Destination. The Source remains unchanged.If the length of the bit field extends beyond the Destination, theinstruction does not save the extra bits. Any extra bits do not wrap tothe next word.If you mix integer data types, the instruction fills the upper bits of thesmaller integer data types with 0s so that they are the same size as thelargest data type.Publication 1756-RM003I-EN-P - January 2007

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!