Jump to content

Losing Track of a Paused Subvi !


Recommended Posts

Here is the scenario:

 

You have a heavily nested project and you are debugging your sub-VIs.  You have pressed pause or you are stepping through one of them and you accidentally close your sub-VI.  Meanwhile you have parallel loops and/or active processes going on.

 

How do you find where you have paused?  Breakpoints are easier to find because you can use the breakpoint manager.  But I havent found a menu item that says "Show Pause Location" or something equivalent. 

 

Has anyone been frustrated by this before?  Is there a simple answer or method that I have missed?

 

 

Link to post
Share on other sites
Here is the scenario:

 

You have a heavily nested project and you are debugging your sub-VIs.  You have pressed pause or you are stepping through one of them and you accidentally close your sub-VI.

 

[...]

 

I just read the part about closing the sub VI; I'm not sure I understand the situation or that my snippet will help.

Link to post
Share on other sites
I just read the part about closing the sub VI; I'm not sure I understand the situation or that my snippet will help.

 

I'm not entirely sure either but I think your VI more or less captures the issue although there might need to be some more work. Basically you can close the front panel of a subVI while it is in paused mode and that can happen easily when having a number of panels open. I for myself also tend to look for windows regularly that I had just worked on and more or less inadvertently closed. If the VI was paused it will stay paused, usually preventing at least parts of the rest of the program to continue. So I then have to go and dig for the VI that is paused to make it resume.

 

This is not different to multithreading programming in other languages. If a thread is blocked in single step mode, the rest of the program can usually still continue (not all debuggers support that though as they lack a good way to get an overview of all current threads) and that can have various effects such as stalling other threads too who wait for events and data from the blocked thread or also just pausing whatever the thread in question should do. Without a central overview of all threads and their paused or active state you end up in a complete nighmare.

 

The only thing about your VI that I'm not sure about is if setting the Frontmost property alone is always enough. I could imagine situations where it may be necessary to do additional work like first opening the front panel or unlocking something else.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Similar Content

    • By Grey
      I have a project where main VI is not protected.
      The main VI consists of several sub vi. Many vi are placed one in to other.
      I have to make sure all vis are unprotected.
      how can i know all vis are un protected?
      any shortcut method available instead of opening all vis block diagram one by one  ??
      thanks. 
       
    • By curiouspuya
      Hi all,
       
      This week I am pulling my hair out trying to fix a big project of mine that produces an executable with no errors which then does not run (crashes).  Upon mass compiling the project (waiting 4hrs) I found a bunch of insane objects in various VIs.  An example of one is:
       
      Insane object at FPHP+2C30A9C0, UID 8, in "VdMiyachiLW25AWeldingLaser.lvclass:SendCommand.vi": {tdname } (0x4000): Numeric (DDO )
      insanities in FPHP of C:Program Files (x86)National InstrumentsLabVIEW 2012instr.lib_InstrumentDriversVdInstrumentsVdWeldingLaserVdMiyachiLW25AWeldingLaser_classSendCommand.vi
       
      Note the number of the object in bold above.  I then went an started Heap Peek (ctr+shift+d+h) in an attempt to find and clear the insane objects (for more info on heap peek see: http://labviewwiki.org/Insane_object).
       
      The trouble is that I cannot find the offending objects as per their numbers.  They simply do not appear.  So short of deleting all possible controls and indicators and replacing thme I have not find an easier way to sort out my problem.
       

       
      Does anyone have experience with Heap Peek?  Have you had this problem with it too?  Am I missing something here?
       
      Thanks for any help! 
       
       
      Puya
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.