2021-11-01 07:17:18 -04:00
|
|
|
/*
|
|
|
|
* SPDX-FileCopyrightText: 2019-2021 Espressif Systems (Shanghai) CO LTD
|
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
|
|
*/
|
2019-11-26 04:48:38 -05:00
|
|
|
#pragma once
|
|
|
|
|
2020-09-08 05:39:56 -04:00
|
|
|
#include "esp_eth.h"
|
|
|
|
|
2019-11-26 04:48:38 -05:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2021-08-03 07:34:52 -04:00
|
|
|
/**
|
|
|
|
* @brief Handle of netif glue - an intermediate layer between netif and Ethernet driver
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
typedef struct esp_eth_netif_glue_t* esp_eth_netif_glue_handle_t;
|
|
|
|
|
2019-11-26 04:48:38 -05:00
|
|
|
/**
|
|
|
|
* @brief Create a netif glue for Ethernet driver
|
|
|
|
* @note netif glue is used to attach io driver to TCP/IP netif
|
|
|
|
*
|
|
|
|
* @param eth_hdl Ethernet driver handle
|
|
|
|
* @return glue object, which inherits esp_netif_driver_base_t
|
|
|
|
*/
|
2021-08-03 07:34:52 -04:00
|
|
|
esp_eth_netif_glue_handle_t esp_eth_new_netif_glue(esp_eth_handle_t eth_hdl);
|
2019-11-26 04:48:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief Delete netif glue of Ethernet driver
|
|
|
|
*
|
2021-08-03 07:34:52 -04:00
|
|
|
* @param eth_netif_glue netif glue
|
2019-11-26 04:48:38 -05:00
|
|
|
* @return -ESP_OK: delete netif glue successfully
|
|
|
|
*/
|
2021-08-03 07:34:52 -04:00
|
|
|
esp_err_t esp_eth_del_netif_glue(esp_eth_netif_glue_handle_t eth_netif_glue);
|
2019-11-26 04:48:38 -05:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|