After scanning my WIFI, entering the password (it’s all correct) I click “Logging ->” to progress to next stage but it never reaches what I assume is where I’ll set up MQTT etc. My Mac shows up “a problem occurred” and repeating setup via a iphone running through the same procedure again seems to timeout.
I can see in the config.py file that the wireless details were saved. In log.txt the last entries are:
[info.... > POST /provision-twp-2-wifi (301 Moved Permanently)
[error.... need more than 0 values to unpack
I’ve looked at the config file and set it to True rather than False to see if that’ll get it out of provisioning mode or at least see if it’ll connect to WIFI as I’d assume that will mean it’s up and working but no joy.
If I press reset the activity LED turns on for a second then goes off. Using the Poke button does nothing and the whole thing sits there dormant.
Needless to say I’ve deleted config.py as per the troubleshooting and ran the provisioning again but without success. It still times out after trying to move on to logging. Should it attempt to connect to the WIFI at that stage? I can get the Enviro on my wifi using a basic py script so it can connect but something in the setup just isn’t working right.
If i connect to the Pico while setup is running I see this when it hangs/fails after entering the WIFI information and trying to continue:
Task exception wasn’t retrieved
future: coro= <generator object ‘_handle_request’ at 20015990>
Traceback (most recent call last):
File “uasyncio/core.py”, line 1, in run_until_complete
File “phew/phew/server.py”, line 254, in _handle_request
File “phew/phew/server.py”, line 142, in call_handler
File “enviro/provisioning.py”, line 71, in provision_step_3_logging
File “enviro/helpers.py”, line 182, in get_config
File “enviro/helpers.py”, line 169, in get_values_from_file
File “”, line 1
SyntaxError: invalid syntax
Done! In fact, I’ll swap you if you add in the code examples to trigger the water pumps in the Grow+accessory bundle I bought and publish the new schematics :D
Only realised there was nothing firing it off after seeing it’s using the basic monitoring code only :/
Yep, I think a pump example is on the way (though we’re a little short handed this week). I’m looking forward to that too, wanting to get stuck into a nice auto-watering tutorial!
Schematics for the new things will also be along soon, but if you want to attempt hacking in some pump control in the meantime, I can see from our production schem that they’re connected to GP12, GP11 and GP10. Your code should avoid triggering them at the same time to avoid voltage/current spikes (I seem to remember this was an issue with the OG HAT version of Grow…)
Perfect thank you! I’ll go find some code examples to add that handover from one pin for the sensor to the pin for the pump and watering separately too.
It’s possible to connect the pump outputs to relays instead of pumps (One shouldn’t connect the Pico GPIOs directly to relays though). The pump output voltage is the board power supply voltage, so the relays should be selected so that the relay coils work with that range.