PCI-1680U/1682U User Manual
30
Parameters
Return Value
Successful: return non-zero values. Unsuccessful: return zero value. Please call Get-
LastError function.
It will be considered unsuccessful if zero values are returned in the following situa-
tion. Please call GetLastError.
In work mode, drivers can not complete some of the requests, GetLastError will be
called to return ERROR_GEN_FAILURE.
Example
Set baud rate:
DWORD dwReturned;
Command_par_t cmd;
Config_par_t config;
cmd.cmd = CMD_STOP;
BOOL bSuccess = DeviceIoControl (
hDevice,
CAN_IOCTL_COMMAND,
&cmd,
sizeof(Command_par),
NULL,
0,
&dwReturned,
NULL
);
if(!bSuccess)
{
//error
}
config.target = CONF_TIMING;
config.val1 = 1000; //set 1000K
Name Direction
Description
hDevice
Input
Handle of the device which was opened.
dwIoControlCode
Input
Control code, shows the specific operation mode.
lpInBuffer
Input
Start address sent to data area of driver.
nInBufferSize
Input
Byte length sent to data area of driver.
lpOutBuffer
Output
Address of data area which receives driver's return data.
nOutBufferSize
Input
Byte length of data area which receives driver's return data.
lpBytesReturned
Output
Real byte length of data received from driver.
lpOverlapped Input
If CreateFile uses asynchronous open, asynchronous oper-
ation must be supported here. Please refer to MSDN for
detailed instruction to asynchronous open.
*Note In WINDOWS CE,set to NULL.
Summary of Contents for PCI-1680U
Page 10: ...PCI 1680U 1682U User Manual 4 ...
Page 16: ...PCI 1680U 1682U User Manual 10 5 Click Next as the following 6 Click Next as the following ...
Page 22: ...PCI 1680U 1682U User Manual 16 ...
Page 26: ...PCI 1680U 1682U User Manual 20 Figure 3 2 PCI 1682U Silk Screen ...
Page 85: ...79 PCI 1680U 1682U User Manual Chapter 4 Software Requirements WDM CE ...
Page 90: ...PCI 1680U 1682U User Manual 84 4 8 2 2 Receive flow chart ...
Page 91: ...85 PCI 1680U 1682U User Manual Chapter 4 Software Requirements 4 8 2 3 Configure flow chart ...
Page 103: ...97 PCI 1680U 1682U User Manual Chapter 5 Pin Assignments and Wiring ...