Automotive and Embedded Networks

cancel
Showing results for 
Search instead for 
Did you mean: 

Does the CAN ncReadNetMult clear queued entries?

I'm new to the CAN interface and I have a question regarding frame Polling that I couldn't find in the NI-CAN interface document:

 

I will have say 30CANs on the bus communicating to one main CAN which is 0. If CAN0 transmits a frame message on the CAN bus to a specific node addresss configured via the attribute ID, but is also executing the ncReadNetMult command in a message handler to process incoming frames on the same objectID. Does this command automatically clear all pending queued frames after the ncReadNetMult command returns them or do they need to be cleared after processing them by another command? If the ncReadNetMult command clears the queue, will the other 30CANs still have the same messages pending in their queues if they haven't process them?

 

Also, If I create a message frame and set the RTR bit to issue a remote request for data, how is generally the best way to handle waiting for that same command to be sent back with data? By just polling on ncReadNetMult command in a Timed loop?

 

I guess I'm not quite sure how the individual CAN port queuing works when you have a lot of CAN ports attached to the bus.

Thanks in advance...

0 Kudos
Message 1 of 2
(6,057 Views)

If the other CAN devices still have messages in their respective queues waiting to go out, the command you mentioned will not clear those messages, just what is active on the bus at the time. 

 

For the remote data question, I'd recommend taking a look under the CAN examples in LabVIEW's Example Finder. There are some good examples on remote frames that will help you get started.

 

-Nick-

Nick C | Software Project Manager - LabVIEW Real-Time | National Instruments
0 Kudos
Message 2 of 2
(6,041 Views)