LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

creat 2d array with 2 cluster

Solved!
Go to solution

hello every one,

I have a problem,

I want to create a 2D array who display my 2 cluster of my CAN protocol

I give you my program and I use PCAN drivers in my program

drivers :

https://lavag.org/topic/15784-cr-pcan-driver_lv2009/#comment-95558

 

0 Kudos
Message 1 of 14
(248 Views)

Hi letesego,

 


@letesego wrote:

I have a problem,

I want to create a 2D array who display my 2 cluster of my CAN protocol


Which problem do you have?

Which 2 clusters do you want to process?

Why should there be a 2D array (for display purposes)?

Can you provide a simplified VI with just those 2 clusters and the expected resulting array?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 14
(242 Views)

Hi GerdW

I want to create 2D array indicator who included my data in my 2 cluster so read and write output

the goal it's when a new data was read or write, the data was integrate in the array.

I hope you understand my problem

letesego

0 Kudos
Message 3 of 14
(231 Views)

Capture.PNG

0 Kudos
Message 4 of 14
(227 Views)

Hi letesego,

 


@letesego wrote:

I hope you understand my problem


The image in message #4 helped more than your text…

 

Suggestion:

 

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 14
(224 Views)
Spoiler
that not solve my problem I want add the new data in a other column and keep the old data 
sorry if my english isn't good
letesego
0 Kudos
Message 6 of 14
(215 Views)

Hi letesego,

 


@letesego wrote:
that not solve my problem I want add the new data in a other column and keep the old data 

Please define how to "add new data to a different column": how should the result look like?

 

My example keeps ALL data, regardless of "new" or "old", so please again: define how the result should look like!

 

Btw. there's no need to hide your message in a spoiler tag…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 14
(199 Views)

Capture labview.PNG

0 Kudos
Message 8 of 14
(192 Views)
Solution
Accepted by topic author letesego

Hi letesego,

 

so you want to place ONLY the data arrays of write/read CAN cluster into your 2D array!?

Why don't you write so?

 

Simple solution:

  • Unbundle the data arrays from both CAN clusters.
  • Concatenate both 1D arrays into a larger 1D array.
  • Autoindex the 1D array at the loop border into your 2D array…
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 9 of 14
(181 Views)

Hi GerdW

That was my best try but that not work

I'm testing many thing like use for loop

I think I haven't a good used with array

Could you help me a last time ?

Best regards

letesego

Capture labview2.PNG

0 Kudos
Message 10 of 14
(118 Views)