manualshive.com logo in svg
background image

 

 

 

 

Titan Electronics Inc. 

Web: 

www.titan.tw

 

 

USB-2CAN-M/USB-CAN-SI-M 

USER’S MANUAL

 

2019 Edition 

Содержание USB-2CAN-M

Страница 1: ...Titan Electronics Inc Web www titan tw USB 2CAN M USB CAN SI M USER S MANUAL 2019 Edition ...

Страница 2: ...ibited Disclaimer TITAN Electronics Inc provides this document and computer programs as is without warranty of any kind either expressed or implied including but not limited to its particular purpose TITAN Electronics Inc reserves the right to make improvements and changes to this user manual or to the products or the computer programs described in this manual at any time Information provided in t...

Страница 3: ...roperties COM Port Number 15 7 4 Linux Driver Installation SocketCAN 16 7 4 1 Using SocketCAN with USB CAN 16 8 FUNCTION DESCRIPTION 17 8 1 LED Indicators 17 8 2 ASCII Command Set 18 8 3 Command list 19 8 3 1 Opening the CAN Bus Channel 20 8 3 2 Closing the CAN Bus Channel 20 8 3 3 Setting CAN Bitrate Standard 21 8 3 4 Setting CAN Bitrate Advanced 22 8 3 5 Transmitting a Standard CAN Frame 23 8 3 ...

Страница 4: ... for selecting and configuring the USB to CAN adapter 41 9 4 2 Receiving CAN frames 43 9 4 3 Sending CAN frames 43 9 4 4 Assistant features 45 9 5 CANopen 49 9 5 1 How to get CanFestival 49 9 5 2 Linux Compilation and installation 49 9 5 4 Windows Compilation 50 9 5 5 Compilation with Visual Studio 50 9 6 APPLICATION PROGRAMMING INTERFACE 53 9 6 1 CAN_Open 54 9 6 2 CAN_Close 56 9 6 3 CAN_Write 57 ...

Страница 5: ...4 9 6 13 Using the API in Python 70 9 6 14 Using the API in LabVIEW 71 ...

Страница 6: ...it very flexible in handling small burst of CAN frames at a high speed Upon plugging the USB 2CAN M USB 2CAN SI M into the USB port the adapter is automatically detected and installed The USB CAN bus adapter provides instant connectivity to CAN bus devices The USB 2CAN M USB 2CAN SI M provides an industrial solution for applications of CAN bus multi drop communications over short and long distance...

Страница 7: ...2 bytes transmit FIFO buffer for high speed data throughput Supports CAN 2 0A and CAN 2 0B protocols Supported CAN modes o Standard mode normal operation on CAN bus o Listen mode passive receiving of CAN frames o Echo mode transmitter also receives sent frames for testing purposes Easy plug and play installation and CAN bus device connection USB CAN adapter can be controlled over serial port using...

Страница 8: ...7 3 DIAGRAM OF USB 2CAN M USB 2CAN SI M 3 1 BLOCK DIAGRAM 3 1 1 USB 2CAN M Block Diagram 3 1 2 USB 2CAN SI M Block Diagram ...

Страница 9: ... system USB 2CAN M Number of Ports Two Connector DB9 male connector 5 pin terminal block CAN Bus Speed 5kbits to 1Mbits for CAN data transmit receive Signals CAN_H CAN_L CAN_GND CAN_V CAN Bus Controller Bosch C_CAN module LED CAN bus data activity CAN bus error CAN Bus Mode Standard mode normal operation on CAN bus Listen mode passive receiving of CAN frames Echo mode transmitter also receives sen...

Страница 10: ...for testing purposes Protection 16 KV ESD protection for CAN signals 2500V galvanic isolation on CAN bus Software Features API Library Supports C C C VB NET and LabVIEW Utility On board firmware update utility OS Driver Support Windows XP to Windows 10 OS Windows Server 2003 to 2012 R2 Monitoring Tools Supported by CANHacker Titan CAN test program Power Requirement Power Input Power supplied via U...

Страница 11: ...10 Environment Operating Temperature 0 C to 60 C 32 F to 140 F Storage Temperature 20 C to 75 C 4 F to 167 F Humidity 5 to 95 RH Safety Approvals CE FCC ...

Страница 12: ...Signal ground 4 Reserved 5 Reserved 6 CAN_GND Signal ground 7 CAN_H CAN_H bus line dominant level is high 8 Reserved 9 CAN_V Provides DC 5V 100mA power optional 5 2 Enabling the 5V 100mA power for external devices Inside the unit there is a 2 pin header block JP5 JP8 which are jumpers for enabling 5V 100mA power for external devices JP3 Jumper Function ON Enable DB9 pins 1 and 9 to provide a 5V 10...

