02-26-2014 11:53 AM
I am trying to use Labview and RP1210 compliant hardware to connect to a truck J1939 bus and receive messages.
Specifically I am attempting to read data frames using the RP1210_READMESSAGE . am able to configure the hardware and send a message to the J1939 bus. . I think I have not configured something correctly. I can use the RP1210_SENDMESSAGE and see the message I have sent on the bus using CANalyzer When I use the RP1210_READMESSAGE I get the timestamp from a message and the return from the function sends back the correct number of bytes (the number matches the number of bytes I sent out plus four bytes from the timestamp). What I am having trouble with is actually receiving the data. I have had the same type of behavior from two different hardware (Vector CANcase XL and Nexiq USB Link), so I don't think the issue is vendor specific.
Has anyone been able to make the RP1210_RECIEVEMESSAGE function work correctly?
Thanks for any help
02-27-2014 05:16 PM
Hi,
Below I have attached a link to a Community example on our website where there are several examples using RP1210.
https://decibel.ni.com/content/docs/DOC-13164
I hope this helps!
02-28-2014 07:16 AM
Thanks
I have already tried that. The links are the NI RP1210 wraper. The problem I am having is using labview to interface with the RP1210 layer. The RecieveMessage char*fpchAPIMessage this is the output which is a pointer to a cahracter array. In this variable I can receive the timestamp of the message but not the message. The retun showns the correct amount of bytes are aviaable (18 for a 8 byte message) but I can only get the 4 byte timestamp I think I have to dereference this pointer to view the data. I am not sure how to fix this.
02-28-2014 01:11 PM
I figured out the problem The data returned contained 00x0 and it was considered a NULL char. I changed and passed in an array of Unsigned 8 and that solved the issue