Documentation Home Page RT-LAB Home Page
Pour la documentation en FRANÇAIS, utilisez l'outil de traduction de votre navigateur Chrome, Edge ou Safari. Voir un exemple.

OpMuxDemux

Library

rtlab/Miscellaneous

Block

This block handles the multiplexing or demultiplexing of data elements according to parameters defined by the user through the block’s interface.

Figure 1: OpMuxDemux block

Mask

Figure 2: OpMuxDemux mask.

Description

The OpMuxDemux block can act either as a multiplexer or a demultiplexer depending on user’s choice. If demux is specified, this block will split the raw Data vector in Element pieces according to the definition of that Element provided by the user through the block’s interface. When acting as a multiplexer, the OpMuxDemux block will concatenate the element data pieces into one raw data vector according to the definition of that Element.

A start bit number and a data word number define an element start position in the stream of data.

For example if the element start bit is equal 2 and element start word is equal 0, the element starts at the third bit of the first word of the data stream as shown in figure 3. The raw length defines the length in bits of the element. An element can span over several words. The total number of bits of a data stream is defined by the position of the last element and its length.

Figure 3: Example of an element in the data raw

Parameters

Number of elementsthe number of elements.
Word sizethe size of one word of data.
Vector of elements start bitsone vector of elements start bits.
Vector of elements start wordone vector of elements start word.
Vector of elements lengthsone vector of elements lengths.

Inputs

This block has one input when acting as a demux, and several inputs when acting as a mux.

Outputs

This block has several outputs when acting as a demux and only one output when acting as a mux.

Characteristics and Limitations

This block has no special characteristics.

OPAL-RT TECHNOLOGIES, Inc. | 1751, rue Richardson, bureau 1060 | Montréal, Québec Canada H3K 1G6 | opal-rt.com | +1 514-935-2323