![]() |
Definitions for the J1587lib API. More...
#include <windows.h>#include <pshpack1.h>#include <poppack.h>Go to the source code of this file.
Data Structures |
Typedefs | |
| typedef int | J1587Handle |
Enumerations | |
| enum | J1587Status { j1587OK = 0, j1587ERR_NOMSG = -1, j1587ERR_NOTRUNNING = -3, j1587ERR_RUNNING = -4, j1587ERR_NORMALONLY = -5, j1587ERR_NODEONLY = -6, j1587ERR_PARAM = -7, j1587ERR_NOTFOUND = -8, j1587ERR_NOMEM = -9, j1587ERR_NOCHANNELS = -10, j1587ERR_TIMEOUT = -11, j1587ERR_NOTINITIALIZED = -12, j1587ERR_NOHANDLES = -13, j1587ERR_INVHANDLE = -14, j1587ERR_CANERROR = -15, j1587ERR_ERRRESP = -16, j1587ERR_WRONGRESP = -17, j1587ERR_DRIVER = -18, j1587ERR_DRIVERFAILED = -19, j1587ERR_NOCARD = -20, j1587ERR_LICENSE = -21, j1587ERR_INTERNAL = -22, j1587ERR_NO_ACCESS = -23, j1587ERR_VERSION = -24 } |
Functions | |
| J1587Status | j1587Close (J1587Handle h) |
| J1587Status | j1587GetFirmwareVersion (J1587Handle h, unsigned char *bootVerMajor, unsigned char *bootVerMinor, unsigned char *bootVerBuild, unsigned char *appVerMajor, unsigned char *appVerMinor, unsigned char *appVerBuild) |
| J1587Status | j1587SetBitrate (J1587Handle h, unsigned int bps) |
| J1587Status | j1587BusOn (J1587Handle h) |
| J1587Status | j1587BusOff (J1587Handle h) |
| unsigned long | j1587ReadTimer (J1587Handle h) |
| J1587Status | j1587WriteMessageWait (J1587Handle h, const void *msg, unsigned int length, unsigned int priority, DWORD timeout) |
| J1587Status | j1587ReadMessageWait (J1587Handle h, void *msg, unsigned int *msgLength, J1587MessageInfo *msgInfo, DWORD timeout) |
| J1587Status | j1587WriteSync (J1587Handle h, J1587MessageInfo *msgInfo, DWORD timeout) |
| J1587Status | j1587Configure (J1587Handle h, unsigned int flags) |
| J1587Status | j1587GetCanHandle (J1587Handle h, unsigned int *canHandle) |
J1587MessageInfo | |
| void | j1587InitializeLibrary (void) |
| J1587Handle | j1587OpenChannel (int channel, int flags) |
Definitions for the J1587lib API.
| struct J1587MessageInfo |
| Data Fields | ||
|---|---|---|
| union J1587MessageInfo | __unnamed__ | |
| unsigned short | bitrate |
Bitrate of the message in bits per second. Range [1000 .. 60000] (plus some margin) |
| unsigned char | flags |
Miscellaneous flags |
| unsigned char | frameDelay |
Frame delay in bit times (up to 255).
|
| unsigned long | frameLength |
Total frame length in microseconds; from the first start bit to the end of the checksum. |
| unsigned short | reserved |
Reserved |
| unsigned long | timestamp |
Timestamp in ms of the reception/transmission completion of the checksum. Uses the canlib CAN timer. |
| unsigned char | version |
To enable future extensions of this structure (see J1587LIB_VERSION). |
| union J1587MessageInfo.__unnamed__ |
| #define canTRANSCEIVER_TYPE_LINX_J1708 66 |
| #define canTRANSCEIVER_TYPE_LINX_K 68 |
| #define canTRANSCEIVER_TYPE_LINX_LIN 64 |
| #define canTRANSCEIVER_TYPE_LINX_LS 72 |
| #define canTRANSCEIVER_TYPE_LINX_SWC 70 |
| #define EEPROM_OP_MODE_J1587_NODE 0x02 |
| #define EEPROM_OP_MODE_J1587_NORMAL 0x01 |
| #define EEPROM_OP_MODE_NONE 0x00 |
| #define J1587_INTER_CHAR_DELAY_MASK 0x0f |
Inter character delay mask.
| #define J1587_NODE 2 |
| #define J1587_NORMAL 1 |
| #define J1587_READ 4 |
| #define J1587_REPORT_BAD_CHECKSUM 0x10 |
Default off.
| #define J1587_REPORT_CHAR_DELAY 0x40 |
Default off.
| #define J1587_REPORT_FRAME_DELAY 0x20 |
Default off.
| #define J1587_WRITE 8 |
| #define j1587FLAG_BYTEDELAY 0x20 |
| #define j1587FLAG_CHECKSUM 0x80 |
| #define j1587FLAG_FRAMEDELAY 0x40 |
| #define j1587FLAG_OVERRUN 0x08 |
| #define j1587FLAG_STOPBIT 0x10 |
| #define j1587INVALID_HANDLE ((J1587Handle)(-1)) |
Invalid J1587 handle
| #define J1587LIB_VERSION 1 |
J1587 library version definition
| typedef int J1587Handle |
J1587 handle