Skip to content
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

first-time help for new users (show how to connect) #13

Open
gitcnd opened this issue Oct 27, 2023 · 3 comments
Open

first-time help for new users (show how to connect) #13

gitcnd opened this issue Oct 27, 2023 · 3 comments

Comments

@gitcnd
Copy link

gitcnd commented Oct 27, 2023

BRILLIANT project!!

Might I suggest, where it currently prints this: "Starting IDE web service" you update that message so it says this instead:-

Starting IDE web service on http://192.168.123.123/
... so we don't have to fuss around trying to work out what IP to use, and whether or not it's on port 80 ...

@gitcnd
Copy link
Author

gitcnd commented Oct 28, 2023

I took a stab at fixing this, but of course, the IP is always 0.0.0.0 until the connection is up

print("Starting IDE web service on http://" + wlan.ifconfig()[0] + "/") # this never works, because non-blocking above (wlan.isconnected())

someone smarter-than-me might have to explain how to code a callback to do the print after the connection comes up...

@vsolina
Copy link
Owner

vsolina commented Nov 4, 2023

That would be a cool feature.
There is a bit of complexity, though: ESP32 can have multiple IP addresses (wlan, eth) at the same time, but for start I could just show the WiFI IP if available.

@gitcnd
Copy link
Author

gitcnd commented Nov 4, 2023

I'm in the middle of researching a much better idea... mDNS... eg: "esp32-1234.local" (where we can pick the name by putting it in some file or whatever - e.g. "geiger.local" for my local geiger-counter project when I upgrade that to uPy)... still needs some kind of async tool to wait for an IP then deal with port5353 UDP stuff, so that component itself could also print out the IP (and name) on the serial port when first connected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants