11-23-2011 10:04 AM
Good day.
I'm a newbie in LabVIEW (first program, to be honest) and I find behaviour of my program unexpected, to say the least.
The pictures ilustrate my problems pretty well, but I will describe them anyway. First of all, my timebase knob only adjusts sawtooth sweeping function's frequency at the moment, it doesn't actually represent the exact time base (but that would be easy to calibrate, so that's not my problem I guess). I would expect XY graph's X scale to "detect" only the amplitude of the sawtooth wave, but with changing frequency two problems arise:
Problem #1: when the time base goes below 100ms/div (frequency of sawtooth function above 10Hz), graph starts to show continuation of a signal at the begining of the XY graph, therefore it starts to overlap the original function and looks messy. Question is: Why does that happen? Would somekind of graph "clearing" after reaching the peak clear the problem?
Problem #2: this is even more unexpected, why when frequency of sawtooth is less than 10Hz, it doesn't seem to be able to reach it's peak? Or maybe it does, but the graph doesn't show that.
As far as I can tell, It has something to do with .1 of a second. If more than one sawtooth wave fits in that, the graph starts to overlap and if the period of sawtooth is more than that, not whole XY graph is filled.
Thank you in advance and sorry if similar question was answered in the past - I tried looking for it (it's hard not to when search is offered before posting ;)) but to no avail.
11-23-2011 11:03 AM - edited 11-23-2011 11:11 AM
Maybe you want to graph both signals vs time. In this case use s wavform graph instead.
11-23-2011 11:15 AM - edited 11-23-2011 11:16 AM
Yup, makes sense about the first one. I think I would be able to fix that in one way or another. Screenshot ilustrates the second problem. It's hard to explain in a way that makes sense since English is not my first language. 🙂 but basically the sawtooth doesn't sweep to the end of X axis for some reason when its frequency is < 10Hz.
P.S. We're specifically instructed to use XY graph for this problem.
11-23-2011 11:41 AM
11-24-2011 05:27 AM
It does have those two traces. The problem is with sawtooth, which controls the x axis. The graph doesn't look the way I would expect it to and I have no idea what is wrong.
11-24-2011 10:55 AM
It's because your Express VI's are set up to only output 100 samples.
11-24-2011 12:57 PM
@K4rolis wrote:
It does have those two traces. The problem is with sawtooth, which controls the x axis. The graph doesn't look the way I would expect it to and I have no idea what is wrong.
No, it has only one trace labeled V(t), which is clearly not what you are graphing because your x-axis is not time.
If it does no look the way you expect it to look, maybe you should tell how you expect it to look! 😄
11-25-2011 02:15 AM - edited 11-25-2011 02:16 AM
Sorry, I should've started with what I actually want to do. 😄
Basically, my asignment is to make a simple oscilloscope which displays signal from signal generator on XY graph (everything's virtual - using LabVIEW's functions. No real equipment involved!). My LabVIEW program shows how I actually understand it, even though it doesn't work. Waveform to be displayed controls Y axis and sawtooth (sweeping) function controls X axis. At least that is what I'm trying to do. 🙂
To be honest, I don't quite understand all the stuff about samples and sample frequencies, so that might be my problem. Attached is a picture which shows what I would like to see. But that is only possible when sweeping function's frequency is 10Hz.
Thank you in advance.