Auric: Learning from testing

It's amazing what you learn when testing in the real world...

Auric went out for a long drive last weekend, while things went pretty well, there are always things to learn:

1.  Solving a performance problem

Halfway through the long test I noticed that Auric was pulling to the left, and I suspected a motor drive problem.  After putting the machine up on a bench for a closer look I noticed something, well, "green"

Upon closer inspection, Auric had decided to become an autonomous lawn mower and managed to wrap a 60cm grass runner around the front left drive.  Side effect was that the motor was loaded down and that caused thermal protection in the driver board to kick in.

The final insult was when the imaging detected off-course behaviour and resulted in the motion controller trying to drive the jammed motor even harder, resulting in a vicious cycle.

The end result of all of this is twofold.  Firstly, removing said grass solved the problem, and I wish to add "WEEDING" as a term in the robotics lexicon for the process of solving environmentally caused mechanical issues.

2.  When the board is not what it seems

Dear SparkFun, I owe you an apology.

In my last article, I wrote I was using your "Monster Moto Shield" as part of the motion controller.  Those with keen eyes will spot something completely different at the back of Auric at present.  So what happened?

I purchased two boards from an online reseller because my usual suppliers had no stock, and it would take too long to get them from the US.  Both boards failed in exactly the same way.  The driver for motor 2 would only drive the motor in reverse.  In forward, the potential across the motor was about 0.8 volt, regardless of the motor being used. supply voltage, etc.

I thought this was highly unlikely, so I looked closely at the boards.  While the say SparkFun on them, have the right logo and all, they don't appear exactly like the board on SparkFun's website.  The two driver chips have wildly different manufacturing ID numbers as well.

So what did I get then?  A pair of pretty good looking knock-offs.  Oddly enough, the seller has gone to ground so I have done my money on these ones, and will stick to my preferred resellers in future.

To meet the deadline, I switched to a Deek Robot motor driver which has got me past the deadline, but I am looking forward to getting my real Monster Shields soon!

3.  If it sticks out, it will get broken
In the interest of getting some more interesting video, I attached a Moovie Action camera from Jaycar electronics just above the front track.  This short clip clearly shows what happens when the front camera extends beyond the line of the front tracks:

Auric: All about batteries

Batteries are really important if you're living off them

OK, so this is going to be pretty boring, but it is important so bear with me.

I learned from my experiments with the self-driving car that battery performance is critical, and to be honest last time I didn't pay enough attention.  I am making up for that oversight this time around.

The Lovbio car used a 6V lead-acid battery to run it's motor.  Because that didn't give me too much headroom for my 5V powered electronics I had to run a separate 7.4V LiPo pack (commonly known as a "2S" pack) to run the electronics.  While it worked in the short term and helped the car to meet it's goals, it was not a viable solution.

Because Auric is a ground-up design I had the opportunity to address a lot of the shortcomings from the last car and one of those was the power supply.  This time, it's a single battery and it's a big one, a 6200mAh 2S LiPo pack.  Basically it was the highest capacity 2S pack I could get my hands on.

I arrived at the 7.2V figure after some estimation.  The motors driving Auric's tracks are recommended for operation from 6V - 9V.  Each LiPo cell is typically 3.7V, so if I went to a 3S battery, I would have to regulate down from 10.9V which would have made things complicated.  But even then it wasn't that simple.  The NanoPC T4 processor board I am using needs 12V to operate.  I am not sure who thought this was a good idea because most comparable boards will operate from 5V - 6V.  To get around that I have to use a small switchmode power supply to provide the power for the processor.

But we are still not out of the woods yet.  Unlike SLA (Sealed Lead-Acid) or NiMH rechargeable cells, LiPo cells have a few other quirks we need to be aware of.  Firstly a fully-charge 2S package will measure well over 8V.  Mine measured 8.25V under load when I started testing.  The second thing is that they do not take kindly to being discharged below around 3V/cell, or 6V in my case.  I'm sure you've seen videos of burning battery packs which will clearly illustrate my point.

This means we are operating with a headroom of around 2.5V, and we need to be careful to shut things down before we get dangerously under voltage.  In a future version of the system software, Auric will manage it's own battery events, but I don't have time for that right now.  As a result, I needed to understand how long I could run the completed system before the battery voltage dropped to the critical point.

How are we going to measure this?  It's pretty simple actually, I dropped Auric onto the "RoboDyno" and let it run while measuring the terminal voltage of the LiPo pack every ten minutes.  My results are shown further down this page, and they highlight some interesting information.

If you plug "LiPo discharge curve" into your favourite search engine, you will find graphs a lot like this one:

You can see from these ideal values that there is a steep initial drop in voltage, followed by a long period of moderate drop and finally the point where the terminal voltage "drops off the cliff" and we really need to shut down.

In my testing, the terminal voltage decline was quite linear, typically 40mV (0.04V) every ten minutes.  However if you plot the available headroom (as a percentage), the chart is much more dramatic.  My battery went from 40% (6.95V) to -10% (5.77V) in the 10 minute window!  Had I used a shorter sample window I would have gotten a more typical curve, but mine does at least follow the text book.

When I plugged in the charger it showed one cell bank at 3V, the other at 2.8V; so the inbuilt measurement is reasonably consistent.

So what did I learn?  A few things actually:
  1. Auric can run safely for around two and a half hours across level terrain.  Hills and soft surfaces would affect this adversely.
  2. The battery cliff is very real
  3. The revised motion controller got to 40C, so I added a heatsink to the driver chip just to keep myself happy.  The datasheets say it can run to 50C, but why take chances?
  4. It takes 3 hours to get 3 hours worth of results.
In conclusion, I am writing this on the eve of what should be Auric's most epic voyage so far.  But at least now I am comfortable that it has the power to last the distance.  I just have to solve whatever other problems come up along the way.

Wasting your and my time

I had a really interesting experience recently which I hope might enlighten others as much as it did me: I was approached (via LinkedIn) by ...