Function Blocks
DDEC Digital Decoder Function Block
Revision 11 HC900 Hybrid Control Designer Function Block Reference Guide 129
2/07
DDEC Digital Decoder Function Block
Description
The DDEC label stands for Digital Decoder.
This block is part of the
Auxiliary category.
Function
The Digital Decoder function converts an analog value from the Value Input to the binary equivalent value
on the 16 digital outputs 1 through 16. The Value Input accepts whole numbers between 0 and 65535.
Fractional values are ignored. The output value OCNT (bottom of block) indicates the total number of
digital outputs that are ON as an analog value.
For example, a value of 285 would be represented by binary 0000000100011101, where OUT 1 is LSB and
OUT 16 is MSB. OCNT = 5 (OUT 1, 3, 4, 5, 9 are ON).
All 16 outputs and the OCNT signal pin are monitored.
Forcing of the outputs is not permitted.
Inputs
VALUE
= Whole number analog input value between 0 and 65535.
Outputs
Sixteen digital outputs, OUT 1 through OUT 16, with OUT 1 = LSB and OUT 16 = MSB.
OCNT = Analog value representing the number of digital outputs (OUT 1 through OUT 16) that are set to
ON.