Shop OBEX P1 Docs P2 Docs Learn Events
Battery monitoring — Parallax Forums

Battery monitoring

jettenrulesjettenrules Posts: 3
edited 2008-09-27 18:05 in Robotics
Hi all,

I recently bought my BoeBot, but I've done all excercises in the manual, and some things of my own, so I thought: let's try a bigger project.

I want to make my BoeBot more autonomous, by making it self-recharging. I've found some articles about making a docking-station, so that shouldn't be a problem (and else I'll ask [noparse];)[/noparse]).
The problem I'm facing is: Is there a way (simple and cheap) to know the battery level of the BoeBot? The idea is to program the Boebot to do it's thing (e.g. roam) and once in a while check it's battery level. If the level goes below a certain point, the program goes to the subroutine 'Recharge'.

I couldn't find any easy sensors in google (maybe bad keywords), only complex and expensive onces. A simple sensor with 1 IO-output would be great.

I'm a newbie to robotics/electronics, so pointers to tutorials/manuals or something would be nice [noparse]:)[/noparse]

Regards,

Sander

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2008-09-24 23:40
    Tracy Allen's website (www.emesystems.com) has a section on using the RCTIME statement to measure battery voltage.
    At the bottom of the page is the link to the Stamp stuff. Use the "app-notes" link and scroll down to the stuff on the RCTIME statement.
  • ercoerco Posts: 20,256
    edited 2008-09-25 00:15
    Sander: I have·a Scribbler charging dock article at http://www.botmag.com/articles/scribbler.shtml but it doesn't monitor battery voltage. My goal was simplicity and to do the absolute minimum robot mods to achieve reliable docking. In my own continuing experiments, I try to keep a rough idea of battery charge through a program variable which is a looping counter·to keep an approximate amp-hour·discharge away from the charger. It's like a taxi meter that·increments·slowly when the robot isn't moving and much faster when the motors are on. When the cumulative·total hits a certain number, it triggers the recharge routine. Mine is a simple·trickle charger, and I can leave it charge indefinitely. You could also slowly decrement the discharge level variable based on time in the charger. Experimental approximations, but useful.

    Surely, monitoring the battery voltage per Mike/Tracy is more reliable. NiMH batteries' discharge curve is not nearly as flat as·some people claim, and you could set some threshold value to trigger your routine. Voltage under a driving load is more useful than·the no-load·(motors off) voltage. It·could be as simple as adjusting a voltage divider pot across your battery voltage to the Basic Stamp's high/low input pin threshold of ~1.4 volts. When the batteries are charged, the sensed voltage·stays above 1.4 volts under load, and the input pin measures high. When it drops below 1.4 volts (input pin low) under load, head for the hills. Or the charger.

    erco

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"If you build it, they will come."
  • jettenrulesjettenrules Posts: 3
    edited 2008-09-25 19:12
    thanks for the quick replies!

    I've got the RCtime-thing working now. I've got to experiment what are the right settings, which give BoeBot enough time to reach the dock though. Part one of project finished [noparse]:)[/noparse]

    @ Erco: Is it alright if I PM you if I get stuck at your docking station? I'm going to try to build that now.

    greetings,

    Sander
  • noobmunchernoobmuncher Posts: 124
    edited 2008-09-25 20:37
    One possibility that i have had success with is attaching a led light directly to the batteries (must still be protected with resistors) attaching a photoresister to it and sealing it in electricians tape.· Then you just have the stamp occasionally check the light level.· It seems crude, but it works quite well.·
  • jettenrulesjettenrules Posts: 3
    edited 2008-09-25 21:02
    I'm looking for an adapter for my docking station. Found a 12-and-a-bit V DC adapter, but the current (A) fluctuates between 1 and 0 about every second, is that normal? (Don't even know if that's a stupid question).
    Is that 12,3V enough to recharge 5 NiMH batteries?


    @noobmuncher: Nice solution [noparse]:D[/noparse] Would've never thought of that. Will give that·a go in another project.


    Sander



    ·
  • ercoerco Posts: 20,256
    edited 2008-09-25 22:53
    OK to PM. Not sure about your adapter fluctuations. You're measuring the current it's trying to charge 5 NiMH battteries? Hopefully it is neither a new switching unit (small & lightweight) nor a 12 volt battery charger.. Best bets are old, dumb, heavy (transformer-based), non-regulated, non-switching types. They will give you steady current. As I said, scavenge adapters from old answering machines and the like...

    With experimentation, you can even use a fixed resistor as your current limiter instead of the LM317T. The whole idea is to limit the fully-charged current to less than 0.1C .

    Noob:·Kudos for your·very simple and innovative·voltage monitor idea using an LED & photocell.·I guess a·standard CdS photocell would be most responsive to a yellow or green LED.·The price is a·small continuous current drain (maybe 5-8 mA?), but I'd guess that you could run a calibration and get pretty accurate voltage readings over a wide range. Nice job!

    BTW, Junun has small green LEDs that operate at 2 mA, which would be useful here. Probably could get 'em down to 1 mA, maybe less... http://www.junun.org/MarkIII/Info.jsp?item=63

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"If you build it, they will come."

    Post Edited (erco) : 9/25/2008 11:04:41 PM GMT
  • MovieMakerMovieMaker Posts: 502
    edited 2008-09-27 18:05
    jettenrules,

    ·· I would like to hear more about this in your future posts as I wish to hook my boebot up to both a docking station and a Solar Cel recharger.

    :-)
Sign In or Register to comment.