[Dprglist] Compass heading using gyroscopes?

Murray Altheim murray18 at altheim.com
Sun May 17 15:25:26 PDT 2020


On 17/05/20 2:19 pm, Karim Virani via DPRGlist wrote:
> Hey Murray,
> 
> In my earlier forays into robotics I was similarly fixated on compass
> heading. Even for indoor situations. I've been down that road and
> learned a bit through my failures. In a purely pragmatic way I would
> say give up now. Learn from the pain of those who have traveled before
> you. Turn back from this mire.[...]

Hi Karim,

This sounds so much like the beginning of a lot of movies. Frankenstein
and The Hound of the Baskervilles, as well as The Shining come to mind.
The Shining is a particularly indoor kind of film.

Yes, my robot is an indoor robot but I sometimes let it out onto the deck.

Thanks to you, John, Doug and David for the advice -- it's appreciated.

Earlier I'd mounted my BNO055 on the main Delrin plate that everything is
connected to, so it was within a few cm of sensors, motors and motor
controllers. It did fall out of calibration rather often but when it was
calibrated it did a remarkably good job of pointing north, within a degree
or so. I dug around and found a Euler to Quaternion conversion algorithm,
then added a cheap check to my Python script that tested if the BNO055
thought it was calibrated (well, the sensors I needed) and if both the
Euler and Quaternion outputs were within an error range of each other.
That didn't happen all the time but when it did I was getting a reasonably
reliable output. I moved it up onto a short 8cm mast and that didn't make
a huge difference but I frankly haven't tested it that much lately, been
on to other things like PID controllers, cat scanners and whatnot.

This isn't to say that some spectral dog won't jump up and bite my throat
-- I take your warnings seriously -- but that as an experiment it seemed
to be almost working okay. But given everyone else's experience with the
board I'm staying appropriately wary of any dense fog or howling.

I'm thinking about that corner challenge, particularly in light of David's
point that its origin was in tuning one's robot. It seems that even if the
odometry is perfect, getting the robot directly facing the first target
is still key. Whether it's absolute or relative orientation (which I'm
guessing doesn't matter *that* much, having some kind of orientation is
a requirement. David's demo I believe is using a gyro so (correct me if
I'm wrong) that's a relative orientation; as he says, he's keeping track
of theta). Relative orientation almost makes more sense given our buildings
aren't perfectly aligned to the compass, nor would robot contest courses.

But I'm pretty sure I'm not a competitive type. Pretty sure. Oh, yeah, I'm
sure. Sure, I'm sure.

As things progress I'll announce any major breakthroughs. Or you may hear
me cry for help.

Cheers,

Murray

...........................................................................
Murray Altheim <murray18 at altheim dot com>                       = =  ===
http://www.altheim.com/murray/                                     ===  ===
                                                                    = =  ===
     In the evening
     The rice leaves in the garden
     Rustle in the autumn wind
     That blows through my reed hut.
            -- Minamoto no Tsunenobu



More information about the DPRGlist mailing list