Clear Filters
Clear Filters

Two signals from one analog i/p channel using Analog Input block of Data Acquisition Toolbox

5 views (last 30 days)
I am using the Analog Input block of Data Acquisition Toolbox of Simulink and am seeing two values for one channel. I am using a NI USB-6212 mass determination device. Data is collected at 200 Hz and I have tried using different modes (Differential / SRE / NRSE) but in vain. I am using sample-based signal type.
In the two figures on dropbox link, the top sub-plot is raw data (in V), middle one is data after removing dc-offset and passing through a low pass filter (12 Hz) and last sub-plot is after applying an appropriate gain to see the response (I am interested in measuring angular displacement, so the last sup-plot is in deg).
I understand that there is noise in the system (which is a separate problem and I am working on it) but nonetheless I could not understand as why should I see two signals even though I have selected only one channel. May be I am not clear as how this block interprets the incoming signal.
I double checked the signal in NI's Measurement and Automation Explorer and see only one signal as I expect (with noise of similar magnitude).
Any help will be greatly appreciated.
Thanks Rahul

Accepted Answer

Shankar Subramanian
Shankar Subramanian on 25 Apr 2013
Hi Rahul,
The two values that you see are because the Block Size is set to 2 for NI devices in clocked acquisition mode. Block size is a parameter on the mask as well. You cannot set a value less than 2. You can connect the output of AI block to drop one value out of it before your processing blocks run.

More Answers (1)

Rahul on 25 Apr 2013


Find more on Simulink Data Acquisition in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!