04-10-2014 04:57 AM - edited 04-10-2014 05:07 AM
Hello, can anyone help me to build a signal conditioning function. Function of current vi is gather current analog input signal and covert to PSI from first channel. I want create an subvi called filter to accurate in range of signal.
For example: gather sample in every 100ms, cut of highest and lowest data. Get average of sample data. Function quite like Filter express in wave conditioning palette. Please find vi file and picture for more detail.
task is created by simulate NI USB 9201,
Thank you.
04-10-2014 07:16 AM
please find attached vi file, I got error 20023 meesage when use filter function.
04-10-2014 07:42 AM
04-10-2014 07:57 AM
thanks, but error message is still here even acquistion mode is continuous samples.
04-10-2014 08:00 AM
Hi jiannan,
well: you use that ExpressVI - it's your fault…
Acquisition mode (continuous) is irrelevant here. It's the number of samples you need to know! You have to select a different DAQmxRead mode: "n chan n samples" - and you need to read more than just one sample per Read!
Additionally you need to convert your data to waveform (or read waveforms from DAQmx) to have that Filter-ExpressVI know the sample rate of your data. Then you still have to fulfill the condition mentioned in that error message…
04-10-2014 08:19 AM
Hi GerdW
Thank you for your explain, just follow your steps, but error is still there, any hint?
04-10-2014 08:29 AM - edited 04-10-2014 08:30 AM
Hi jiannan,
- from your picture we cannot see your sample rate settings
- setting a dt of 1 (second!) in the waveform is surely wrong…
- why don't you even want to change the dt of your waveforms?
- why don't you request a certain number of samples from DAQmxRead?
And:
Why don't you clean up your block diagram? Doing so before posting is kind of respect for the forum participants…
04-10-2014 08:57 AM
I am sorry for mess block diagram. will clean up next time when post,
The code is working fine without filter.but I want get more accurated result. so just like get solution soon.
i am not asking you to do my work. it would be better just to tell me how i could finish it.
Regards
04-10-2014 10:27 AM