PXI

cancel
Showing results for 
Search instead for 
Did you mean: 

NIXNET

Hello Team,

 

I would like to Read and Write the CAN data over NI PXI device. I am using NIXNet drivers. 

 

I have used the following steps

1. Create Input session using nxMode_FrameInStream , set baud rate

2. Create Output session using nxMode_FrameOutStream , set baud rate

 

3. Call Write frame 

g_Status = nxWriteFrame(g_OutputSessionRef,l_MyBuffer,l_MyNumberOfBytesForFrames,10);

 

4. Call read frame function into a buffer.

 

//Read a frame
g_Status = nxReadFrame (g_SessionRef,l_MyBuffer,sizeof(l_MyBuffer),0,&l_NumBytes);

 

When i did this procedure for the First call to Write frame function, 8byte CAN data i am not able to receive any data and l_Numbytes are 0

 

if I did the call to WriteFrame function again, 8byte CAN data, i am now able to receive 8 byte data but it is the response received for the First CAN write function.

 

Could you please let me know what is that wrong in my code?

Please let me know if you need any further information. 

 

Thanks 

Rajeswari.

 

 

 

0 Kudos
Message 1 of 1
(4,329 Views)