Automotive and Embedded Networks

cancel
Showing results for 
Search instead for 
Did you mean: 

use ncWrite to transmit data in VC++

 NCTYPE_CAN_FRAME   Transmit;
 NCTYPE_CAN_DATA Trans; Trans.IsRemote = NC_FALSE;
 Trans.ArbitrationId = 0x05; 
 Trans.DataLength = 8;
 Transmit.Data[0] = 0x55;
 Transmit.Data[1] = 0x55;
 Transmit.Data[2] = 0x55;
 Transmit.Data[3] = 0x55;
 Transmit.Data[4] = 0x55;
 Transmit.Data[5] = 0x55;
 Transmit.Data[6] = 0x55;
 Transmit.Data[7] = 0x55;
 
use the Botton return ----->Write(TxHandle,1,&Transmit);
Why is the waveform is 0x55(7bit)?
use the Botton return ----->Write(TxHandle,2,&Transmit);
Why is the waveform is 0x55(9bit)?
 
 
0 Kudos
Message 1 of 2
(3,917 Views)

Hi r78,

Could you clarify your question and what you would like to accomplish with this code further?  You may consider starting with an example program that National Instruments provides (C:\Program Files\National Instruments\NI-CAN\MS Visual C\Frame API examples) and making adjustments from there... 


Regards,
Anna M.
National Instruments
0 Kudos
Message 2 of 2
(3,900 Views)