-
Notifications
You must be signed in to change notification settings - Fork 7.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
esp32 arduinoOTA sethostname() not working #3438
Comments
esp32 != esp8266. https://github.com/espressif/arduino-esp32/blob/master/libraries/ArduinoOTA/src/ArduinoOTA.h#L82 |
The following worked, but i don´t think you really need the disconnect and config parts.. In my case it wasnt the ESP32, it was my router. Check that you don´t have the mac or ip assigned anywhere in the router and change the lease time of dhcp to something like one minute.. now the router should see the ESP with it´s new hostname.. ` void setup () { WiFi.disconnect(); // probalbly not needed WiFi.begin(ssid, password); } |
Well thanks to both, indeed |
@EsserPrototyping thanks for the tip! Turns out for me it was
that was needed... although I actually used
I found in addition that My complete code:
|
Hi,
I'm using
ArduinoOTA.sethostname("esp32-entrance-device");
and the hostname in the Arduino IDE Network ports is always showing as esp32-[MAC address].Maybe I'm a little bit rusty with my code abilities, but isn't _hostname missing in the ArduinoOTAClass::ArduinoOTAClass() definition?
Link to code: https://github.com/esp8266/Arduino/blob/master/libraries/ArduinoOTA/ArduinoOTA.cpp
Thanks!
The text was updated successfully, but these errors were encountered: