LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Concatenating Tunnel Bug?

I think there may be a bug using concatenating tunnels on RT if the 1D Array input to the tunnel is a Fixed Size array coming from the FPGA code.  See the image below.

 

Tunnel Bug .png

 

Each array of 6 U32 is a CAN frame coming from an NI-9853.  The for loop is looking for 4 CAN frames since that is what my device outputs.  As you can see the indexed array is properly sized at 4x6, but the concatenated tunnel is only 6 long instead of 24.

 

I tried duplicating the bug with an array of random numbers but it worked fine, which is what led me to the conclusion about the fixed size arrays. 

 

Edit: If I create the array without right clicking>create indicator (or edit the indicator's Size property) I get the properly sized array of 24, but only the first 6 indices are right.  The other 18 are all 0

--
Tim Elsey
Certified LabVIEW Architect
0 Kudos
Message 1 of 7
(3,299 Views)

I can't test your bug at the moment, but as for a work around, is it possible to convert the fixed array to a normal LabVIEW array?  Maybe try a Insert Array element at index 0, then delete it.  Does concatenating out of the for loop work then?

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

Off the top of my head, I can confirm this. I think I ran into this issue recently when I copied a fixed size array from my FPGA code (forgetting it was fixed size) and put it on my RT block diagram (just did it to get the same data type easily). I can't really blame NI for not testing/catching this, but I believe I saw the same issue.

0 Kudos
Message 3 of 7
(3,265 Views)

@Hooovahh wrote:

I can't test your bug at the moment, but as for a work around, is it possible to convert the fixed array to a normal LabVIEW array?  Maybe try a Insert Array element at index 0, then delete it.  Does concatenating out of the for loop work then?


The workaround I'm using is just reshaping the array from the indexed tunnel.  But, yes inserting into an empty array works.  So does replacing a subset of an array with 6 elements

--
Tim Elsey
Certified LabVIEW Architect
0 Kudos
Message 4 of 7
(3,258 Views)

Another option: right click your indicator, open its properties, and see if it's set to "adapt to source." It may not be the concatentating thats the problem, it may be once it gets to the indicator to be displayed. If it's adapting to a fix sized array, that may be your issue.

0 Kudos
Message 5 of 7
(3,234 Views)

@for(imstuck) wrote:

Another option: right click your indicator, open its properties, and see if it's set to "adapt to type." It may not be the concatentating thats the problem, it may be once it gets to the indicator to be displayed. If it's adapting to a fix sized array, that may be your issue


Not sure if you caught the edit at the bottom of my first post - That also was an issue, but there still seems to be issue with the concatenating.

--
Tim Elsey
Certified LabVIEW Architect
0 Kudos
Message 6 of 7
(3,231 Views)

@elset191 wrote:

@for(imstuck) wrote:

Another option: right click your indicator, open its properties, and see if it's set to "adapt to type." It may not be the concatentating thats the problem, it may be once it gets to the indicator to be displayed. If it's adapting to a fix sized array, that may be your issue


Not sure if you caught the edit at the bottom of my first post - That also was an issue, but there still seems to be issue with the concatenating.


mah baddd

0 Kudos
Message 7 of 7
(3,228 Views)