LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

frequency sweep simulation challenge

Hello,

 I have been trying to simulate two speed signals with the following specification.

Signal 1:

Maximum amplitude:    5V

Minimum amplitude:     12V

Form:                                    Sinusoidal

OP Impedance:                 ~100 Ohm

Switchable:                         8Hz or 800Hz

 

Signal 2:

Maximum amplitude:    5V

Minimum amplitude:     12V

Form:                                    Sinusoidal

OP Impedance:                 ~100 Ohm

Adjustable over:              8Hz to 1000Hz

Soft switchable sweep: 800 Hz rising @ 7% per second

                                                800 Hz rising @ 9% per second

                                                800Hz rising @ 11% per second.

I have implemented the first part. For the second one,  I have used the formula for the sweep, taking the 7% per second as an example.

From v = u + at where v is freqency, and then integrating:

800Hz to 1.07*800:                          800 + 56t

856 Hz to 1.07*856;                         856 + 59.2t

915.92Hz to 980.0344;                915.92 + 980.0344t

sin((800* t) + ((56*t*t)/2))+sin((856* t) + ((59.2*t*t)/2))+sin((915.92* t) + ((980.0344*t*t)/2))

 I have tried simulating two portions of this sine wave. But I cannot implement the whole thing on a single waveform.

Please help. I have attached the Vis for 1 and a trial for the second one.

 

Thanks.

0 Kudos
Message 1 of 7
(3,259 Views)

Hey there,

Are you looking at doing a linear sweep? A really good example LabVIEW code for showing a broad range of analog signals, including a linear sweep is shown http://zone.ni.com/devzone/cda/epd/p/id/4623#0requirements

From what it sounds like you are wanting to do a Chirp signal. A chirp signal is a signal which continuously increases in frequency (or down). This is explained in the KnowledgeBase article KB 4HHCCOD2

 

Please let us know how your getting on.

 

Kind regards,

Ashish Naik
Automotive Business Development Manager
National Instruments UK
0 Kudos
Message 2 of 7
(3,217 Views)

Thanks a lot for the wonderful response. I intend trying it out using the formula:

 

f = sin(2*pi[(f+(rate*t)]t ) i.e from f = sin(2*pi*f*t)

 

f = initial frequeny, in my case, 800Hz

   rate = rate of sweep increase with options of 7%, 9% and 11% in my case.

t= time in seconds.

 

I hope to implement it using the formula waveform vi.

 

I would get back with the VI later in the day.

 

Thanks a lot.

0 Kudos
Message 3 of 7
(3,199 Views)

Thanks for letting me know. Please give us a shout with how you get on!

 

Ash

Ashish Naik
Automotive Business Development Manager
National Instruments UK
0 Kudos
Message 4 of 7
(3,184 Views)

Hi,

 

I have been able to come up with this VI to get a sweep for a 7% increasing frequency. Please have a look at the VI and let me know what you think.

 

I have attached the VI here.

 

from sin (2*pi*f*t)

 

sin(2*pi*f(t)*t)

f(t) = f0(1+at)   where f0 is initial frequency and a is the rate of increase in this case, 7%

sin(2*pi*f0(1+at)*t)

 

 

0 Kudos
Message 5 of 7
(3,165 Views)

Hi maxidivine,

 

I am glad that you have got things working! I have if you dont mind edited the vi to give you another control to be able to change the % of the rise per second, as I noticed this was a requirement of yours.

 

Please let me know what you think.

 

Ash

Ashish Naik
Automotive Business Development Manager
National Instruments UK
0 Kudos
Message 6 of 7
(3,147 Views)

Thanks so much. It is amazing just how powerful LabVIEW is. I have resumed work on a datalogging project and things are going well. I would not hesitate to seek for assistance from this very useful and encouraging forum.

 

Thanks.

 

 

0 Kudos
Message 7 of 7
(3,140 Views)