LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

sampling problem of serially inputted sinewave

hello everyone,

Again sampling problem

Iam using PIC16f877A to serially interface with PC ..

When I am giving input of AC sine wave , the labview wave chart showing accurate AC sine wave upto 2-3Hz but as I increases frequnecy upto 5-7Hz or higher aliasing occurs.. And I am confirmed about that my PIC sampling rate is correct because (to check) taking samples and plotting it on other software it reconstruct same sinewave as inputted..

Am I doing something wrong...?

Please help...

Newbie to labview

 

Thank You ..

0 Kudos
Message 1 of 3
(2,312 Views)

yep- something wrong.

 

You do not need the wait til next ms multiple or Loop delay.  the VISA Read will throttle the loop for you (as well as all the UI thread switches inside the loop).

 

You should use Append to waveform.vi rather than build the waveform from scratch each iteration

See example

untitled.png

 

But the bigest reason you are loosing data is the insanity of disabling end on term character of new-line and throwing out most of the data with the Pick line primitive wired to the line index control?  Don't you want every reading?


"Should be" isn't "Is" -Jay
0 Kudos
Message 2 of 3
(2,304 Views)

Hi thank you for reply..

In the attach figure I tried to give you reason that why I am using (Pick a line block) hope you will understand what I want to say..

0 Kudos
Message 3 of 3
(2,297 Views)