Use Third Party CAN, LIN, and FlexRay Devices in LabVIEW

Updated Apr 17, 2018

Reported In

Hardware

  • CAN Interface Device
  • LIN Interface Device
  • FlexRay Interface Device

Software

  • LabVIEW

Driver

  • NI-CAN
  • NI-XNET

Other

Third party CAN/LIN/FlexRay devices

Issue Details

How can I use a Third-Party CAN, LIN, or FlexRay device with LabVIEW? What do I need to install when using non-NI interfaces with LabVIEW?

Solution

To use third-party CAN, LIN, or FlexRay interfaces with LabVIEW, the provider must have a written library that can be called from the software. Usually in the form of LabVIEW VIs, Dynamic-Link Libraries (.dll), or .NET/ActiveX constructors. When setting up your device, look for the next two items:

 

  1. The driver required to interface with your computer. For example: if the CAN interface connects by USB, you will need the driver from the vendor to properly recognize it.
  2. The driver's calling instructions. Sometimes vendors will have already built VI libraries for LabVIEW, which you can download from their website and use normally. Other times, they will provide instructions to create .NET/ActiveX constructors. One last option is to call the driver's C functions from the .dll library using the Call Library Function Node.

 

For example: To use the CANCapture® Standard ECOM cable, you will need to download the ECOM Device Driver, and use the Simple LabVIEW Example (and LabVIEW Driver) that comes with it.

Additional Information

For a smoother experience using CAN, LIN, and FlexRay communications, NI offers an array of hardware options that include the USB, cDAQ, cRIO, PCI and PXI platforms. More information here: Vehicle Communication Buses.

 

NI-XNET is the newest National Instrument's driver to interface with CAN, LIN and FlexRay devices. NI-XNET just works with selected National Instruments hardware. Read more about its supported resources in the NI-XNET Readme file.

 

NI-CAN is a legacy driver used to interface with former National Instrument's CAN devices. Read more about its supported hardware in the NI-CAN Readme file. Note: NI-CAN just supports LabVIEW 32-bit version.

WAS THIS ARTICLE HELPFUL?

Not Helpful