LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

NI-CAN

Solved!
Go to solution
Highlighted

Hello all,

 

 I'm using the frame API on the NI-CAN 8473 hardware, I dont have a problem to analyze the data.  However i have a small problem, i need to add a control that will help specifying the number of samples to retrieve.  for example i need to read 100 CAN frames and stop. thank you.

 

 

Best Regards,

Hassan Badawi

0 Kudos
Message 1 of 7
(1,790 Views)
Highlighted
Solution
Accepted by topic author hassan.bdw

Hi Hassan,

 

some pseudocode:

repeat
  get CAN frame data
until number of CAN frames >= 100

Looks quite easy!

 

If you need more/specific help you should attach your VI…

Best regards,
GerdW

using LV2011SP1 + LV2017 (+LV2020 sometimes) on Win10+cRIO
Message 2 of 7
(1,775 Views)
Highlighted

Hello GerdW,

 

do you mean to do something like the VI i've attached?.

Thank you.

 

Best Regards,

Hassan Badawi

0 Kudos
Message 3 of 7
(1,765 Views)
Highlighted

Hi Hassan,

 

something like your VI.

 

I would actually collect the data in a (2D) array - right now you only get the last frame data when your VI finishes!

Best regards,
GerdW

using LV2011SP1 + LV2017 (+LV2020 sometimes) on Win10+cRIO
Message 4 of 7
(1,757 Views)
Highlighted
Posting from mobile so I haven't opened your VI. You should use ncReadNetMult to read multiple frames, instead of putting a single frame read in a loop.
0 Kudos
Message 5 of 7
(1,720 Views)
Highlighted

Hello all,

 

Is it possible to send multiple messages having different arbitration ID periodically (messages may have different periods) through single CAN

interface

 

 

0 Kudos
Message 6 of 7
(1,440 Views)
Highlighted
0 Kudos
Message 7 of 7
(1,428 Views)