LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to locate the trigger point at the center (0.3s) of the windows in the "Turn on current waveform"?

Dear My friends,

 

   I have one question. I have a labview vi program as enclosed it. The program is to record the turn-on transient current waveform from the DAQmx. My problem is the trigger point can not be located at the center of the window for the "turn on transient current waveform", i.e., 0.3s when the length of the window is 0.6s (the sampling rate is 10080Hz, the samples per channel is 6000).

Sometime, the turn on current waveform is also displayed in the window of "current waveform". 

 

It is appreciated for your responses.

 

sschang

0 Kudos
Message 1 of 8
(835 Views)

Hi sschang,

 


@sschang wrote:

Sometime, the turn on current waveform is also displayed in the window of "current waveform". 


That's because the coparison before the case structure results in FALSE…

 

What's the point of all those Rube-Goldbergs?

  • Why do you use FiniteSamples when you create, start and kill the DAQmx task in each iteration?
  • Why is there a loop inside the case structure?
  • Why is there an "x AND TRUE" function before the case structure?

What's the purpose of the VI in general? What do you want to achieve?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 8
(796 Views)

Hi, GerdW

 

Thanks for your responses.

1. The purpose of the VI is designed to be a signal oscilloscope to storage and measure a complete transient current waveform of turn-on event, i.e., turn-on hair dryer.

2. The turn-on event will be detected continuously after the VI has the complete transient current waveform. The complete turn-on transient current waveform is  stored to be an EXCEL file for the analyses of the appliance.

3.  The loop inside the case structure is able to remove.

4. The  "x AND TRUE" function before the case structure is used to detect the turn-on point. The rms value is more than the value of the threshold when the appliance is turned on. The turn-on transient waveform will be stored. 

 

Please refer the website for the details.

https://www.youtube.com/watch?v=pmCpAHAbb08

 

How can I do? The turn-on transient current waveform should not show in the "current waveform window", and the turn-on point can be located at the center of the transient waveform window. Please!

 

Thanks.

 

sschang 

 

 

 

 

 

0 Kudos
Message 3 of 8
(776 Views)

Hi sschang,

 


@sschang wrote:

My problem is the trigger point can not be located at the center of the window for the "turn on transient current waveform", i.e., 0.3s when the length of the window is 0.6s


Why/how do you want to detect your "trigger point" at the "center of the window"?

How do you know that "point" will be in that specific position within the waveform data?

Why do you calculate the RMS of the whole waveform when you want to examine the sample "at the center"?

 

This is all very unclear for me! (I just fast forwarded that video, it didn't contain any code.)

 

IMHO you should start with a VI like this:

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 8
(762 Views)

Hi, 

 

  Thanks for your answer.

How about the trigger point?

 

I hope the transient current waveform is located in the center of the "turn-on transient current waveform window" not in the "current waveform window" when the appliance is turned on, 0.3s before and after the trigger point in the turn-on transient window. There is enough sample data for the signal processing of appliance's feature extraction.

The rms is an easy way to detect the turn-on of the appliance to compare with the value of threshold.

 

sschang

 

0 Kudos
Message 5 of 8
(733 Views)

Hi, GerdW,

 

  Enclosed please find the revised version according to your comments.

 

How about the trigger point to show in the center of the turn-on transient current window when the appliance is turned on?

 

Thanks.

 

sschang

0 Kudos
Message 6 of 8
(728 Views)

Hi sschang,

 


@sschang wrote:

 Enclosed please find the revised version according to your comments.

 

How about the trigger point to show in the center of the turn-on transient current window when the appliance is turned on?


Why is there again that "x AND TRUE" function? This is a PURE RUBE-GOLDBERG!!!

Why is the label of the stop button hidden in the block diagram and why does it still hold a default label?

 

I don't know how that simple VI should show your "trigger point" in the center of the graph on it's own: right now it depends on the acquisition of the samples, which may occur in the right moment - but most probably will not…

 

When you want to make sure you see the interesting part of the waveform in the center of the graph (x axis) then you need to do some post-processing of your signal data: find the "trigger point", then cut the waveform so you have the same number of samples before and after that "point"…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 8
(696 Views)

Hi, GerdW,

 

  GerdW wrote: When you want to make sure you see the interesting part of the waveform in the center of the graph (x axis) then you need to do some post-processing of your signal data: find the "trigger point", then cut the waveform so you have the same number of samples before and after that "point"…

 

As you mentioned above for the post-processing to find the trigger point, this is my key problem. Before doing this, I have to save a waveform of samples in the "Write to the measurement file" in advance when the appliance is turned on. The length of waveform is 6000 samples at least, includes samples before and after the trigger point.

 

The data will be very large if the samples are always saved in the "Write to the measurement file". Then, I cut out the samples for the post processing before 6000 samples of the end. It is not smart. So, It would be better to use for the event trigger to save the samples only 3000 samples before and after the trigger for the enough data in feature extraction.

 

How can I do for the VI? please!

 

best

sschang

0 Kudos
Message 8 of 8
(666 Views)