Skip to main content

WORDS_TO_DWORD

The WORDS_TO_DWORD block concatenates two WORD values into one DWORD value.

Ladder Representation

WORDS_TO_DWORD Ladder representation

Block Structure

Variable TypeNameData TypeDescription
VAR_INPUTENBOOLBlock enable.
VAR_INPUTValue1WORD / UINT / INTFirst WORD, least significant.
VAR_INPUTValue2WORD / UINT / INTSecond WORD, most significant.
VAR_OUTPUTENOBOOLEnd of operation.
VAR_OUTPUTResultDWORD / UDINT / DINTDWORD value.

Operation

When EN is TRUE, the block concatenates Value1 and Value2 to build a 32-bit DWORD value. Value1 is the least significant WORD and Value2 is the most significant WORD.

When EN is FALSE, Result remains unchanged.

The ENO output passes the EN state to the next Ladder block after the operation is finished.

Execution Flowchart

WORDS_TO_DWORD execution flowchart

Examples

The Ladder examples concatenate two WORD inputs into one DWORD output. The block finishes successfully and activates ENO.

WORDS_TO_DWORD Ladder example

WORDS_TO_DWORD Ladder example result