06-27-2016 12:42 PM
@big5824 wrote:
Norbert, trust me, having previously approached this problem in the way you are suggesting the flat sequence structure is an appropiate tool for my application. Could we please focus on the Labview bug I'm trying to find a fix for instead of coding style? No amount or lack of local variables will fix the bug.
Well actually, the coding style could be what is causing the issue. LabVIEW is trying to coerce you into using subVIs. (Well, okay - that last part was my own).
But in reality, when you have huge BDs things go haywire when you try to manipulate the block diagram. It shouldn't, but it does.
I keep wondering two things about LabVIEW developers that come from text language backgrounds:
The strange thing to me is, you'd never see C source where everything is dumped into main(), which is analagous to placing everything in one huge block diagram.
The other strange thing is that you'd never see C code with random indents. This is what spaghetti wire is analogous to. While it makes no difference to the compiler in both cases, in both cases I'd also walk out of the room if a teammate came in and started strangling you because he couldn't read the code. 😄
06-28-2016 02:19 AM
@big5824 wrote:
Norbert, trust me, [..] Could we please focus on the Labview bug I'm trying to find a fix for instead of coding style? No amount or lack of local variables will fix the bug.
Well, as pointed out:
There seems to be a bug with sequence frames in timed structures concerning the Clean Up tool. There won't be a hot fix for your specific LV version specifically for you solving the issue directly in LV itself.
Talking about coding style is THE ONLY SOLUTION you have right now if you want to avoid running into this weird situation ever again.
Besides, my personal opinion about the Clean Up tool: If you need it, you definetly did something terribly wrong....
Semi-official reply: Clean Up tool is a tool which helps developers to handle inherited, unstructured code by hopefully increasing readability by a little amount. However, there are some known and obviously some unknown bugs in this tool so thank you for reporting this.
@ Matt J: Can you provide a CAR ID for this?
thanks,
Norbert
06-28-2016 04:53 PM
CAR 594070: Peforming BD Cleanup of Items in a Timed Structure's Frame Behaves Incorrectly
As the title indicates, the behavior is also the same for items in a Timed Sequence Structure. I mentioned this in a previous post but I the workaround I included was, "Place a flat sequence structure around whatever you want to cleanup and selectively cleanup the contents in the structure.". Let me know if there is a better or alternative workaround that should be included.
I don't think the diagram cleanup is as bad a tool as you are making it out to be though. For smaller amounts of code that doesn't have deep nesting it works pretty well.