Страница 13: ...CAN bus termination resistors A CAN bus network requires 120Ω termination resistors at each end Generally this must be done in the cabling Since this depends on the installation of connections please check your CAN bus cable specification for proper impedance matching ...

Страница 14: ...u will find a new USB Serial Port COMX under Ports COM LPT in device manager You will need to execute the command CAN_BAUDRATE_SET COMX to set the USB to CAN adapter to work in high speed 3Mbits After executing the command please disconnect the USB to CAN adapter from the system for about 5 seconds and connect it again refer to page 31 Note The set baud rate program CAN_BAUDRATE_SET exe must be ex...

Страница 15: ...matically via Internet Windows XP Vista Server 2003 and 2008 Connect your computer to Internet and plug USB CAN adapter to the USB port when asked to install the drivers allow your computer to search the Internet to load and install the drivers automatically 7 2 Verifying the Installation You can verify the installation by looking under device manager Start Settings Control Panel System Properties...

Страница 16: ...to a COM port number that is already in use To change the virtual COM port properties 1 Select the USB Serial Port COMX 2 Click Properties 3 Select Port Setting and Advanced 4 Click the drop down arrow on COM Port Number and scroll to the required COM port 5 Select OK 6 Return to the Device Manager Screen You will see that the USB Serial Port installation has been changed to the new COM Port Numbe...

Страница 17: ...inux kernel modules You can manually load these modules with the following command sudo modprobe can sudo modprobe vcan sudo modprobe slcan 7 4 1 Using SocketCAN with USB CAN To use USB CAN with SocketCAN you have to establish a link between the drivers and the hardware This is done with the following command sudo slcand o c s8 dev ttyUSB0 can0 The s parameter allow to configure different interfac...

Страница 18: ...alized the USB to CAN adapter flashes the green and red LED four times to indicate that the USB CAN adapter has been initialized B CAN bus channel open close When CAN bus channel opens the green LED will turn on to indicate that the CAN bus channel is open When CAN bus channel closes the green LED will turn off to indicate that the CAN bus channel is closed C CAN Bus Data Activity When CAN data fr...

Страница 19: ...this serial port User can send receive commands from any simple serial terminal program Example Set bitrate to 500Kbps open CAN channel send CAN frame ID 002h DLC 3 Data 11 22 33 close CAN Command Response Function S6 CR CR Set bitrate of USB CAN adapter to 500Kbps O CR CR Open CAN channel t0023112233 CR z CR Send CAN message ID 002h DLC 3 Data 11 22 33 C CR CR Close CAN channel ...

Страница 20: ...l mode L Open the channel in Listen Only mode Y Open the channel in Loopback mode C Close CAN Channel S Set standard CAN bitrate s Set non standard CAN bitrate t Transmit a standard frame T Transmit an extended frame r Transmit a standard remote request frame R Transmit an extended remote request frame Z Set timestamp on off m Set acceptance mask M Set acceptance filter F Read status flag V Check ...

Страница 21: ...in a loop back mode in which the USB to CAN adapter will also receive the frames that it sends Before you use one of the commands you should set a bitrate with the commands S or s Command Response Function O CR CR Open the channel in Normal mode L CR CR Open the channel in Listen Only mode Y CR CR Open the channel in Loopback mode 8 3 2 Closing the CAN Bus Channel The CAN bus channel will be close...

Страница 22: ...to 10K S1 CR CR Set the CAN bus bitrate to 20K S2 CR CR Set the CAN bus bitrate to 50K S3 CR CR Set the CAN bus bitrate to 100K S4 CR CR Set the CAN bus bitrate to 125K S5 CR CR Set the CAN bus bitrate to 250K S6 CR CR Set the CAN bus bitrate to 500K S7 CR CR Set the CAN bus bitrate to 800K S8 CR CR Set the CAN bus bitrate to 1M Example S6 CR will be set USB CAN adapter to 500K bps CAN Bitrates No...

Страница 23: ...a CAN Bitrate Calculator program to calculate the value of CAN bitrate registers for setting non standard bitrates Follow these steps to calculate and set non standard bitrates for the USB to CAN adapter 1 Open the CAN Bitrate Calculator program 2 Enter CAN Bitrate 150 for 150Kbps CAN Bitrate in the field Desired bitrate 3 Click Calculate to calculate the value of CAN bitrate registers 4 Remember ...

