Skip to content

AdderInt32

Overview

Adds integer signals

Discussion

The adder int32 module has a variable number of input pins and a single output pin. In all cases, all inputs must have the same block size and this equals the block size of the output pin.

The module operates in two fundamentally different modes depending upon the value of the variable oneChannelOutput. If oneChannelOutput==0, then all of the input pins must have the same number of channels. The output pin will then have the same number of channels as the input pins and be formed as the sum of all inputs. If oneChannelOutput==1, then the input pins can each have a different number of channels. The output is then a one channel signal that is formed as the sum over all input channels.

Module Pack

Standard

ClassID

classID = 45

Type Definition

typedef struct _ModuleAdderInt32
{
ModuleInstanceDescriptor instance;            // Common Audio Weaver module instance structure
INT32 oneChannelOutput;                       // Boolean value that determines whether all channels are summed to form a single output.
} ModuleAdderInt32Class;

Variables

Properties

Name Type Usage isHidden Default Value Range Units
oneChannelOutput int const 0 0 0:1:1

Pins

Input Pins

Name in1
Description Audio input
Data type int
Channel range Unrestricted
Block size range Unrestricted
Sample rate range Unrestricted
Complex support Real
Name in2
Description Audio input
Data type int
Channel range Unrestricted
Block size range Unrestricted
Sample rate range Unrestricted
Complex support Real

Output Pins

Name out
Description Audio output
Data Type int

Matlab Usage

File Name: adder_int_module.m 
 M=adder_int_module(NAME, NUMIN, ONECHANNELOUTPUT) 
 Creates a multi-input adder module for use with the Audio Weaver. 
 Arguments: 
    NAME - name of the module. 
    NUMIN - number of input pins 
    ONECHANNELOUTPUT - boolean value which determines if multi-channel 
         input signals are collapsed to a single output channel. 

Copyright (c) 2026 DSP Concepts, Inc.