Functions | |
cy_rslt_t | cy_lwip_add_interface (cy_lwip_nw_interface_t *iface, ip_static_addr_t *ipaddr) |
Adds a network interface to LwIP and brings it up, a network interface contains a WHD Wi-Fi Interface and role such as STA, AP. More... | |
cy_rslt_t | cy_lwip_remove_interface (cy_lwip_nw_interface_t *iface) |
Removes a network interface from LwIP. More... | |
struct netif * | cy_lwip_get_interface (cy_lwip_nw_interface_role_t role) |
Return the LwIP network interface for the given network interface role. More... | |
cy_rslt_t | cy_lwip_network_up (cy_lwip_nw_interface_t *iface) |
This function brings up the network link layer and and starts DHCP if required. More... | |
cy_rslt_t | cy_lwip_network_down (cy_lwip_nw_interface_t *iface) |
This function brings down the network interface, brings down the network link layer and stops DHCP. More... | |
void | cy_network_process_ethernet_data (whd_interface_t iface, whd_buffer_t buf) |
This function takes packets from the radio driver and passes them into the lwIP stack. More... | |
void | cy_network_activity_register_cb (cy_network_activity_event_callback_t cb) |
This function helps to register/unregister callback fn for any TX/RX packets. More... | |
cy_rslt_t | cy_network_activity_notify (cy_network_activity_type_t activity_type) |
This function notifies network activity to Low Power Assistant(LPA) module. More... | |
void | cy_lwip_register_ip_change_cb (cy_lwip_ip_change_callback_t cb) |
This function helps to register/unregister for any IP changes from LwIP. More... | |
cy_rslt_t cy_lwip_add_interface | ( | cy_lwip_nw_interface_t * | iface, |
ip_static_addr_t * | ipaddr | ||
) |
Adds a network interface to LwIP and brings it up, a network interface contains a WHD Wi-Fi Interface and role such as STA, AP.
This is the entry point in this file. This function takes network interface adds to LwIP, configures the optional static IP address and registers to IP change callback.
[in] | iface | Network interface to be added. |
[in] | ipaddr | IPv4/IPv6 address information associated with the interface. |
cy_rslt_t cy_lwip_remove_interface | ( | cy_lwip_nw_interface_t * | iface | ) |
Removes a network interface from LwIP.
[in] | iface | Network interface to be removed. |
struct netif * cy_lwip_get_interface | ( | cy_lwip_nw_interface_role_t | role | ) |
Return the LwIP network interface for the given network interface role.
[in] | role | Interface role. |
cy_rslt_t cy_lwip_network_up | ( | cy_lwip_nw_interface_t * | iface | ) |
This function brings up the network link layer and and starts DHCP if required.
[in] | iface | Network interface to be brought up. |
cy_rslt_t cy_lwip_network_down | ( | cy_lwip_nw_interface_t * | iface | ) |
This function brings down the network interface, brings down the network link layer and stops DHCP.
[in] | iface | LwIP Interface. |
void cy_network_process_ethernet_data | ( | whd_interface_t | iface, |
whd_buffer_t | buf | ||
) |
This function takes packets from the radio driver and passes them into the lwIP stack.
If the stack is not initialized, or if the LwIP stack does not accept the packet, the packet is freed (dropped). This function will be registered as part of the whd_netif_funcs defined in whd.h of the Wi-Fi Host Driver.
[in] | iface | WiFi interface. |
[in] | buf | Packet received from the radio driver. |
void cy_network_activity_register_cb | ( | cy_network_activity_event_callback_t | cb | ) |
This function helps to register/unregister callback fn for any TX/RX packets.
Passing "NULL" as cb will deregister the activity callback
[in] | cb | Network activity callback function |
cy_rslt_t cy_network_activity_notify | ( | cy_network_activity_type_t | activity_type | ) |
This function notifies network activity to Low Power Assistant(LPA) module.
[in] | activity_type | Network activity type cy_network_activity_type_t to be notified to Low Power Assistant(LPA) module. |
void cy_lwip_register_ip_change_cb | ( | cy_lwip_ip_change_callback_t | cb | ) |
This function helps to register/unregister for any IP changes from LwIP.
Passing "NULL" as callback will deregister the IP changes callback
[in] | cb | IP change callback function |