Страница 24: ...t be equal to the data length field Example t00231199FF CR will send a standard CAN frame with ID 002h DLC 3 Data 11 99 FF 8 3 6 Transmitting a Standard Remote Request CAN Frame Transmitting a standard remote request CAN frame ID 11 bit over a CAN bus can be done with the command riiil CR The return value will be z CR or the normal error byte BELL The command is only available when the CAN bus cha...

Страница 25: ...the data length field Example T1FFFFFFF3112233 CR will send an extended CAN frame with ID 1FFFFFFFh DLC 3 data 11 22 33 8 3 8 Transmitting an Extended Remote Request CAN Frame Transmitting an extended remote request CAN frame ID 29 bit over a CAN bus can be done with the command Riiiiiiiil CR The return value will be Z CR or the normal error byte BELL The command is only available when the CAN bus...

Страница 26: ...e timestamp functionality of received frames ON or OFF This command is only available when the CAN channel is closed Command Response Function Z1 CR CR Set the timestamp functionality on received frames ON Z0 CR CR Set the timestamp functionality on received frames OFF ...

Страница 27: ...and is executed the channel will update the setting and return to the open state Command Response Function miii CR CR Set acceptance mask for standard CAN frame 11 bit identifier miiiiiiii CR CR Set acceptance mask for extended CAN frame 29 bit identifier iii standard 11 bit CAN mask 0x000 through 0x7FF iiiiiiii extended 29 bit CAN mask 0x00000000 through 0x1FFFFFFF A value of 0 in a bit location ...

Страница 28: ...ple if the channel is open when this command is executed the channel will update the setting and return to the open state Command Response Function Miii CR CR Set acceptance code for standard CAN frame 11 bit identifier Miiiiiiii CR CR Set acceptance code for extended CAN frame 29 bit identifier iii standard 11 bit CAN mask 0x000 through 0x7FF iiiiiiii extended 29 bit CAN mask 0x00000000 through 0...

Страница 29: ...nowledged by another node Error Code 4 1 0 0 Bit 1 error during the transmission of a message with the exception of the arbitration field the device wanted to send a recessive level bit of logical value 1 but the monitored bus value was dominant Error Code 5 1 0 1 Bit 0 error Bit 1 error during the transmission of a message or acknowledged bit or active error flag or overload flag the device wante...

Страница 30: ... been successfully received since this bit was last reset by CPU Bit 5 Error Passive Read only 1 The CAN core is in the error passive state as defined in the CAN specification 0 The CAN core is in the error active Bit 6 Error Warning Status Read only 1 At least one of the error counters in the EML Error Management Logic has reached the error warning limit of 96 Both error counters are below the er...

Страница 31: ...rmatted like this VXXXX CR 8 3 14 Getting Serial Number The command N CR will retrieve the serial number of the USB CAN adapter Command Response Function N CR TXXXXXXXX CR Get the serial number of the USB CAN adapter This command is always available and will return the decimal serial number like this TXXXXXXX CR 8 3 15 Resetting the USB CAN adapter The command RST CR will reset the USB CAN adapter...

Страница 32: ... rate program CAN_BAUDRATE_SET exe must be executed under command prompt with administrative privileges Following is set baud rate program command CAN_BAUDRATE_SET COM PORT Example CAN_BAUDRATE_SET COM7 COM7 the USB to CAN adapter installed as USB Serial Port COMX You can check the port number under Device Manager After setting the baud rate successfully you will find following message under Comma...

Страница 33: ...ative privileges Following is the firmware upgrade command can_fw_update COM PORT FIRMWARE FILE Example can_fw_update COM7 USBCAN_FW_V05 bin COM7 the USB to CAN adapter installed as USB Serial Port COMX You can check the port number under Device Manager USBCAN_FW_V5 bin new firmware file binary file of USB to CAN adapter After executing the firmware upgrade successfully you will find following mes...

Страница 34: ...itting receiving CAN frames The CANHacker software has a friendly interface and is easy to use Through the software user can easily test and analyze the CAN frames Following shows its main panel The following sections will briefly introduce the necessary steps on how to use the software ...

Страница 35: ...TS handshake function 4 Check Time Stamp to enable timestamp function 5 Select CAN Baudrate for the CAN bus operating speed 6 Finally click OK to finish the settings and return to the main panel You may connect the USB to CAN adapter after configuration Click Connect as shown in the figure to start the CANHacker software operation When USB to CAN adapter successfully connects you will find the mes...

