LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Wrong data flow values

A reasonably simple Labview program fetches spec limit values from a config file, reads actual valus, and then compares expected to actual.

The config file reading is Good. But the values flowing into a Sequence Pane are incorrect. The Labview data probes demonstrate this incorrect behavior.

There are two screen dumps in the enclosed file.

 

Screen #1 show probes 4 and 5 fetching the correct values from the config file.

Probes 1 and 2, inside the Sequence  panel, are incorrect. Since the data flows are connected, probels 5 and 1 are expected to have the same value. This is not the case, Additionally, probes 4 and 2 are expected to have the same value. This is also not the case.

 

Screen #1 shows the correct mapping of the config file values to the dat aflows. The only thing done to correct the error was to delete the vertical flows (line containing probes 1 and 2) and the Sequence entry points. When the same lines and entries were re-created the problem has disappeared.

 

Any thoughts regarding what was occurring and how often this could happen?

The only reason I was able to detec this error is the print statement I was using to log the measurement activity.

0 Kudos
Message 1 of 7
(2,322 Views)

First, you should either post an actual picture of the code in the post (not in a Word doc) or preferably post the code itself. More than likely what happened was that you had moved a wire a some point or had auto-wiring turned on and mis-wired the lines to the tunnels. LabVIEW can get funny that way in that it can create two 90 degree bends in the wire that run along the border of a structure and are not visible. Visually it looks like things are wired correctly however they actually are not. It is common to see this type of error in a case structure on an output tunnel when wiring a line through the case structure and manually wiring each case. From time to time you actually create a new tunnel and it sits on top of the other. You get a broken arrow on the VI yet everything visually looks fine.

 

Without seeing all of your code I would wonder if you actually need the frame structure at all. Proper use of data flow can easily eliminate the need for using frame sequences the majority of the time.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 2 of 7
(2,319 Views)

As Mark points out this is likely a confusion created by hidden wires under the frame of the flat sequence structure. To quickly check if this is so, drag a large selection box over the two terminals and the connected wires that carry the two values into the structure and press CTRL+U to do a selective cleanup. If there's any wiring confusion then cleanup will move the wires about to make any cross over visible.

 

This kind of thing can happen occasionally when auto-wire is selected and one is refactoring or cleaning up code. 

Thoric (CLA, CLED, CTD and LabVIEW Champion)


0 Kudos
Message 3 of 7
(2,268 Views)

Well, the Ctrl-U didn't show anything, but I like the rationale of the suggestion.

So, I selected one of the wires and manually did a "Clean Up Wire". The resultant change was unexpected as it seems one of the tunnels has no connection.

I know that is not true, in  the original drawing, as both values are seen in the data probes. If there was a missing connection, the string formating and data probes would not show both the value 0.3 and 0.8. Only one of these values would be available in the sequence if a tunnel was not connected.

0 Kudos
Message 4 of 7
(2,251 Views)

@Ed_from_Wisconsin wrote:

Well, the Ctrl-U didn't show anything, but I like the rationale of the suggestion.

So, I selected one of the wires and manually did a "Clean Up Wire". The resultant change was unexpected as it seems one of the tunnels has no connection.

I know that is not true, in  the original drawing, as both values are seen in the data probes. If there was a missing connection, the string formating and data probes would not show both the value 0.3 and 0.8. Only one of these values would be available in the sequence if a tunnel was not connected.


I dunno - unless there's a weird bug that I'd never heard of, "cleanup wire" never lies.  But maybe it's hiding the truth.  If you can, do a cleanup of that general area just to make sure that there aren't any hidden goodies that make it look like there is nothing connected.

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 5 of 7
(2,240 Views)

Please post the code or embed the picture. You can create a VI snippet which is very easily embedded in the post. Many people will not open Word documents attached to posts.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 6 of 7
(2,238 Views)

Looking athis second document there are overlapped wires (sometimes the cleanup utility doesn't do a perfect job!), but the only way we can detemrine the true issue here is if we can have the code.

 

I'f you're worried about sharing your code, create a copy of this subVI and remove all the extraneous code to help redact it sufficiently for publishing on here 🙂

Thoric (CLA, CLED, CTD and LabVIEW Champion)


0 Kudos
Message 7 of 7
(2,224 Views)