Initializing Tasks and objects

After all the µC/TCP-IP prerequisite modules have been initialized (see section Prerequisite Module Initialization), the TCP/IP stack must be initialize with the function Net_Init(). This function must be called before any other network API functions.

This function will create the OS objects required by the TCP/IP module, initialize to their default value all the network configurable parameters, initialize the network statistic counters, initialize the network buffer pools, initialize all the different network layers, etc.

This function also takes as arguments the three Network Task configurations defined in the net_cfg.c (see section Network Stack Configuration) file as shown in the function prototype below.   

NET_ERR Net_Init(NET_TASK_CFG  *p_rx_task_cfg,
                 NET_TASK_CFG  *p_tx_task_cfg,
                 NET_TASK_CFG  *p_tmr_task_cfg);


For more details on the Net_Init() function refer to API functions section here.

The section Sample Applications also gives examples of TCP/IP application initialization functions.