SLIP network device

SLIP network device over UART. More...

Detailed Description

SLIP network device over UART.

See also
RFC 1055

Files

file  slipdev.h
 SLIP device definitions.
 
file  slipdev_internal.h
 
file  slipdev_params.h
 Default configuration for the SLIP device driver.
 

Data Structures

struct  slipdev_params_t
 Configuration parameters for a slipdev. More...
 
struct  slipdev_t
 Device descriptor for slipdev. More...
 

Macros

#define SLIPDEV_BUFSIZE   (2048U)
 UART buffer size used for TX and RX buffers. More...
 

Functions

void slipdev_setup (slipdev_t *dev, const slipdev_params_t *params)
 Setup a slipdev device state. More...
 

Device state definitions

enum  { SLIPDEV_STATE_NONE = 0, SLIPDEV_STATE_NET, SLIPDEV_STATE_STDIN }
 

Macro Definition Documentation

◆ SLIPDEV_BUFSIZE

#define SLIPDEV_BUFSIZE   (2048U)

UART buffer size used for TX and RX buffers.

Reduce this value if your expected traffic does not include full IPv6 MTU sized packets.

Precondition
Needs to be power of two and <= INT_MAX

Definition at line 44 of file slipdev.h.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
SLIPDEV_STATE_NONE 

Device is in no mode (currently did not receiving any data frame)

SLIPDEV_STATE_NET 

Device writes handles data as network device.

SLIPDEV_STATE_STDIN 

Device writes received data to stdin.

Definition at line 52 of file slipdev.h.

Function Documentation

◆ slipdev_setup()

void slipdev_setup ( slipdev_t dev,
const slipdev_params_t params 
)

Setup a slipdev device state.

Parameters
[in]devdevice descriptor
[in]paramsparameters for device initialization