Model Railroad System  2.2.1
Functions | Variables
TclSocketCANModule

Tcl Channel for CAN Sockets. More...

Functions

SWIGEXPORT int Tclsocketcan_SafeInit (Tcl_Interp *)
 
int SocketCAN (Tcl_Interp *interp, const char *candev)
 Open a CAN Socket. More...
 

Variables

module TclSocketCAN
 
include typemaps i
 

Detailed Description

Tcl Channel for CAN Sockets.

This module defines a Tcl Channel type for CAN Sockets. These are much like TCP Sockets, except the read/write code translates CAN frames to/from GridConnect messages. This module is only available under Linux, since only Linux has kernel support for the CAN socket family (AF_CAN).

Author
Robert Heller <heller@deepsoft.com>

Function Documentation

◆ SocketCAN()

int SocketCAN ( Tcl_Interp *  interp,
const char *  candev 
)

Open a CAN Socket.

This function opens a read/write connection to a CAN socket to the named interface. The result of this function is the name of a Tcl Channel and can be used as an argument to any Tcl Channel function (such as gets, puts, or fileevent).

Parameters
candevThe name of the CAN interface to connect to.
Returns
The name of a Tcl Channel.

◆ Tclsocketcan_SafeInit()

SWIGEXPORT int Tclsocketcan_SafeInit ( Tcl_Interp *  )

Variable Documentation

◆ i

include typemaps i

◆ TclSocketCAN

module TclSocketCAN
Initial value:
{
static const char rcsid[] = "@(#) : $Id$"