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

How do I Read All Available Samples in the CAN Buffer?

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:
How do I read all available samples in the CAN buffer using the CAN Read VI?

Solution:
You can use the Number of Samples Pending property to read all available samples in the CAN buffer. To access and use this property, follow the steps below:
  1. Drop a CAN Get Property VI from the CAN channel API palette onto the block diagram.
  2. Right-click on the VI, and click on the Number of samples pending entry from the Select type menu.
  3. Wire the Number of Samples Pending output of the CAN Get Property VI into the Number of Samples to Read input of the CAN Read VI.

Each time the CAN Read VI executes, it returns all available samples in the CAN buffer.

Related Links:
Developer Zone Tutorial: The NI-CAN Channel API

Attachments:





Report Date: 04/21/2006
Last Updated: 07/26/2007
Document ID: 3WKAUU5N

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