How to apply Wifi in an Espruino and ESP8266 contexts uniform? #1004
Unanswered
espruino-discuss2
asked this question in
Interfacing
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Posted at 2018-10-30 by @allObjects
Wifi is pretty compatible in Espruino with ESP8266 as well as in Espruino on ESP8266... including
wifi.getIP()
, which works in callback style the same way, even though for Espruino on ESP8266 the direct approach is still available (see my ddddooohhh-post atEspruino/Wifi - getIP() returns undefined but callback receives null,ip... - LOL).
The uniform way for
getIP()
looks as follows:...But it falls all apart when I
setHostname(...)
before (before connecting). With Espruino Wifi I still get the IP... but on ESP8266 I get0.0.0.0
. May be I do not understand setting thehostName
yet... have to play a bit more......to be continued.
Beta Was this translation helpful? Give feedback.
All reactions