Skip to main content
Open topic with navigation CAPL Functions » TCP/IP CAPL Functions

TCP/IP CAPL Functions

Valid for: CANoe DE • CANoe4SW DE The TCP/IP API provides access to TCP/IP networking features. It is implemented on top of the native Winsock 2 API of the Windows operating system. The API falls into the following categories. These CAPL functions are supported by Windows and Linux. The functionality under Linux has not been fully tested yet. ON THIS PAGE:

IP API

The IP API consists of general functions for network information retrieval such as querying for installed network interface cards (NIC), IP addresses, address conversion functions, error handling, and so on. In addition, the IP API has some special functions for socket manipulations such as setting socket options or binding.

Functions

The IP API Supports the Following CAPL Callbacks:

IPsec API

Functions

The IPsec API Supports the Following CAPL Callbacks:

UDP API

The UDP API is used for UDP communications. It provides a high-level interface for implementing connectionless, datagram-oriented communications.

Functions

  • UdpClose: Closes the UDP socket.
  • UdpConnect: Connects a UDP socket to the given remote address.
  • UdpOpen: Creates a UDP socket for use in connectionless, datagram-oriented communications.
  • UdpReceiveFrom: Receives data into a specified buffer.
  • UdpSend: Sends on a connected UDP socket.
  • UdpSendTo: Sends data to a specified location.

The UDP API Supports the Following CAPL Callbacks:

  • OnUdpReceiveFrom: It is called when an asynchronous receive operation on a UDP socket completes.
  • OnUdpSendTo: It is called when an asynchronous send operation on a UDP socket completes.

TCP API

Functions

  • TcpAbort: Closes the TCP socket immediately and sends a RST. The socket is no longer valid.
  • TcpAccept: Accepts an incoming connection request on a specified socket resulting in a new socket.
  • TcpClose: Closes the TCP socket.
  • TcpConnect: Establishes a connection with a specified location.
  • TCPGetRemoteAddress: Retrieves the remote address of the specified socket.
  • TCPGetRemoteAddressAsString: Retrieves the remote address of the specified socket in Internet standard dotted-decimal format.
  • TcpGetRemoteEndpoint: Retrieves the remote endpoint of the specified connected socket.
  • TcpListen: Causes the socket to listen for incoming connection requests.
  • TcpOpen: Creates a TCP socket for use in connection-based, message-oriented communications.
  • TcpReceive: Receives data into a specified buffer.
  • TcpSend: Sends data on a specified socket.
  • TcpShutdown: Disables send operations on a specified socket.

The TCP API Supports the Following CAPL Callbacks:

  • OnTcpClose: It is called when a TCP socket receives a close notification.
  • OnTcpConnect: It is called when an asynchronous connection operation completes.
  • OnTcpListen: It is called when a connection request for a specified socket is received.
  • OnTcpReceive: It is called when an asynchronous receive operation on a TCP socket completes.
  • OnTcpSend: It is called when an asynchronous send operation on a TCP socket completes.
Winsock 2 Error CodesTechnical DetailsSocket Options