Wiki

This version (14 Sep 2022 13:52) was approved by Angu Sewa.The Previously approved version (18 Jan 2021 06:39) is available.Diff

Click here to return to the Basic page

Counter



Description

The Counter block can be used with a State Machine to process your input at a particular time interval, in ms. The counter starts from 0 by default or any other user-defined value if specified.
The Counter with Interval module has 2 input pins. First input is for Start/Hold the Counter and second input is used to Reset the counter value.

Varaints

  1. Counter
  2. Counter with Interval

Targets Supported

Name ADSP-214xx ADSP-215xx/SC5xx ADAU145x/146x
———————————————————— ——————-- ——————————-- —————————-
Counter B/S B/S S
Counter with Interval NA NA S


Pins

Input

NameTypeDescription
———————————————————-——————————————————————————————
Start / Hold (only for Counter with Interval) Control Counter start or hold input
Reset (only for Counter with Interval) Control Counter Reset input

Output

NameTypeDescription
——————————————————————————————————————————————
Output Control (Only for Counter with Interval) / Audio Output channel

Configurable Parameters

GUI Parameter NameDefault ValueRangeFunction Description
————————————————————————————-———————————————————-
Max1342177270 to 134217727This is the maximum value for the counter. If the counter reaches the maximum value, its output will stay at that value until it is reset. The value can be changed by clicking in the text field and typing a new value, or by clicking the adjacent up/down arrows.
step11 to 10000 This controls the rate at which the counter increments. The counter value will increase by the value in this field at the end of every audio sample. The value can be changed by entering the desired value in the text field or using the adjacent up/down arrows.
Init0 0 to 268435456This is the initial value of the counter, which is the starting value for the counter when it is reset. Enter the start count value in the Init field, or use the adjacent up/down arrows.
Reset False True / False Resets the counter value to initial value
Pause False True / False Starts or stops the counter increment. If the counter is stopped in mid-operation, its output value will freeze at its most recent value.

DSP Parameters

Parameter Name Description ADSP-214xx/SC5xx/215xx ADAU145x/146x
—————————————- ——————————————————————————-- —————————————- —————————-
Max This is the maximum value for the counter FloatFixPoint8d24
step The counter value will increase by the value at the end of every audio sample Float FixPoint8d24
Init This is the starting value for the counter when it is reset Float FixPoint8d24
Pause Starts or stops the counter increment FloatFixPoint8d24
Reset Resets the counter value to initial value FloatFixPoint8d24
resources/tools-software/sigmastudiov2/modules/basic/counter.txt · Last modified: 10 May 2021 08:49 by Nikhin Shetty