Cangeterrorcode() - ADLINK Technology NuCOM PCI-7841 User Manual

Dual-port isolated can interface card
Table of Contents

Advertisement

See Also
Usage
#include "pci7841.h
int handle = CanOpenDriver(0, 0);//open the port
0 of card 0
....
CanClearTxBuffer(handle);
CanCloseDriver(handle);

CanGetErrorCode()

Purpose
Prototype
BYTE CanGetErrorCode(int handle)
Parameters
Return Value
Bit Symbol
7 ERRC1 Error Code 1
6 ERRC0 Error Code 0
5
DIR
4
SEG4
Segment 4
3
SEG3
Segment 3
2
SEG2
Segment 2
1
SEG1
Segment 1
0
SEG0
Segment 0
Function Reference
un-send message would be stored in the
memory of the driver. The sequence of out-
going message is the FIRST-IN-FIRST-
OUT. According this algorithm, if your pro-
gram need to send an emergency data, you
can clear the transmit buffer and send it
again.
CanRcvMsg()
C/C++
Get the Error Code
C/C++
handle : handle retrieve from CanOpen-
Driver()
error code
Return error code is an 8-bit data
Name
Value
1
Direction
0
Function
Rx error occurred during reception
Tx error occurred during ransmission
29

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the NuCOM PCI-7841 and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Nucom cpci-7841Nucom pm-7841

Table of Contents