Страница 36: ...35 Connected to XXX kbits s firmware version VXXXX and operation mode at the bottom of the main panel ...

Страница 37: ...an set the following parameters on the bottom of the main panel for CAN data transmission Select transmit an extended CAN Frame 29 bits ID or a standard CAN frame 11 bits ID Check 29 Bit Id to transmit an extended CAN Frame 29 bits ID and uncheck 29 Bit Id to transmit a standard CAN frame 11 bits ID Select remote request frame mode or transmit CAN frame mode Check RTR for a remote request frame mo...

Страница 38: ...odic mode is selected you can enter Period ms to send CAN frames message repeatedly enter 500 to send CAN messages every 500ms To send a single CAN frame message click Single Shot Click Send All to send CAN frames message repeatedly To stop sending CAN frame messages click Stop All ...

Страница 39: ... in the figure below Saving data to file or loading data from file Select File option to save Rx List Trace Tx List Command List and Load Trace Tx List Command List Click Disconnect to stop CANHacker Click Reset to renew the received CAN frame messages and reset the transmission received count ...

Страница 40: ...39 Select Filter to set mask filter and range filter Select Tracer or Monitor to trace or monitor the CAN frame messages ...

Страница 41: ... and transmitting receiving CAN frames The Titan CAN test program is an easy to use software Through the software users can easily test and analyze the CAN frames Following shows its main panel The following section will briefly introduce the necessary steps on how to use the Titan CAN test program ...

Страница 42: ...ly to open the CAN bus adapter in loopback or listen only operation mode otherwise the CAN bus adapter will open in normal operation mode 6 Finally click OK to finish the settings and return to the main panel You may connect the USB to CAN adapter after configuration Click Connect as shown in the figure to start the Titan CAN test program operation When USB to CAN adapter successfully connects you...

Страница 43: ...42 ...

Страница 44: ...CAN node you can set the following parameters on the bottom of the main panel for CAN data transmission Select transmit an extended CAN frame 29 bits ID or a standard CAN frame 11 bits ID Check Extend to transmit an extended CAN Frame 29 bits ID and uncheck Extend to transmit a standard CAN frame 11 bits ID Select remote request frame mode or transmit CAN frame mode Check RTR for a remote request ...

Страница 45: ...CAN frame message click Single Shot Click Send All to send CAN frames message repeatedly To stop sending CAN frame messages click Stop All To add a new send CAN frame message click Add to add new send CAN frame message and click Copy to copy a send CAN frame message repeatedly To delete a send CAN frame message click Delete to delete send CAN frame message ...

Страница 46: ...y assistant features included in Titan CAN test program as shown in the figure below Select File option to save Rx List Tx List and Load Tx List Click Disconnect to stop Titan CAN test program Select Filter to set mask filter and range filter ...

Страница 47: ...nel Note Before you set the Mask Filter function you need to disconnect the USB adapter After setting the value of Mask Code connect the USB adapter again to enable the Mask Filter function because the Mask Filter function is only available if the CAN adapter is initiated and not opened Mask Filter example After setting Mask to 1FFFFFF0 and Code to 12345678 CAN message frames of the range 0x123456...

Страница 48: ...ple After setting Start ID to 00000000 and End ID to 01FFFFFF The CAN message frames of the range 0x00000000 through 0x01FFFFFF will be passed and all other CAN IDs will be blocked The Range Filter can also set Discrete IDs to block a unique CAN ID Discrete IDs Filter example After setting Start ID to 00000000 End ID to 01FFFFFF and setting Discrete IDs to 01000000 The CAN ID range 0x00000000 thro...

Страница 49: ...48 Click Reset option to renew the received CAN frame message and reset the transmitted received count Click About option to show the version information of Titan CAN test program ...

Страница 50: ...http www canfestival org CanFestival focuses on providing an ANSI C platform independent CANopen stack that can be implemented as master or slave nodes on PCs Real time IPCs and Microcontrollers For detailed information about using CanFestival in your project see the The CanFestival CANopen stack manual 9 5 1 How to get CanFestival You can get the CanFestival source code from repository Then get T...

Страница 51: ...val source code into your Cygwin home Then configure CanFestival cd CanFestival configure can titan make 9 5 5 Compilation with Visual Studio You can either load independent vcproj project files along your own pro jects in your own solution or load the provided CanFestival 3 vc8 sln solution files directly Build CanFestival 3 project first The examples directory contains some test program you can ...

