NetBurner 3.5.0
PDF Version
 
Low Level Processing (NetDoRx)

Callback functions to add custom Ethenet handlers and pass Ethernet frames in the bottom of the TCP/IP stack. More...

Typedefs

typedef int(* netDoRXFunc) (PoolPtr, uint16_t, int)
 Typedef interface for all network rx processing functions.
 

Functions

netDoRXFunc SetCustomNetDoRX (netDoRXFunc customFunc)
 Registers a new custom ethernet handler to run prior to the primary handler.
 
netDoRXFunc ClearCustomNetDoRX ()
 Clears the custom ethernet handler, resetting the handler to NULL.
 
int NetDoRX (PoolPtr pp, uint16_t ocount, int if_num)
 Entry function for Ethernet frames into the system TCP/IP stack.
 

Detailed Description

Callback functions to add custom Ethenet handlers and pass Ethernet frames in the bottom of the TCP/IP stack.

#include< netrx.h >

Note
Custom handlers require that the system is(re)compiled with the ALLOW_CUSTOM_NET_DO_RX macro defined.
Warning
These functions are for advanced developers only! Code written can affect all receive network processing.

Typedef Documentation

◆ netDoRXFunc

typedef int(* netDoRXFunc) (PoolPtr, uint16_t, int)

#include <netrx.h>

Typedef interface for all network rx processing functions.

Parameter Types:
PoolPtr   The buffer structure containing the received network data
uint16_t  The total number of receive bytes of network data
int       The network interface number of the interface that the frame was received from
Returns
Boolean integer value declaring whether the frame was handled or if it should continue to be processed 1 = proccessed and should be released 0 = not processed and should continue being handled

Function Documentation

◆ ClearCustomNetDoRX()

netDoRXFunc ClearCustomNetDoRX ( )
inline

#include <netrx.h>

Clears the custom ethernet handler, resetting the handler to NULL.

Returns
Previously registered custom handler (NULL if there was none)

◆ NetDoRX()

int NetDoRX ( PoolPtr pp,
uint16_t ocount,
int if_num )

#include <netrx.h>

Entry function for Ethernet frames into the system TCP/IP stack.

Parameters
ppPoolPtr to PoolBuffer containing the ethernet frame
ocountA count of the number of octets (bytes) of ethernet payload
if_numThe interface number that the frame came in on.
Returns
The number of system time ticks to wait before calling again, call with null if timeout.

◆ SetCustomNetDoRX()

netDoRXFunc SetCustomNetDoRX ( netDoRXFunc customFunc)
inline

#include <netrx.h>

Registers a new custom ethernet handler to run prior to the primary handler.

Parameters
customFuncThe netDoRXFunc to call when processing an ethernet frame
Returns
Previously registered custom handler (NULL if there was none)