Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI
1 ratings:
 5 out of 5     Rate this Document

Setting Buffer Size for the NI-CAN Read and Write Functions

Primary Software: Driver Software>>NI-CAN
Primary Software Version: 2.3
Primary Software Fixed Version: N/A
Secondary Software: N/A
Hardware: Industrial Communications>>CAN

Problem:
Can I set a buffer size for my CAN reads and writes using NI-CAN?

Solution:
If you are using the Channel API, you can't set the buffer size for CAN reads because all memory management for the Channel API is done by the system RAM. However, if you are using the Frame API, you can configure the queue length using the ncConfigCANObj.vi or equivalent C function ncConfig.  Below are the vi and the cluster on the front diagram for CAN Object Config, where the Read Queue Length and Write Queue Length are the buffer sizes.

See the link below for some guidelines on setting queue sizes using NI-CAN.


Related Links:
KnowledgeBase 1YD93QRM: How Large Can I Make the Read and Write Queues For NI-CAN?
Product Manuals: NI-CAN Hardware and Software Manual and Specifications

Attachments:





Report Date: 04/27/2006
Last Updated: 03/27/2009
Document ID: 3WQLCN5N

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