Showing posts with label robot. Show all posts
Showing posts with label robot. Show all posts

Sunday, July 23, 2017

Link Update (Again) and Bonus Link Trig!

Once again, all my documentation permalinks got broken when Google Drive stopped supporting static URL hosting. But, I've transferred everything over to AWS now and gone through updating links accordingly on all the static project pages and a few select posts, especially this one. Hopefully these permalinks last a bit longer! Here's the full directory: https://scolton-www.s3.amazonaws.com/list.html. I may transfer more stuff over to there as I go, including maybe using it for hosting new static project pages. Still learning my way around AWS.

Speaking of links, here's an odd bit of trigonometry to solve last post's linkage mystery:

For Twitch X, I mentioned that rather than solving the trig for the geometry of the linkage that connects the two sets of diagonal wheels together (the sin/cos link, as I called it), I came up with a weird exponential parametric equation for the two angles:
x = [sin(θ1)]^K = 1 - [cos(θ2)]^K
The value x ranges from 0 to 1 as θ1 and θ2 both sweep from 0º to 90º, albeit on different trajectories. It makes an excellent feedback variable for the controller, since it can be derived from a simple weighted average of the two linkage angle sensors (after trig and exponent). And conveniently, x = 0.5 is where the wheel sets are perpendicular, for omni mode. For the link lengths used on Twitch X (L1 = 1.00in, L3 = 7.50in), I experimentally derived K = 1.23456789...no joke. But I wasn't ever convinced this was an exact solution, and as it turns out it isn't.

A few pages of trig later, this is the actual parametric solution:
L3*[cos(θ2) + sin(θ1) - 1] = L1*sin(θ1 + θ2)
This one's a lot less convenient from a control standpoint: since θ1 and θ2 are on both sides of the equation it's not obvious what to do with the wheels based on measurements of the linkage angles, at least not without further math. But this is the geometrically accurate solution.

What's amazing is how close the other parametric equation is. As it turns out, the max error is just over 1º and the value K = 1.23456789 is actually a pretty good one in terms of the average error over the full range from 0 to 90º:


None of this matters as far as Twitch X control software is concerned - the exponential approximation with θ1 and θ2 separated is still far better for the application. But solving the mystery of the sin/cos link was really interesting.

Monday, January 30, 2012

Did you know that Flinch still exists?

If you don't even know what a Flinch is, I don't blame you, since I last posted about it in June 2011, and it's been sitting on a shelf ever since. It's a miniature Mecanum-wheel robot that was supposed to be a smaller companion to Twitch:


Unfortunately, I ran into trouble with the FingerTech 2.125" Mecanum wheels. The rollers are nicely-molded rubber, but the shafts are just 1/8" brass rods riding directly on the plastic hubs. Steel washers separate the rubber from the face of the plastic, but there is still way too much friction for the rollers to do what they're designed to do. (For reference, here's a smooth-driving ~40lb Mecanum wheel chassis. And here's the full ~110lb robot.)

FingerTech does sell a bearing upgrade kit, but I have my doubts. The bearings they sell are needle roller bearings, which can only handle radial force. The roller shafts can still slide sideways, allowing the metal washers to rub against the plastic face of the wheel. That, if anything, is the large-surface-area friction culprit of these wheels. So, I decided to go my own way and get much more expensive SR144ZZ ball bearings:

Pictured: Lunch money for three days.
Additionally, I bought some 1/8" ID bearing shaft shims, McMaster P/N 99040A316. These tiny shims keep the metal washers that come with the Mecanum wheel rollers separated from the inner race of the bearings, spacing them out from the side face of the wheel. This allows the ball bearings to take up the thrust load, rather than the face of the wheel. Here's the roller, stock washer, and extra shaft shim all in place on one shaft:


The next step was boring out each of the 24 roller shaft holes from 1/8" to 1/4" to accept the new bearings. Since the faces on which these holes are drilled are at 45º to the rotational axis of the wheel, and spaced 60º radially from each other, and there are two different (mirror image) wheels, this was not a simple task.

Or maybe it was, and I made it way more complicated.
In any case, I managed to increase the roller bores to 1/4" in a way that isn't idiotic. The next step in this already-too-long-and-expensive process was to take apart all the wheels:

Sigh...
Then, I pressed in the bearings one by one and...realized I only ordered half as many SR144ZZ's as I needed.

...

FFFFFFFUUUUUUUUUu

...

A few days and $70 later, I finally got around to reassembling all four wheels with the new bearings.


And after all that work I had four wheels that look exactly the same as they did before, but cost 122% more than FingerTech pretends they do. At least they will be more functional. Except they weren't, at first. After just a minute of driving around, half the bearings had slipped sideways, allowing the metal washers to contact the sides of the wheels again. This was mostly because the new bore was exactly 1/4", so the press fits were loose. So, I took all four wheels apart again...

...cursing myself for ever thinking this was a good idea.
And I very carefully added CA to each of the 48 bearings (two per shaft) to hold them in place:


I used a sharp object to spread CA around the bearing perimeter so it would wick into the bore, hopefully without getting into the bearing itself. I managed not to ruin any bearings, but the process took half a day. And then I still had to reassemble all the rollers. 

I wish I could say that the result of all this Mecanum wheel re-engineering was a wonderful drivetrain that will rival Twitch for its speed and maneuverability. I wish I could say it was all worth the effort and the money. But, after putting it all together and running it, it's still only barely passable as a Mecanum, drive:


Yes, it moves sideways. But it's a jerky, bumpy, inefficient sideways. All Mecanum drives are less efficient sideways than they are forward, but this one is really fighting. It tends to rotate while moving sidways as well, which is a sign of mismatched wheel friction and bad weight distribution. That can mostly be compensated out by gyro feedback. But the gyros won't be able to stop it from bouncing around like a cockroach bot. That's mostly a function of the wheel shape and twitchy nature of small/light robots with oversized motors.

So I'm not sure how much more time or money I'm willing to spend on it. I feel like adding weight, switching to a higher gear reduction, and adding closed-loop rotation control would help a lot. But the thought of buying new gearboxes, a gyro, and possibly stiffer chassis plates makes me cringe. I'm glad it isn't just sitting half-finished on a shelf anymore, though.