02-22-2005 03:38 AM
02-22-2005 09:18 AM
09-04-2007 01:56 PM
Hi Dennis,
I´ve seen your answers about problems with real time waveform charts.
I have a similar problem in my app (in attachment). I'm acquiring a 10 Hz senoidal signal and my sample rate is 250 Hz. I'm sending (serial port) it (a sample at a time) to another PC. In this one I´m running the vi in attachment. I have one chart and one graph (for testing). I don´t know what I have to do to my XScale show the actual time, that is: When I run the vi, as soon as I start the transmission the waveforms are showed in both graph and chart, but the time in chart Xscale run faster than the actual time, it starts at correct time and I can see 10 cycles of the senoidal signal in 1 second of the chart (10Hz as it is), so the multiplier is ok, but the XScale is showing the time later than the actual time. Why it runs faster?
I´d thank you if you could help me.
Celia
09-04-2007 02:07 PM
Where exactly are you getting a sample rate of 250 Hz? The only thing you are sampling in this example is the serial port and you have no rate defined in the while loop.
Also, get rid of the sequence structure. It does nothing.
09-04-2007 02:18 PM
Dennis,
My sample rate is set by the transmission. The transmission app is in attachment.
09-04-2007 02:19 PM
Dennis,
My sample rate is set by the transmission. The transmission app is in attachment.
09-04-2007 02:30 PM
09-05-2007 08:15 AM
09-05-2007 10:05 AM
I don't know how to make it any clearer. If you want the x axis to reflect actual time, the x axis multiplier has to equal a sample rate and you have no sample rate. If you want 250 samples per second, put a 4 msec wait inside or use a timed loop equal to that. A timed loop would be the best solution.
It's possible that the serial port buffer is retaining old data since you may stop the client after the server is stopped. Do a VISA Flush buffer after you do the VISA Configure Serial Port and see if that helps.
09-05-2007 11:53 AM