Digital demultiplexer

BD11_DIGITAL_DEMULTIPLEXER

PROGRAM BD11_TEST
VAR 
    INPUT:REAL;
   SELECTOR:LINT;  
    IN1: BOOL;
  OUT1: LIB.CORE.V1_0.MULTIIOBOOL;
    FB: LIB.CORE.V1_0.BD11_DIGITAL_DEMULTIPLEXER;
END_VAR
    FB(IN:=IN1, SEL:=SELECTOR);
 OUT1:=FB.OUT;
END_PROGRAM

LIB\CORE

V1.0

The block is a logical values demultiplexer. If SEL=1 then the first element of the output array OUT is a copy of the input IN. If SEL=2 then the second element of the output array is a copy of IN, etc. All other outputs are set to DEFAULT.

Input TypeDescription Default value
IN BOOLInput value False
SEL LINTOutput selector 0
DEFAULTBOOLDefault value of all outputsFalse
OutputType Description
OUT MULTIIOBOOLOutput signal


In the example above, output 3 is selected, displaying the value of True (1) which is brought on the input. All other outputs are False (0) which is the DEFAULT value.

  • © Energocentrum Plus, s.r.o. 2017 - 2024