LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

NI XNET in LabView: Transmitting source address along with signal

Hi all!

 

Does anyone know a way to transmit a user-determined source address along with a specific signal (J1939)?  I'm outputting a signal from CVI with nxWriteSignalSinglePoint and reading it with CANalyzer, which says that the source address is NULL (254).  Is there a way to set this or would I have to transmit the whole frame (maybe doing the raw bits format)?  Thanks in advance!

0 Kudos
Message 1 of 2
(4,262 Views)

Hey BLowery,

 

Given that this is a more XNET-oriented question, I would recommend asking this type of question on the Embedded Networks forum page rather than the CVI Forum since that's where user dealing with CAN and J1939 reside.

 

Embedded Networks Forum:

http://forums.ni.com/t5/Automotive-and-Embedded-Networks/bd-p/30

 

However, if you are wanting to be able to specify the source address manually in the 29-bit extended arbitration ID, as J1939 requires, it wouldn't be too hard, but you can't do it with Signal session. A Signal session uses the CAN database file to determine the ID and parameters of the frame to be sent automatically, and you simply provide the signal data. To be able to edit the ID yourself, a Frame Stream session that doesn't rely on a database would be required, since it would allow you to provide the ID manually.

 

I recommend taking a look a this white paper, which shows how to use XNET with the J1939 standard. In the sample code that they provide, there is an example using a Frame Out Stream session which edits the ID manually based on the user's input.

 

http://www.ni.com/example/31215/en/

 

Regards,

 

Ryan

 

Ryan P.
CLA
Message 2 of 2
(4,230 Views)