LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

BUG Block diagram cleanup fails completely? Generates very bad results

I find there is value in looking at different ways to do things. Even if you don't use the ideas, thinking about them could lead to better solutions.

 

Off the top of my head ....

 

Benefits of a For Loop Sequencer (FLS) vs a Stacked Sequence Structure (SSS).

  1. You can't see all of the code, but you can at least see the names of the steps in a FLS (if you expand the input array)
  2. Passing data through the sequences (like using a shift register as in the example) would be ugly in a SSS
  3. You can rearrange the steps in an FLS by just changing the input array
  4. You can exit the sequence in a FLS (Conditional Terminal)
  5. You can have a generalized method in a FLS to repeat a step (while loop around case)
  6. You can create a generalized method to address errors in an FLS without repeating code
  7. You won't be harassed by well-meaning folks who abhor the SSS Smiley Wink

You may not need some of these benefits, but I believe the FLS is more flexible and extensible.

 

steve

--------------------------------------------------------------------------------------------------------------------------
Help the forum when you get help. Click the "Solution?" icon on the reply that answers your
question. Give "Kudos" to replies that help.
--------------------------------------------------------------------------------------------------------------------------
Message 41 of 52
(1,317 Views)

With what version of LabVIEW did you see the sequence structures going from dark grey to a lighter grey?  This is the first I've heard of a color change, and I haven't seen it at all.

0 Kudos
Message 42 of 52
(1,314 Views)

Actually all good points on the changes in design.  The multiple flat sequence is an obviously textual language format.  It appears that the data flow should be incorporated into the subVIs along with the associated waits.  Use the data flow for sequencing rather than the sequence structure.

 

The For/Case structure can be a better case as a statemachine where it is a while/case structure allowing for non-fixed sequence of steps in response to a UI.  However both of these "hide" code in non-visible layers making reading a diagram slower.

LabVIEW ChampionLabVIEW Channel Wires

0 Kudos
Message 43 of 52
(1,310 Views)

This has happened to me also, and come to think about it i believe i had Structure frames also. I often try to use the BDCT since the idea is good and if it worked good it'd be a lovely tool. If i'm lucky and win the lottery i get something useful, else it's CTRL+Z.

 

Since much of the selling points of LV is "better code faster" it'd be great if it were "decent looking better code faster". I spend way too much time aligning objects and removing chinks and bends in wires. 🙂

 

If it were a text based language (and i appreciate how much harder it must be to layout a 2D diagram) it's akin to aligning the text rows to the letter 'm' instead of the normal indentation rules.

 

BDCT is a lovely idea, but more a proof on concept than an actual tool, as i see it. E.g. it seems to prioritize wire distance over reduced bends, something i never do manually.

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 44 of 52
(1,288 Views)

@stevem181

Great ideas!  I will definitely keep those in mind.  Thank you Steve!

 

@

I don't recall the exact year they changed, but, I think it was around 2011 +/- when the different flat sequences changed color.  I'm just basing this judgment on I never had any problems with the BDCT when there was only the dark Flat Sequences.  While the BDCT is never meant to absolutely be perfect, it's understood, the problem I'm having is the BDCT is breaking and folding wires.  I' m not too particular what the BDCT does, as long as it whips the code a little tighter, and it doesn't break other wires.  I don't expect it to perfectly align wires, but, I do expect it to NOT break wires.  Is that too simple to ask?

 

@sth

Yes, I agree with Steve, a very good suggestion.  But my point is the BDCT used to work, not well, but, it did a simple job without breaking existing code before.  I wanted to see if any other people are having these problems and I found this thread.  Seemed like a good place to add my comments on the Failure of the BDCT.

 

@

Thank you!  I'm not the only person that sees this problem.  If we don't say anything nothing will ever get done.  The BDCT isn't ever going to be one tool that will make code look perfect...we all know that.  The main point I'm trying to make is don't break my existing code when I use the BDCT.  I don't think that's an unreasonable request.  I think the BDCT should auto clean without breaking and/or folding wires.  That's what the BDCT is doing now.  Heck, if I'm the only person seeing this problem, then yes, it's just me.  But If you have LV2015 or later...and you use the BDCT...then I'm betting you have seen this problem at least once.  

0 Kudos
Message 45 of 52
(1,268 Views)

I think it's not cleaning up after itself.  Check out this post.  It would seem that it is leaving "loose ends" all over the place.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 46 of 52
(1,257 Views)
@Dhubbell wrote:

@@sth

Yes, I agree with Steve, a very good suggestion.  But my point is the BDCT used to work, not well, but, it did a simple job without breaking existing code before.  I wanted to see if any other people are having these problems and I found this thread.  Seemed like a good place to add my comments on the Failure of the BDCT. 

I think I mentioned that from the first time I tried BDCT with a complicated (messy) diagram it left dangling broken wires.  I think this has been an issue with BDCT from the beginning.  So far I have not found a case where the remove broken wires (cmd-B) will not just solve it.

LabVIEW ChampionLabVIEW Channel Wires

0 Kudos
Message 47 of 52
(1,248 Views)

@sth

Yes, for the most part, a CMD/CTRL B will clear broken wires.  But some of the wire behaviors fold under structures or what will happen is other structures will hide under other structures too.  See attached.

 

I'm hopeful the BDCT will be reviewed by NI to see if there can be improvements made.  Yes, I'm sure there's room for improvement on my side too, but, while I've improved by creating many more sub vis, the BDCT isn't keeping pace with all the other Enhancements in LV.  Like I mentioned, very early versions of the BDCT used to work without flaw and with worse code.  Now simple one page BDs are affected when you use the BDCT.  

 

I'm trying to gain support from the community to show that I'm not the only one seeing these BDCT problems.  This thread began back with cober in 2-21-2013.  I'm sure this person felt out numbered at the time.  I too was seeing similar problems back in 2013, but, I didn't say anything.  I think it's time for others who use the BDCT to say something if they are using LV 2015 and are having BDCT problems.  

 

I like staying current with the newest version of LV.  However, if I knew back then what I know now, I'd probably would have stayed with an ealier version of LV if I knew the BDCT would continue to work.  I enjoy using the BDCT when it works.  I hate the BDCT when it breaks my code.

0 Kudos
Message 48 of 52
(1,239 Views)

Another clue I found today, I had only a single flat sequence with two panes, in one of the flat sequence panes, I had a DIAGRAM DISABLE STRUCTURE, very simple VI, not complicated at all.  WITH The DIAGRAM DISABLE STRUCTURE, it would NOT Auto clean and as soon as I removed the DIAGRAM DISABLE STRUCTURE the BDCT Worked!

 

It's weird that Diagram Disable Structure would break the BDCT...

0 Kudos
Message 49 of 52
(1,198 Views)

Well if we are collecting bugs in BDC then sub-diagram labels are a ripe hunting ground.  Especially if you have a multi-line label of documentation or a non-standard height for the label, but even the default has issues.

 

Check while loops, for loops, flat sequence struct, diagram disable, and all those, probably any with a sub diagram.  Hopefully NI is monitoring this thread.  My guess is that it is up to be fixed in the new tech preview version and current LV is on bug maintenance.  I hope not.

LabVIEW ChampionLabVIEW Channel Wires

0 Kudos
Message 50 of 52
(1,180 Views)