Jump to content

Restart depending on debug


Recommended Posts

I have this rather strange problem. The VI I'm working with is based on a rather complex home-grown LVOOP. If I open the project and run the VI, then it works as it should. Then I stop it (from within the application, not "Abort Execution") and start it again, and it does not work as expected - it runs, but doesn't do what it is supposed to do.

Then I add a strategically placed breakpoint, start it, and the VI works every time (I just need to hit "Continue" when it reaches the breakpoint). With the breakpoint active I can stop and start it as many times as I want. When I remove the breakpoint, the VI again starts working only on the first run again.

Does anyone have a clue what is going on here?

Miha

Link to comment

Things like this are usually timing issues. Is something running in parallel that could be changing values on you? What happens if you put in a wait just before where your breakpoint is and remove the breakpoint? Without seeing the code, these are the best suggestions I can come up with.

Link to comment

Agreed it's a timing problem. Make sure you use a nice long Wait (5-10 seconds, however long it would take you to see the break come up, switch screens, select continue etc) to confirm.

If you can't figure out what item is the problem, you can try moving the Wait around your code until you can find which items are having the effect. (Personally, I find it easiest to just move the wait "back" from where you have it until it stops helping - whatever you just jumped is either the culprit or occurs at the same time as the culprit). Given LabView's asynchronicity, this can be a bit more complicated but you can probably still determine what things are going on at the critical moment.

Link to comment

Mystery "solved"! The restart doesn't work only on WinXP :frusty:. On Windows 7 restart doesn't cause any problems.

Not that this doesn't leave me with a problem, since the end result should work on any system (including RT targets) :(

Link to comment

Join the conversation

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

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
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.

×
×
  • Create New...

Important Information

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