Add get_eth_has_ip()
This commit is contained in:
@@ -999,6 +999,11 @@ bool get_eth_connected()
|
|||||||
{
|
{
|
||||||
return wifi_get_status_bits() & ETH_CONNECTED_BIT;
|
return wifi_get_status_bits() & ETH_CONNECTED_BIT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool get_eth_has_ip()
|
||||||
|
{
|
||||||
|
return wifi_get_status_bits() & ETH_HAS_IP_BIT;
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
@@ -105,5 +105,6 @@ tl::expected<std::string_view, std::string> get_hostname_for_interface(esp_netif
|
|||||||
#ifdef CONFIG_ETH_ENABLED
|
#ifdef CONFIG_ETH_ENABLED
|
||||||
esp_eth_handle_t getEthHandle();
|
esp_eth_handle_t getEthHandle();
|
||||||
bool get_eth_connected();
|
bool get_eth_connected();
|
||||||
|
bool get_eth_has_ip();
|
||||||
#endif
|
#endif
|
||||||
} // namespace wifi_stack
|
} // namespace wifi_stack
|
||||||
|
Reference in New Issue
Block a user