08-31-2009 04:26 AM
Hi All,
I want to read a CAN message with arbitration id 700h from CAN bus. There may be more then one CAN message available on the bus. How can i read a CAN message of particular arbitration id from CAN bus.
Kindly reply as soon as available.
Regards,
J
09-01-2009 01:23 AM
Hi ,
Check out the following VI. Also refer to the CAN manual: http://www.ni.com/pdf/manuals/370289m.pdf
Hope that helps.
Kudos are welcome.
09-01-2009 01:27 AM
Hi,
Kindly attached this example in Labview 7.1.
09-01-2009 01:44 AM
Hi,
I am attaching the screenshot of the VI. Hope it works in 7.1. Else upgrade LabVIEW.
Kudos are welcome
09-02-2009 08:29 AM
Hi All
With ncOpen.vi we can set the particular arbitration id that we want to read from the CAN bus. Now if i have to read 3 arbitration id & write 2 arbitration id then can it possible by using one ncOpen.vi function or i have to use ncOpen.vi for every arbitration id ?
Kindly reply as soon as possible.
/J
09-02-2009 08:37 AM
Also let me know what is the use of Mask & Comparator in ncConfigCANNET.vi. Can it be use for filtering the Arbitration id which we want to read ?
09-03-2009 01:44 AM - edited 09-03-2009 01:46 AM
Hi,
With ncopen you can only set one arbitration id. Check out the ncreadobjmulti.vi and ncwritemultiobj.vi
Examples of CAN in Example finder will help you understand it better.
Standard Comparator is the CAN arbitration ID for the standard (11-bit) frame comparator.
Standard Mask is the bit mask used in conjunction with the Standard Comparator attribute for filtration of incoming standard (11-bit) CAN frames. If the mask/comparator matches, the frame is stored in the Network Interface queue, otherwise it is discarded. Bits in the mask that are clear are treated as don't-cares. For example, hex 00000700 means to compare only the three upper bits of the 11-bit standard ID.
Kindly refer to the following threads and manual for more information:
http://www.ni.com/pdf/manuals/370289k.pdf
http://forums.ni.com/ni/board/message?board.id=30&message.id=505&requireLogin=False
http://forums.ni.com/ni/board/message?board.id=30&requireLogin=False&thread.id=2010
09-03-2009 01:55 AM
Hi
Thank you very much for the useful reply.
If i want to read 800h to 805h arbitration id then what will be the Standard Comparator & Standard Mask value ?
Thanxs in advance
09-03-2009 04:09 AM
09-04-2009 06:41 AM
Comparator 11 11 11 11
Mask 00 01 10 11
Frames Received All 01 (1), 11 (3) 10 (2), 11 (3) 11 (3)
Comparator 00 00 00 00
Mask 00 01 10 11
Frames Received All 10 (2) 01 (1) None
Extended
comparators and masks work in exactly the same way. As you can see, it
is possible to use complex combinations of these attributes to
precisely define which frames will be received.
Also suggest you to go through the CAN manual and labview help and check out this forum: http://forums.ni.com/ni/board/message?board.id=30&message.id=2209&requireLogin=False
Kudos are welcome