From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

waveform different time frequency

You can also use script:

Call ChnLinGen("/Time_channel",begin_value,end_value,number_of_values,"")

 

Simyfren

0 Kudos
Message 11 of 23
(2,940 Views)

No, this cannot work,

 

Obviously, ploting channel Vsum as function of the time channel or as function of the lineargenerated channel is not equivalent....

 

Regards,

 

Louval

 

0 Kudos
Message 12 of 23
(2,937 Views)

Why not?

 

Simyfren

0 Kudos
Message 13 of 23
(2,935 Views)

Because the generated time is equidistant, the original is not, so of course plotting the same data channel as function of one or the other is different.

 

I believe you did not understand my goal.

 

I need to transform my time channel so that I can perform the ChnTowfChn function on (time, vsum).

 

Thank you,

 

Louval

 

0 Kudos
Message 14 of 23
(2,929 Views)

Yes I understand Louval.

 

It isnot the same!. What you need to do is interpolate your original channel. For doing this first generate a linear equidistant channel with the time interval and then use this.

 

 

Call ChnMapLinCalc("OriginalTimeChannel","Vsum","LinearGenerated", "ResultChannel",True,"f[bound.slope]",NoValue,"analogue")

 

Then "ResultChannel" and the equidistant channel can be converted to waveform.

 

0 Kudos
Message 15 of 23
(2,926 Views)

I don't why you have time not equidistant, because time is generally equidistant.

But, try to divide channels into 6 channels (so that the time will be equidistant) and create waveforms separately.

 

Simyfren

0 Kudos
Message 16 of 23
(2,924 Views)

TIme is not equidistant if the aquisition frequency is changing during the aquisition. That is why.

I would like to avoid dividing channels... but yes this is defintely a solution. 

 

Louval

0 Kudos
Message 17 of 23
(2,922 Views)

I think you have no choice.

 

Simyfren

0 Kudos
Message 18 of 23
(2,919 Views)

You don't have to divide the channels, even if you divide the original channel it means that each division should contain exactly the same sample rate!!!. Which i wonder is not true.

 

The only solution is to interpolate the channels to "fix a sample rate". otherwise there is no way to convert to waveform. If you interpolate close to the average sampling rate of your original signal the results should not be affected considerably.

 

regards,

0 Kudos
Message 19 of 23
(2,918 Views)

Use this insted

 

Call ChnMapLinCalc("OriginalTimeChannel","Vsum","LinearGenerated", "Vsum",True,"f[bound.slope]",NoValue,"analogue")

 

And then the "LinearGenerated" and "VSum", can be converted to waveform channel!.

 

Regards.!

0 Kudos
Message 20 of 23
(2,913 Views)