Wifi: Changing Hostname
Posted: Thu Mar 21, 2024 9:57 pm
I tried adapting the wifi-station-example (https://github.com/espressif/esp-idf/bl ... ple_main.c), so that the hostname is changed via .
More specifically, I changed this line from the example:
to this:
The code compiles and runs just fine, however the hostname is still showns as "espressif" when looking at my home-network.
How do I have to change the wifi-station-example, so that the hostname is adapted?
Code: Select all
esp_netif_set_hostname
More specifically, I changed this line from the example:
Code: Select all
esp_netif_create_default_wifi_sta();
Code: Select all
esp_netif_t* netif = esp_netif_create_default_wifi_sta();
ESP_ERROR_CHECK(esp_netif_set_hostname(
netif, "something"));
How do I have to change the wifi-station-example, so that the hostname is adapted?