I would like to connect a solar cell to charge the Puck's battery. I think this could happen regularly checking the battery voltage using NRF.getBattery() and once it is below certain level to start charging from the solar cell. Is there a way to charge a battery through any of the pins ?
The 3V pin on Puck.js is connected straight to the battery, and Puck.js draws so little power that you can use a small solar cell which can be left connected to the battery (batteries are usually fine with a small amount of 'trickle' charging even if they are already full).
There are a few really easy things you could do. The only thing is to watch out for is to make sure you don't put too much voltage (over 3.6v) into Puck.js:
Sadly what you can't do (but which would have been perfect) is to use a rechargeable Lithium Ion CR2032 battery (they do exist) and insert that in to Espruino, as the voltage of the battery is too high. While LiPo/LiIon batteries say '3.7v' they can be as high as 4.2 when they come off the charger.
You could do the same trick as with the supercapacitor though - putting a zener diode between 0 and 3v to ensure the voltage never gets too high. You could then put a half-charged CR2032 rechargeable battery in it and use the solar panel to charge the battery (but to only around 75% charge). It wouldn't be amazing for the battery, but probably wouldn't be too bad.
Hope that helps!
Connecting the solar cell to 3V and GND with a voltage regulator chip should do the trick?
My concern is that by having the battery constantly charged would drop its life. What is your opinion?
Yes, a voltage regulator would be great - but depending on the regulator they do draw some extra current, so it's worth making sure you get an efficient one.
You could also look at getting a proper charge controller. I'm pretty sure I've seen some simple boards that'll charge a LiPo battery from a solar cell properly and provide a flat 3.3v output.
I believe charging batteries like NiMH with a low current trickle charge is absolutely fine - perhaps not ideal, but especially as it's only happening for half the day it should be ok. You could even add some code to Puck.js that would occasionally do some heavy calculations to partially flatten the battery :)
It looks like there could be issues with trickle-charging LiPo though, but again, partially flattening it occasionally will probably help a lot. If you're after the longest life, probably the best solution is to use a supercapacitor as even well cared for rechargeables won't be looking great after 10 years.
...burn the excessive energy w/ turning on LED(s)... when voltage raises above a certain level...
(That's what I do with my excessive solar pv power when battery bank is full: heating water with electricity - the most inefficient way to actually heat water. I divert to a water heater element instead of just short cutting / shunting the pv array and heating it up).
Don't worry about formatting, just type in the text and we'll take care of making sense of it. We will auto-convert links, and if you put asterisks around words we will make them bold.
For a full reference visit the Markdown syntax.
© Espruino, powered by microcosm.
Report a problem