Conversation
|
As a stylistic point, I'd make In my code, I always start the enduser_setup -- it exits once the connection is up -- no matter whether the user configured it, or whether a previously set SSID was found. |
Now it is - I just changed the base branch. Also, please fix the CI build issues: https://travis-ci.org/github/nodemcu/nodemcu-firmware/jobs/757193097 |
| @@ -0,0 +1,34 @@ | |||
| -- init.lua example, with wifi portal | |||
There was a problem hiding this comment.
This should IMO go into a sub directory like e.g. lua_examples/eus/init.lua
There was a problem hiding this comment.
I agree that this init.lua is "eus" specific. I have no problem moving it to eus. However, maybe we could group all examples of init.lua together... one with eus, one for waking up after deep sleep, other situations.... All I know is that when we need those examples, they are scattered around the docs, so a directory "starting up" might also work. Its up to you, I'll follow your suggeations and update the PR.
There was a problem hiding this comment.
maybe we could group all examples of init.lua together
Good idea! Do you have a naming proposal? A directory called init_lua and then files like e.g. eus-init.lua?
https://nodemcu.readthedocs.io/en/latest/upload/#initlua -> move from docs to a file in that new folder, add reference to existing docs chapter.
|
To answer, @pjsg, we can't make Unfortunately, |
|
@blobule "I don't see any way around this" -- Use a tmr. ;-) |
|
You can disable checks in luacheck by adding a comment. See the luacheck documentation |
Fixes no specific issue,
devbranch rather than for thereleasebranch.docs/*.Following a suggestion in #3374 , this is an example for a init.lua that uses a wifi portal to configure wifi if needed.
I put it inside lua_examples, but I don't know how and where to refer to this in the docs. Suggestions?
Also, I wonder if it would be interesting to provide complete examples for some common IOT setups:
( Here robust means that it will survive power outage, network outage, etc, and always restart properly. )
Such examples could make it much simpler to setup IOT by providing a good template.
Juste wondering if this is something that would be considered useful.