06-09-2009 06:23 PM
I don't have LV8.6 installed, so I could not look at the code. Is there a stop button for the sub-vi? 😮
And it (the sub-vi) is called from within a sub-vi? 😮
Can you describe the behavior you were trying to code? Without seeing the sub-vi (and main-vi), it sounds like you are trying to control the sub-vi from the main vi, and that the main vi runs until you quit the application. As I explained earlier, you may want to consider an Event Structure to call (start), control and stop the sub-vi. The events affecting the sub-vi can be communicated to it using queues, notifiers, ActionEngines, references...
Did you want it (sub-vi) to be the active screen and the operator interface until you click stop. It is a novice (beginner) way of programming and does not allow suitable application control from the main vi while the sub-vi is running. Thus, not a proper to write code.
(all this to say that again I agree with Dennis)
R
06-18-2009 03:27 AM
i wanted to simplify my problem but i might simplified it too much ,
i solved the problem thanks to GOD , and simply by implementing a parallel loops in the same VI , this was a project that calculates the Speed of a car after acquiring the signal from the Speedometer sensor.
i wanted to make a loop that handles the timing measurements , like total testing time , drive time and stop time
using the producer/consumer i made it
Thanks alot to Dennis and Ray
Regards..
10-16-2009 01:45 AM
hi,
Mr. Mohammed Ashraf i need your help.... i'm doing a project which is similar to ur project.... while doing normal program i was completed my project..... but suddenly my head told me to create very module to be in subvi... so i my program into three module Subvi (Learning the signal and saving in file, Comparing with the real time signal with save data, report generation) but now i was struck in the first module Subvi itself....
Pls can u help me to finish this....
10-16-2009 02:14 AM
hi,
Here i attached my module Main program vi with subvi.... In the main program vi u have to the numeric value in which the for loop wil run... then u have to the signal from the enum controller with corresponds to the signal your are selected the output show in the Main program vi... pls help me.... I'm waiting for your reply...
note: i have attached just the example(method) of my project...
10-16-2009 02:39 AM - edited 10-16-2009 02:40 AM
10-19-2009 01:21 AM
i got the answer... here i attached my file.... i use Control refnum.. in the main_prg.vi and subvi. 🙂
because i want to learn more in labview ... i was post my question in 2 threads.. im sorry for that... after two days i was completed my first module... thank you u guide and then if i have further i'l contact u later...
10-19-2009 01:53 AM
10-20-2009 05:43 AM
To Mr. Ashraf
Trying Using parallel while loops in flat sequences in the same VI. placing the main VI in one window and the Sub Vi in the other. U need not complicate things by messing with while loop in a SUb VI controllable from the main VI. Its good that uve already solved the problem.
Have a good time.