how to change host name from "espressif" in wifi station mode for esp32
-
- Posts: 1
- Joined: Wed Jan 29, 2020 9:34 pm
how to change host name from "espressif" in wifi station mode for esp32
I tried to change the host name which is displayed in the router after esp32 is connected to it in station mode. It is displayed as "espressif" in the router. I used esp_netif_get_hostname(esp_netif_sta_handle, (const char**)temp) and esp_netif_set_hostname(esp_netif_sta_handle, (const char*)sta_name) to check and set the name, those functions works fine and did change the name. But after the esp_wifi_start(), the hostname is changed back again back to "espressif". I tried to change the name before and after wifi_start() , and nothing works. Also these is no setting in sdkconfig to make this change. Please help. Thanks.
-
- Posts: 15
- Joined: Thu Jan 02, 2020 12:07 am
Re: how to change host name from "espressif" in wifi station mode for esp32
Code: Select all
tcpip_adapter_set_hostname(TCPIP_ADAPTER_IF_AP, WIFI_MDNS_HOSTNAME);
Re: how to change host name from "espressif" in wifi station mode for esp32
I observed the same problem and report it belowjiangzhiyong wrote: ↑Fri Feb 07, 2020 5:29 amI tried to change the host name which is displayed in the router after esp32 is connected to it in station mode. It is displayed as "espressif" in the router. I used esp_netif_get_hostname(esp_netif_sta_handle, (const char**)temp) and esp_netif_set_hostname(esp_netif_sta_handle, (const char*)sta_name) to check and set the name, those functions works fine and did change the name. But after the esp_wifi_start(), the hostname is changed back again back to "espressif". I tried to change the name before and after wifi_start() , and nothing works. Also these is no setting in sdkconfig to make this change. Please help. Thanks.
https://github.com/espressif/esp-idf/issues/4737
Who is online
Users browsing this forum: Majestic-12 [Bot] and 97 guests