Jump to content

Is it possible to probe a block diagram WITHOUT the front panel being open?


Recommended Posts

I find myself in this situation a lot, where I have an Actor that inserts itself into a subpanel. I want to look at what's going on in the Actor Core block diagram.

 

Typically I'd stick a breakpoint there so that the particular Actor clone's BD will pop up. But in that case, the front panel also opens, which very often leads to buggy behavior or errors when the Actor later tries to stick itself into a subpanel.

 

Anyone have some workaround suggestions for this? I run into the problem a lot and always slug through somehow but I figure someone's got a better procedure.

Link to comment

I run into this in source (without the AF) and in executables. I put messages throughout the code that go to a debug UI. This may not be able to see all values when the code is running, but it doesn't change the timing of code running at full speed. Since the debug UI displays based on a flag in a configuration file, I can leave the screen in an executable for when I remote into a computer and try to determine what the customer's issue is.

Link to comment

Okay so my actors are not using AF and they aren't reentrant (so there is a bunch less issues I don't have to worry about).  But I also found some times my front panel would be open when inserting it into a subpanel which would cause errors.  So in the code that inserts the actor, it will perform a front panel close, then clear the error if it was never opened.  Then I know the front panel isn't open so it is free to insert it into a subpanel.  I'm pretty sure the close front panel from VI Server doesn't close the block diagram if it is open.  So your debug probes and break points should be left untouched.

Link to comment

I find myself in this situation a lot, where I have an Actor that inserts itself into a subpanel. I want to look at what's going on in the Actor Core block diagram.

 

Typically I'd stick a breakpoint there so that the particular Actor clone's BD will pop up. But in that case, the front panel also opens, which very often leads to buggy behavior or errors when the Actor later tries to stick itself into a subpanel.

 

Anyone have some workaround suggestions for this? I run into the problem a lot and always slug through somehow but I figure someone's got a better procedure.

 

I (not AF, but similar) set the subpanel option “Allow User to Open Block Diagramâ€.  Then I open the block diagram from the subpanel, once the actor’s FP is loaded into it.   Even when the actor leaves the subpanel the diagram stays open (this is a bit strange, since I have open block diagrams with no front panel open).   Much more convenient that having to use breakpoints.

Link to comment

Any routine I write to insert something into a sub-panel first checks the state of the FP and if it is in an incompatible state, I change it to "hidden" before inserting.  I also remember to remember the state so that when removing it I can reinstate the old setting.

 

I generally have a few sub-VIs to do this work for me.


Ps I don't close the FP because that can lead to really problematic situations where (AF aside) the VI is actually exited upon setting the FP to being closed.

 

I have (in the past) also taken a reference (Open VI Reference) of the VI first, set the FP to close and then inserted it.  Explicitly opening a reference to the VI (in the case it has been passed as a parameter instead of opening it within the sub-panel calling VI) prevents the VI from being stopped.

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
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.