LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How would you create a waveform with predefined parameters like rise time?

I am trying to run a simulation and I want to generate a signal in Labview where I can define these parameters: rise time, fall time, and pulse width.
 
I know there are ways to do this using DAQ cards but I have no plans of connecting any hardware to the computer since I am using it just for a simulation.
Message 1 of 8
(3,741 Views)
Look at the Functions palette: Analyze >> Signal Processing >> Signal Generation >> Arbitrary Wave.vi. Read the help file carefully as some of the inputs may be specified in unusual units (frequency in cycles per sample).

Lynn
0 Kudos
Message 2 of 8
(3,737 Views)

That was the only function I could see that would work, but it was an array of numbers.

How do you transcribe a signal with these properties (as an example) into this form:

Rise Time: 2 us

Fall Time:   2 us

Pulse Width:  20 us

I just need a logical, easy way to do this, because these are the types of values I want to be able to variable.

0 Kudos
Message 3 of 8
(3,739 Views)
You need to define a sampling rate and then create the array. One way to accomodate variable transition durations and pulse widths is to define equations. For the rise time you could use: v(t) = VL + (VH - VL)*(t/Tr), where VL is the voltage when the pulse is low, VH is the voltage for the top of the pulse, and Tr is the rise time. Keeping track of the time that each segment of the pulse ends and the next segment starts can be a bit tedious if you are doing a pulse train.


I posted a VI earlier today which generates an arbitrary waveform composed of straight line segments in the "Output Voltage Ramps" thread.

Lynn
0 Kudos
Message 4 of 8
(3,729 Views)
An alternate method, which has the advantage of giving you "realistic" waveforms, is to generate a square wave and then filter it with digital filters.  If you want to truly separate the rise and fall times, you may need to generate two waveforms, one for the rising edge and one for the falling, and use pieces of each for your final waveform.  It has been long enough since I attempted anything like this that I don't have a good example.  My apologies.
0 Kudos
Message 5 of 8
(3,720 Views)
Dear atl123,
I am also trying to make such a program, if you have made such a program, can u please mail it to this website otherwise we could we could get in contact. I am also trying to make a program with a 1.5 volts output with 0.15ms pulse width, i have a PXI 1031 generator. Thanx
0 Kudos
Message 6 of 8
(3,694 Views)
Dear all,

I also need to generate a trapezoidal waveform with variable rise/fall times and pulse widths. atl123 mentioned that there are ways to do this using a DAQ card. Can anyone give me any ideas on how to do this? This is my first time working with Labview/DAQ stuff, so apologies if this question is basic.

Thanks a bunch
0 Kudos
Message 7 of 8
(3,592 Views)
gitmeb:
 
While NI makes several arbitrary waveform generators that could output trapezoidal waveforms, chances are those devices would be "overkill" for your particular operation.  Refer to Johnsold's previous post to this tread.  If you search for "Output Voltage Ramps" in the Discussion Forums you will find the thread where he's posted code that will create trapezoidal waves.
 
Hope that helps!
 
Todd S.
Todd S.
LabVIEW Community Manager
National Instruments
0 Kudos
Message 8 of 8
(3,564 Views)