www.beck-ipc.com

@CHIP-RTOS C Library - TCP/IP API


AddStaticRoute

Add a route for an interface.

int AddStaticRoute ( IP_INTERFACE which_interface,
                     const Route_Entry far *route,
                     int *error );

Parameters

which_interface

Enumeration type:
  • II_ETHERNET = 0:   Ethernet
  • II_PPP_SERVER = 1:   PPP server
  • II_PPP_CLIENT = 2:   PPP client

route

Pointer to user Route_Entry structure (defined in tcpipapi.h).

error

Output parameter:  Failure code, 0 on success.

Return Value

0: success
-1: See reported error code.

Comments

IP packets destined for the specified network will be routed to the specified device.

The alternative AddStaticRouteEx() API must be used for user defined devices.

SC1x3/SC2x Comments

Important:    The current SC1x3/SC2x Chip-RTOS version supports only route definitions based on the IPv4 protocol.

See Also

RTOS API

This library function invokes a RTOS software interrupt. Refer to this RTOS API function's documentation for more details.

Supported since or modified in @CHIP-RTOS version

    SC12SC13SC11SC1x3SC2x
    V1.10V1.00V1.00V0.90V1.00

This API List
List of C Libraries
@CHIP-RTOS Main Index


End of document