This content is not available in your preferred language.

The content is shown in another available language. Your browser may include features that can help translate the text.

How Can I Set Custom Baud Rates on NI-XNET Devices?

Updated Aug 16, 2022

Environment

Driver

  • NI-XNET

How can I set custom baud rates for NI-XNET devices?

NI recommends users to set baud rate value in the database.
  1. Launch NI-XNET Database Editor.
  2. Open the database file. Select the CAN Cluster you wish to modify.
  3. Under CAN Cluster Properties, select <Custom> from Baud Rate drop down menu.
CAN Cluster Properties from NI-XNET Database Editor.
  1. Configure the custom baud rate.
Custom Baud Rate Popup Dialog

Refer to Interface:64bit Baud Rate  and Interface:CAN:64bit FD Baud Rate  for the detailed explanation of the Bit Timing Registers.

To configure custom baud rate of a CAN interface programmatically, write the hexadecimal value from the custom baud rate dialog to Interface:64bit Baud Rate or Interface:CAN:64bit FD Baud Rate property.
  1. Place a property node on your block diagram by going to the Measurement I/O palette >> XNET >> Session Node. Once you have dropped down the node on the block diagram, click the section under XNET Session and navigate to Interface >> 64bit Baud Rate. Navigate to Interface >> CAN >> 64bit FD Baud Rate for CAN FD.
  2. Copy the hexadecimal value from the custom baud rate dialog to the constant or the control and wire the value to the property node.
LabVIEW Property Node
  1. Format the input value into hexadecimal representation if necessary. Right click the constant or the control and choose Display Format... then select Hexadecimal.


Additional Information

When choosing the values for the different parameters in the XNET Database Editor, keep the following in mind:
  1. NI XNET Hardware runs with 40 MHz, so the Time Quantum is 25 ns. If you get the parameters from a hardware with a different frequency, you have to adapt the values. E.g. if your parameters are made for a hardware with 80 MHz, you have to use only half of the value for the XNET hardware.
  2. For some of the values, the hardware adds 1 to the configured value. E.g. if you need a BRP of 2, you need to set 1.