This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
resources:tools-software:sigmastudio:toolbox:counters:pulsecounter [21 Jun 2012 21:11] – created Brett Gildersleeve | resources:tools-software:sigmastudio:toolbox:counters:pulsecounter [22 Jun 2012 19:33] (current) – fixed link William Jahn | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | <WRAP center round todo 60%> | + | ======Pulse Counter====== |
- | Under Construction | + | |
- | </WRAP> | + | [[resources: |
+ | \\ | ||
+ | ------------------------------------------------------------------------------------------------------ | ||
+ | |||
+ | |||
+ | |The Pulse Counter block, counts the number of non-zero inputs it receives. There is a start/stop pin to initiate and pause the count, and also a reset pin to set the count back to zero. Any non-zero input on the pulse input pin, is considered a pulse and will be counted when the count is enabled.|{{pulsecounterpic1.png}}| | ||
+ | |||
+ | ===Input Pins=== | ||
+ | ^Name^Format [int/dec] - [control/ | ||
+ | |Pin 0: Start/ | ||
+ | |Pin 1: Reset|int - control|When this pin is high, it clears the count value back to zero.| | ||
+ | |Pin 2: Pulse Input|int - control|Input signal to monitor and count pulses| | ||
+ | |||
+ | ===Output Pins=== | ||
+ | ^Name^Format [int/dec] - [control/ | ||
+ | |Pin 0: Count Output|int - control|Count Value indicating number of pulses| | ||
+ | |||
+ | ===Algorithm Description=== | ||
+ | The purpose of the Pulse counter, is to count the number of pulses during a specified amount of time. The time is dictated by the signal on the start/stop pin. When the start/stop pin is high, the algorithm is counting pulses, otherwise the last count value is output. The reset pin clears the count value and counting can resume from 0 whenever the start pin is high. | ||
+ | |||
+ | The graph below shows the interaction between the start/stop and reset pins when a pulse train signal is present on the Pulse Input pin. The reset signal is in red. The start/stop signal is in blue, and the counter output is the second graph in yellow.\\ | ||
+ | \\ | ||
+ | {{pulsecounterpic2.png}}\\ | ||
+ | \\ | ||
+ | |||
+ | ===Example=== | ||
+ | The Pulse Counter is very useful to use with the Value Cross Detection algorithm. For an application in which you need to monitor the number of value-crossings (zero-cross counter) during a specified time the two blocks together can help achieve this. The following image uses a [[resources: | ||
+ | \\ | ||
+ | {{pulsecounterpic3.png}}\\ | ||
+ | \\ | ||
+ | |||
+ | ===Algorithm Details=== | ||
+ | |Toolbox Path|Counters - Counters - Pulse Counter| | ||
+ | |Cores Supported|AD1940 \\ ADAU170x \\ ADAU144x \\ ADAU176x \\ ADAU178x| | ||
+ | |"Grow Algorithm" | ||
+ | |"Add Algorithm" | ||
+ | |Subroutine/ | ||
+ | |Program RAM|12| | ||
+ | |Data RAM|3| | ||
+ | |Parameter RAM|0| | ||
+ | |||