Страница 52: ...e to the directory where examples were extracted to and execute TestMasterSlave s COM3 S 125K M none l canfestival_titan dll in the first command window and TestMasterSlave m COM4 M 125K S none l canfestival_titan dll in the second Following pictures shows the output messages of both nodes Master Slave ...

Страница 53: ...ples were extracted to and execute export LD_LIBRARY_PATH TestMasterSlave s dev ttyUSB0 S 125K M none l libcanfestival_can_titan so in the first terminal window and export LD_LIBRARY_PATH TestMasterSlave m dev ttyUSB1 M 125K S none libcanfestival_can_titan so in the second Following pictures shows the output messages of both nodes Master Slave ...

Страница 54: ...s It will make it much easier for users to build their own CAN controlling software with these functions than to implement their application command by command on the ASCII protocol Users can use Windows based API for use with high level languages Please refer to the following website for our GUI sample codes and updates https www titan tw drivers can api html ...

Страница 55: ...0Kbps 50 50Kbps 100 100Kbps 125 125Kbps 250 250Kbps 500 500Kbps 800 800Kbps 1000 1000Kbps XXXXXXXXX non standard bitrate o Example 50 1000 000000150 acceptance_code o Type String o Used in conjunction with the acceptance mask to filter CAN messages Set to 00000000 for NULL to allow all messages Also referred to as acceptance filter in other parts of the manual o Format XXXXXXXX o Example 00000700 ...

Страница 56: ...sten only the device will passively receive CAN messages 2 Loopback the device will also receive messages it transmits o Example 2 Return value o Type Integer o Handle to the device o Result 0 CAN_Open is successful 1 error communicating with COM port 2 error in opening channel COM port may be already in use 3 error in parameter settings o Example 2508 Sample Command CAN_Open COM3 50 00000000 0000...

Страница 57: ...nel to be closed o Format A numeric value provided by the return value of CAN_Open o Example 2508 Return value o Type Integer o Code indicating result of CAN_Close o Result 1 CAN_Close is successful 1 error communicating with COM port 4 error CAN channel is not open Sample Command CAN_Close 2508 Closes device connected to channel with the handle 2508 ...

Страница 58: ...ucture o The standard structure of CAN frame messages o Format Name of an instance of the CAN_MSG structure o Example myCANMsg Return value o Type Integer o Code indicating result of CAN_Write o Result 1 CAN_Write is successful 1 error communicating with COM port 4 error CAN channel is not open Sample Command CAN_Write 2508 myCANMsg Writes the message contained in myCANMsg to device connected to c...

Страница 59: ...dard structure of CAN frame messages o Format Name of an instance of the CAN_MSG structure o Example myCANMsg Return value o Type Integer o Code indicating result of CAN_Read o Result 1 CAN_Read is successful 1 error communicating with COM port 4 error CAN channel is not open 5 error there are no messages Sample Command CAN_Read 2508 myCANMsg Reads the message from device connected to channel with...

Страница 60: ... buffers are to be cleared o Format A numeric value provided by the return value of CAN_Open o Example 2508 Return value o Type Integer o Code indicating result of CAN_Flush o Result 1 CAN_Flush is successful 1 error communicating with COM port 4 error CAN channel is not open Sample Command CAN_Flush 2508 Clears the buffers of device connected to channel with the handle 2508 ...

Страница 61: ...it 2 1 0 0 0 0 no error 0 0 1 stuff error 0 1 0 form error 0 1 1 ACK error 1 0 0 Bit1Error 1 0 1 Bit0Error 1 1 0 CRCError 1 1 1 unused Bit 3 1 message successfully transmitted 0 no message has been transmitted Bit 4 1 message successfully received 0 no message has been received Bit 5 1 CAN core is in error passive state 0 CAN core is in error active state Bit 6 1 at least one error counter in EML ...

Страница 62: ...61 Sample Command CAN_Status 2508 Checks the status bits of device connected to channel with the handle 2508 ...

Страница 63: ...the return value of CAN_Open o Example 2508 buf o Type Character array string o Information about the firmware version will be stored into this array o Format Name of a character array o Example myVersion Return value o Type Integer o Code indicating result of CAN_Version o Result 1 CAN_Version is successful 1 error communicating with COM port 4 error CAN channel is not open Sample Command CAN_Ver...

