Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI
This Document is not yet Rated  Rate this Document

Programmatically Changing the Baud Rate of the NI 9852 CAN Module

Primary Software: LabVIEW Modules>>FPGA Module
Primary Software Version: 8.0
Primary Software Fixed Version: 8.0
Secondary Software: Driver Software>>NI-CAN
Hardware: Industrial Communications>>CAN>>cRIO-9852

Problem:
I need to change the baud rate of a port on my NI 9852 CompactRIO CAN module from the default of 500 Kbps. How do I do this?

Solution:
Changing the baud rate manually
To manually set the baud rate for the NI 9852 module complete the following steps.
  1. Right-click on the module in the Project Explorer window for your project and select Properties. This will open the C Series Module Properties dialog box for the NI 9852 module.
  2. Select the CAN0 or CAN1 tab and select the desired baud rate from the Baud Rate listbox.
  3. Click OK.
Changing the baud rate programmatically
Use an FPGA I/O Property Node for the specified CAN port with the property Bit Timing. To use this property CAN communication must be stopped for the port, otherwise the property node will return an error.

The correct usage is to include an FPGA I/O Method Node with the Stop method selected before writing to the FPGA Property Node, then using another FPGA I/O Method Node with the Start method selected right afterwards. See the image below.



Related Links:
KnowledgeBase 0ZEF3MHR: How Can I Set Nonstandard Baud Rates in NI-CAN?

Attachments:


CanBitTiming.JPG


Report Date: 03/07/2007
Last Updated: 03/08/2007
Document ID: 47699UQ4

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
  1 2 3 4 5
Please Contact NI for all product and support inquiries.submit