LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to get time stamp

Thanks Anand, will try and let you know..
0 Kudos
Message 11 of 20
(1,363 Views)

Hi Anand,

 

I tried what you suggested. Here are the results so far.

 

I will try to explain my problem a bit more...

 

When I run my VI, my pressure pump starts running, and pressure in the system starts to increase.

 

I want to calculate pressure (P) over time (t) ratio (P/t) at the instant the rising pressure crosses 80mmHg.

 

The attached VI does something close. Only thing is that I want the FIRST P/t value when this condition is met and want to use it further. So, I want that first P/t to be stored somewhere temporarily while the program is still running.

 

Based on the first instant of P/t when the pressure crosses 80mmHg, I want to run a motorized leakage valve for a time period proportional to P/t.

 

So, I have 2 problems:

 

(1) How to hold/latch the P/t value associated with the instant when rising pressure crosses 80mmHg.

 

(2) How to send voltage signal to motorized valve only for a fixed duration (range ~ 1-2 seconds), based on the detected P/t ratio.

 

Thanks!

 

VI Attached.

0 Kudos
Message 12 of 20
(1,354 Views)

So you want to calculate the slew rate of the pressure when it reaches 80mmHg? Do you have a image of how the pressue increase w.r.t time also please post the vi in 2009 version.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 13 of 20
(1,352 Views)

Hi Anand,

 

I want to know how long it took the pump to pump upto 80mmHg.

 

The pressure plot is attached.

 

I have Labview 2011. Is there a way to save the VI as 2009 version?

 

I am attaching the picture of the VI.

 

cheers,

 

Saif

Download All
0 Kudos
Message 14 of 20
(1,349 Views)

From the Picture I can see that the pressure reaches 80 mmHg around 10 seconds so you want that time has to be found automatically?.

 

Yes go to File>>Save for previous verison>> Select 2009 and save.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 15 of 20
(1,346 Views)

Yes that is correct. And also I want to use that P/t ratio further.

 

Attached in 2009.

0 Kudos
Message 16 of 20
(1,343 Views)

Yes, that time should be found automatically because this ratio changes for individuals. So, for me it reacged there  in 10 s. For somebody else with bigger arm, it will reach there in 12 seconds, and so on. 

0 Kudos
Message 17 of 20
(1,342 Views)

I have attached a code in that you replace the DAQmx DBL control with the DAQmx vi. The code gives you the time once the pressure crossed 80mmHg.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 18 of 20
(1,338 Views)

Hello Anand,

 

This is great! I just cheked it and it works 🙂

 

I will try to understand what you did.

 

Also, now I will try the remainder of the problem.

 

Cheers,

 

Saif

0 Kudos
Message 19 of 20
(1,336 Views)

Hi Anand,

 

Hope you are doing very well!

 

If you remember, you had helped me with this problem a few days ago.

 

All works well.

 

I noticed one thing. When I ask the system to give me the time elapsed to reach a pressure of 80, it does. However, when I analyze this data in Matlab, I realize that there is some delay. So, for example, the systems outputs T = 7 s to reach 80. When I check offline, T = 7 s actually corresponds to 83. This valuse seems to be moving up&down a bit.

 

I wanted to ask you if there is a way to get the actual system pressure at T = 7s (say)? I tried to read the acutal pressure as soon as T latches from 0 to 7 s. However, I need the system pressure also to latch.

 

Is this possible?

 

Any help would be much appreciated!

 

Cheers,

 

Saif

.

0 Kudos
Message 20 of 20
(1,313 Views)