WORDS_TO_DWORD
The WORDS_TO_DWORD block concatenates two WORD values into one DWORD value.
Ladder Representation
Block Structure
| Variable Type | Name | Data Type | Description |
|---|---|---|---|
| VAR_INPUT | EN | BOOL | Block enable. |
| VAR_INPUT | Value1 | WORD / UINT / INT | First WORD, least significant. |
| VAR_INPUT | Value2 | WORD / UINT / INT | Second WORD, most significant. |
| VAR_OUTPUT | ENO | BOOL | End of operation. |
| VAR_OUTPUT | Result | DWORD / UDINT / DINT | DWORD 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

Examples
- Ladder
- Structured Text
The Ladder examples concatenate two WORD inputs into one DWORD output. The block finishes successfully and activates ENO.
The following Structured Text code applies the same logic shown in the Ladder example.
Structured Text
VAR
VAL1 : INT := 4;
VAL2 : INT := 1;
RESULT : DINT;
END_VAR
RESULT := FB_WORDS_TO_DWORD(
EN := DI1,
Value1 := VAL1,
Value2 := VAL2,
ENO => DO1
);