Specifications
Chapter 2 - AsconBasicIOLib
69
Input Special
Function
Frequency Measurement
For the channels 1 and channel 2 it is possible to activate the function of
frequency measurement. The module is able to provide the frequency of the
digital input signals connected to the device. The outputs Frequency1 and
Frequency2 contain the measured values while the user must specify the range of
the input signal using the Frequency_Range parameter: 0 for the range 0.015Hz...
2KHz and 1 for the range 1Hz... 20KHz. Please note that the frequency range it is
common for both the input channels.
To activate this function the user must:
- set for the channel used as input with ChMode
- set the proper value to the Input_Option parameter (see the table below)
- set the desired Frequency_Range value
Counter Input
For the channel 1 and channel 2 it is possible to activate the function of counter
input. The module is able to count the rising edge of the digital input signal
connected to the device. The outputs Counter1 and Counter2 contain the number
of the edge detected.
To activate this function the user must:
- set for the channel used as input with ChMode
- set the proper value to the Input_Option parameter (see the table below)
- give the start command to the STARTCOUNTERx parameters
The value of the counter can be reset to 0 using the RESETCOUNTERx command.
Period Measurement
For the channels 1 and channel 2 it is possible to activate the function of period
measurement. The module is able to provide the period time of the digital input
signals connected to the device. The outputs Period1 and Period2 contain the
measured values.
To activate this function the user must:
- set for the channel used as input with ChMode
- set the proper value to the Input_Option parameter (see the table below).
Input Option Table
Val Channel 1 Channel 2
0
No Option Active –
General purpose channel
No Option Active –
General purpose channel
1 Frequency measurement
No Option Active –
General purpose channel
2 Frequency measurement Frequency measurement
3 Counter
No Option Active –
General purpose channel
4 Counter Counter
5 Period measurement
No Option Active –
General purpose channel
6 Period measurement Period measurement
7 Frequency measurement Counter
8 Frequency measurement Period measurement
9 Counter Period measurement