Страница 64: ... Example 11 o Flags Type Byte Determines the message ID type and timestamp settings Format 1 timestamp off standard 2 timestamp off extended 9 timestamp on standard 10 timestamp on extended Example 9 o Timestamp Type Unsigned Short Value of the timestamp Format No input from the user is required Example 0 Sample Message o With a CAN_MSG structure instance declared as myCANMSG myCANMsg ID 1FF myCAN...

Страница 65: ...4 SendMSG Data 4 0x55 SendMSG Data 5 0x66 SendMSG Data 6 0x77 SendMSG Data 7 0x88 Handle CAN_Open ComPort szBitrate acceptance_code acceptance_mask flags Mode printf handle d n Handle if Handle 0 return 0 memset version 0 sizeof char 10 Status CAN_Flush Handle Status CAN_Version Handle version if Status CAN_ERR_OK printf Version s n version Status CAN_Write Handle SendMSG if Status CAN_ERR_OK prin...

Страница 66: ...65 break Status CAN_Close Handle printf Test finish n return 0 ...

Страница 67: ...CAN_Write and CAN_Read functions if needed public struct CAN_MSG public UInt32 Id public byte Size MarshalAs UnmanagedType ByValArray SizeConst 8 public byte Data public byte Flags public UInt16 TimeStamp The keyword MarshalAs is used for all structure members to ensure that the structure size corresponds to what the DLL expects 4 In order to communicate with the channel with other functions after...

Страница 68: ...s Public Structure CAN_MSG MarshalAs UnmanagedType U4 Public Id As UInteger MarshalAs UnmanagedType U1 Public Size As Byte MarshalAs UnmanagedType ByValArray SizeConst 8 ArraySubType UnmanagedType U1 Public Data As Byte MarshalAs UnmanagedType U1 Public Flags As Byte MarshalAs UnmanagedType U2 Public Timestamp As UShort End Structure The keyword MarshalAs is used for all structure members to ensur...

Страница 69: ...ou need to create a variable to store the handle value Private myHandle As Integer myHandle CAN_Open COM3 50 00000000 00000000 1 2 10 This concludes the basic setup process of using the DLL in Visual Basic NET Imported functions can then be easily called from the DLL with the parameters created above ...

Страница 70: ...cture for the CAN_Write and CAN_Read functions if needed Private Type CAN_MSG Id As Long Size As Byte Data 0 To 7 As Byte Flags As Byte Timestamp As Integer End Type To use the CAN_MSG structure you will need to create an instance of the structure you just defined Private myCANMSG As CAN_MSG 4 In order to communicate with the channel with other functions after opening it with CAN_Open you need to ...

Страница 71: ...ushort class CAN_MSG Structure _fields_ Id c_uint Size c_ubyte Data c_ubyte 8 Flags c_ubyte Timestamp c_ushort To use the CAN_MSG structure you will need to create an instance of the structure you just defined myCANMSG CAN_MSG 9 In order to communicate with the channel with other functions after opening it with CAN_Open you need to create a variable to store the handle value myHandle DLL CAN_Open ...

Страница 72: ...operation For example the user can choose from Normal Listen Only or Loopback mode to suit their purposes Once the channel is opened the user can use either Write Once or the Write Repeatedly button to send messages as configured in the fields Messages received will appear on the fields on the rightmost side if they are available All subVI icons have been customized with the terminals wired to be ...

Страница 73: ...ages To be used with the acceptance mask o acceptance_mask Used for filtering CAN messages To be used with the acceptance code o Flags Whether or not the timestamp function should be enabled o Mode The mode at which the device should operate at with choices being Normal Listen Only and Loopback Output o Return Handle to the device A positive value indicates success in opening the channel while 2 r...

Страница 74: ...CAN channel with the specified handle Input Handle The handle of the CAN channel which is to be closed Output Return A positive value indicates success in closing the channel whereas a negative value indicates an error in closing the channel ...

Страница 75: ...s to be sent to Id Message ID Size Frame size 0 8 Data 8 Data bytes 0 7 Flags 1 standard 2 extended 9 standard timestamp 10 extended timestamp Timestamp Timestamp ms Output Return A positive value indicates success in sending the message whereas a negative value indicates an error in sending the message with 4 representing that the channel is not open ...

Страница 76: ...rn A positive value indicates success in reading the message whereas a negative value indicates an error in reading the message with 4 representing that the channel is not open and 5 representing that there is no message to be read Id Message ID Size Frame size 0 8 Data 8 Data bytes 0 7 Flags 1 standard 2 extended 9 standard timestamp 10 extended timestamp Timestamp Timestamp ms ...

Отзывы: