Hi Liam,
Then it’s really good. Thank you.
Hi Bob,
The control board on top is the crème de la crème that makes this board so useful, instead of having to include a MOSFET or H-Bridge on the plant_io SHIM we can do away with all that. Now that it acts like a servo a duty cycle can be sent via the signal wire.
Without that board working it takes away the solderless experience that is the plant_io kit.
Liam
Hi Liam
Didn’t say anything about any board.
Simply said you suggested the pump being faulty when Jarrah255746 had tested it as OK by connecting the battery directly.
Cheers Bob
G’day guys,
I just received the kit and love it. However, i’m just wondering, i may have had the battery pack turned on and then connected it to my computer via USB at the same time…now the battery pack doesn’t seem to be working. No light comes on the board when the pack is turned on. I have tried disconnecting the pack and reconnecting it, and have changed batteries. Still nothing.
The unit still connects fine to Mac/Thonny.
Second thing, When i was running the system just off the battery, when i did connect it up Thonny to check the log file, i couldn’t find it. I could only find it when i left it connected Via USB cable to Mac.
update Now the light comes on briefly and goes off again when connected via battery pack.
Cheers
Justin
Hi Justin,
When running from the battery bank you might have to press the reset button on the power timer HAT.
Or keeping the battery pack off when powering from USB, then turning it on.
I’m not certain about the log file off the top of my head but the guys at Core should be able to help tomorrow!
Thanks Liam, this helped. Didn’t even realise there are 2 reset pins on the HAT. In the end I tried that but it still turned off. So I pulled everything apart and started again. And all good now.
Just need to work out the Log file
Hi Justin,
The log saves to the internal flash so the experience on Windows and Mac should be the same, would it be possible to send through a photo of your Thonny? (Make sure to not include any personal details)
You can enable the file window by naviating to View > Files
When you connect your Pico its always good to do a file system refresh,
Let us know how you go!
Liam
Hi Liam,
Thanks for getting back to me. Appreciate it. I just checked it again, and i could find it all there. Not sure what happened before. I am a total noob, so maybe its just that.
Loving this kit by the way.
I added a pic of the setup.
Justin
Hi Justin,
Gkad to hear you found it!!
We all started somewhere and glad it was with the Plant_io kit!!
Awesome setup, keen to see your plants grow
Liam
Hi,
Just connected up my kit and can’t get the soil moisture probe to read 0. When running the soil moisture test it reads about 60% when completely dry and about 90% when submerged in water. After any suggestions on how to calibrate the sensor?
Thanks
Hi Liam,
Ok, everything was working fine, then i ran the set up on battery power for about 24hrs and turned battery pack off and then connected to mac. Couldn’t find the log file (even after refreshing). I stopped and started the main.py and found the log file but i couldn’t get all the data that was from last 24 hours.
I rewatched the Plant_IO setup video and wondered if it matters if the battery pack is turned on or off when reconnected to USB.
Now i can’t tell if i’m doing something wrong or not.
Hi Josh,
It sounds like that’s arrised from this PR: Plant_io Basic Setup Guide | Automatically Water a Seedling Based on Soil Moisture - #8 by Marc67778
You could try the old values:
self.curr_sens = self.mf.normalise_x(moving_ave, 27500, 50000)
or set your own min and max using the following code:
import machine
import utime
soil_moisture = machine.ADC(28)
# A handy function for mapping values
def map_range(x, in_min, in_max, out_min, out_max):
mapped = (x - in_min) * (out_max - out_min) / (in_max - in_min) + out_min
return int(max(min(mapped, out_max), out_min))
while True:
soil_moisture_raw_reading = soil_moisture.read_u16()
print(soil_moisture_raw_reading)
# # Uncomment the 2 lines below for the mapped reading
# soil_moisture_filtered_reading = map_range(soil_moisture_raw_reading, 15000, 50000, 0, 100)
# print(soil_moisture_filtered_reading)
utime.sleep(0.5)
Hey @Justin264431
That’s quite strange - if you run off of USB what does the battery voltage say? The Pico might be in a brown-out state and isnt able to completely run/save?
It shouldnt matter whether its on or off when reconnected - keen to get to the bottom of this!
Liam
Here are a couple of screenshots from this evening. Keen to get to the bottom of this too! Cheers for your ongoing support.
One thing that seems to keep happening, is that after i disconnect the USB cable from laptop, the power switch on the battery setup pack has no effect. Then i hit the ‘reset’ buttons on the Power HAT and it seems to start working again (lights are on just from being supplied by power pack). BUT then there is no log.txt file anywhere to be seen once reconnected to Laptop.
Hi Justin,
This seems like its working and supplying power to the power timer HAT at least!
It sounds like the Pico might not be receiving power here, thanks for confirming that.
- The Batteries might not be charged in which case the Pico is definitely in that brown-out state
- The power timer HAT is faulty
If you have a NiMH charger popping them in for a while should remedy any voltage issues
A quick test to confirm that the batteries and power timer HAT are working would be to run the following code:
from machine import Pin
from time import sleep
onboard_led = Pin(25, Pin.OUT)
DONE = Pin(22, Pin.OUT)
onboard_led.on()
sleep(3)
DONE.on()
The LED should turn on for 3 seconds then turn off, you can start this again by pressing the reset button on the HAT.
Liam
Hi Liam,
Thanks for replay. I can confirm that the NiMH batteries were in fresh brand new and fully charged. I even measured the charge from
Them and got 4.8v. So not the batteries.
Hi Liam,
Should that code be run whilst connected to usb or via battery?
Hi Justin,
Sorry, it should be uploaded as main.py
so that it can be run when the power is coming through the power timer HAT.
Ok great. Thanks
Hi Liam,
Things are getting weird. I tried the code and it worked sometimes and then other times it just turned off.
Justin
Hey Liam,
When the Plant is operating off of battery power is the LED lights on the HAT supposed to stay on constantly? Or does it just come on when the 20minute power cycle kicks in to run the program and then off again?
Sorry for so many questions haha.