Archive for June, 2010


Deathblades: Next-day Shipping Edition

Jun 19, 2010 in Project Build Reports, RazErBlades, Reference Posts

I was able to hop onto a lab parts order early yesterday and throw in some force sensitive resistors and prototyping miscellanea. Thanks to the miracle that is modern supply chains and logistics, I had them on my desk in less than 24 hours.

Now, if only Advanced Circuits could finish my Double DEC’er boards that fast. I mean, without costing a significant percentage of my undergraduate tuition.

Oh, speaking of the Double DECers, here’s the latest board iteration featuring discrete 3.3v and 5v regulators. The amount of power I wanted to draw from the 5v line was cresting the limit of the DECs’ onboard regulators, so I added one that runs directly off the battery input. Also, a power LED.

I figured it was safe to stop there for now.

And here’s (part of) the controller parts roster. On the left is a Lilypad Xbee holder and prototyping antiperfboard. Lilypads were designed to be used with wearable electronics, and I figured that the controller qualified as a piece of wearable electronics. These things are actually huge. They looked tiny and cute in the pictures, but are actually about 2 inches in diameter. I foresee no fitting problems, however.

I got four coin cell holders. The controller power will, for now, come from 2 CR2032s in series for a 6 volt power source, which will be regulated to 3.3 volts.

The XBee 2mm headers are for the Double DECers, so I don’t have to solder my poor XBees to the board.

Anyways, here’s How Shit Go Down™ with the FSRs.

Their resistance decays as 1/R with linearly increasing pressure. There is a very high (megohms) unloaded state, and a minimum force must be applied to enter the hyperbolic region. After a certain pressure is applied, the decay saturates at a steady value until you compress it out of existence. Actually, all this is in the datasheet. Why am I explaining it?

I elected to begin experimenting with the “buffered voltage divider” on p. 16. As fig. 9 illustrates, the voltage response is highly nonlinear near zero force. However, with a low load resistance (Rm), the logarithmic curve is approximately linear at higher forces.  And with a high parallel resistance inserted across the FSR, the Precipitous Voltage Cliff is smoothed out to a zero force intercept with a value of approximately (Rm /  Rparallel + Rm) * Vref.

I exaggerated this approximately linear curve even further by using a 1Kohm load resistor, which seems to put me on the edge of the FSR’s 1ma per cm² current tolerance. Next, I set up the op amp buffer as an adjustable noninverting amplifier (as seen in figure 10). Tuning the blue potentiometer effectively let me set the force slope.

Now I had a response that was kinda-sorta-not-really-but-close-enough linear within an adjustable force range. To supplement, I put a slow RC filter (t ~ 0.5 sec) on the output of the amplifier.

After having enough fun playing Squeeze the Resistor, I began to attach it to spots on the wrist plate for ergonomics testing.  The results:

  • Palm area: Good wrist bend force response, but had the unfortunate side effect of also responding when I opened my palm all the way. This was due to the way the sensor was oriented – a normal force could come from either forcing the hand down through the wrist or pushing the palm out by uncurling the fingers.
  • Other side of same area: Very little response at all, because the force didn’t really go that way.
  • Behind the wrist on the flat portion of the plate. This is the 1st class lever equivalent of the first configuration, so it suffered from the same undesirable side effect. Pushing out with the palm also meant that this area of the plate was pushed upwards (with the main wrist strap as a fulcrum), triggering the sensor. Clearly, any response having to do with “opening of the hands” is bad, because that means if I’m trying to recover from an impending faceplant, it will just faceplant me harder.
  • Right under the wrist: Now this was actually promising. While the motion is reverse (i.e. now I pull up with my wrist), the side effect was eliminated – if not, it was a transient at most.

Crap, should have made the damn wire longer.

And so I actually settled with the original motion I was going to reserve for a brake or reverse mode. Now, something that can clearly solve this issue is having multiple FSRs such that different ones are triggered depending on hand position. The ability to distinguish between the open hand and limp hand with wrist pressure positions clearly mean the difference between go faster and oh shhhhh–.

However, that would require some software processing of the multiple signals, and I want to just start simple for now.

Here’s a short video illustrating wrist bend control. In the video, the control looks sensitive with respect to distance displaced, but that distance comes with substantial force applied against the wrist straps and plates. It’s actually quite easy to maintain a certain voltage position, and the “muscle twitch” response is well damped due to the filter.

The moving line scale is 1 volt per division, and the maximum output voltage is just under 3.2 volts. The system runs on a 3.3 volt bus (XBee native voltage) using the LMC6484 rail to rail I/O op-amp to take maximum advantage of the low voltage swings.

Next mission: Transmit this 0-3.3v signal to another board using the XBees in direct I/O bridge mode and decode & buffer the output to 0-5v.



Jun 17, 2010 in LOLrio Kart, Project Build Reports, Reference Posts, Stuff

MITERS is the greatest thing that has ever happened to the world (or specifically just me), but while it has copious amounts of tools, test equipment, machinery, and an almost gratuitous amount of parts, it lacks space. Having been to other non-academically affiliated hackerspaces (such as Freeside Atlanta), I realize how outclassed we are in our capacity to host projects. Despite that, we’ve stacked up a whole bunch of “large”, generally vehicular contraptions, including the beloved LOLrioKart.

LOLrioKart takes up a good portion of floor space in the back half of the room and is occasionally used to store all my crap. It’s also a pain to move around because of its mass, and a pain to work on the electricals because they are all very low to the ground. If I want to test the drivetrain, I had to lift the kart and balance it on a set of automotive jacks. Don’t even mention that time I had to swap the battery packs…

So for a while, I had wanted a lift or crane to suspend the kart from. I didn’t take the idea seriously until Spring term ended, when I started looking for options. I became partial to a ceiling-mounted hoist because of the ability to send the kart all the way to the top for storage and extra floor space.

The kart only weighs about 200 pounds empty, which is a essentially trivial load in the world of winches and cranes. MIT building N52 used to be a factory, and factories in the early 20th century were built to last forever. The ceilings are all solid concrete, more than a foot thick. Essentially, almost anything would have worked, and I briefly considered just gearing down a beefy DC motor instead of buying a specifically designed winch or hoist motor.

But as luck would have it, Craigslist produced a pristine example of an ATV winch for sale locally, so I quickly jumped on it.

This Master Lock (I thought they just sold locks, but I was wrong) unit seems to be a pretty standard offer in the world of cheap generic utility winches. It made some substellar sounds when loaded and the drum finish was pretty rough, but I’m going to assume that it won’t kill me. Too badly, anyway.

The mounting holes in the winch frame were located in a place where I couldn’t access them with a powered screw driving tool. They were designed to be mounted to brackets first, which are in turn mounted to your choice of stationary reference frame.

…so I had to devise my own. This 3/8″ aluminum plate was just hanging out in the cave of materials. I could probably have waterjetted any number of small robot parts from it, but hey.

The two large middle holes are countersunk on the other side to fit 5/16″-18 socket head cap screws. The six surrounding holes are countersunk to fit some 1/4″ flathead concrete bolts. MITERS had a large stock of “tapcon” style concrete screws (which do not use anchors), probably from back when we bolted stuff to the ceiling all the time.

Because bolting things to the ceiling isn’t exactly a precision machining activity, I used spraypaint and sprayed a pattern into the ceiling, using the mounting plate as a template.

The winch itself is mounted using two 5/16″-18 socket head cap screws and grade 8 nuts and washers. This should not be the first failure point.

A little while later…

I borrowed a hammerdrill and a 5/32″ concrete bit and went to town on the ceiling. Reportedly, the hammering noise was ungodly loud, even on the third floor. I guess that’s what happens when you bang on a solid concrete building.

I learned that a hammerdrill is best used not under intense drilling pressure, but rather under modest pressure. If you push too hard, you dampen the chiseling action and the effect is diminished. This was well reflected in me taking almost half a minute to drill the first hole – but the last only took 5 seconds.

Unfortunately, attempt #1 to mount the winch didn’t go well. I made the mistake of reading a different box of screws (which specified a 5/32″ drill). 1/4″ tapcon screws need a 3/16″ drill. The difference meant that I managed to shear off the screw halfway into the final depth.

Epic fail.

I quickly went back with a 3/16″ bit to expand the other holes, and the rest went well. Friends and cohorts spotted the high-altitude work and helped hold the 25 pound winch up while I drove in the screws.

But after much sweat, concrete dust, and loud construction noises…


Well, at least I know my five-bolted rig can hold up 1 LOLrioKart. The only power supply strong enough to supply the current demand of the winch was a big Optima lead-acid battery.

Because this is a shady winch being held up by shady screws into shady century-old concrete, we started piling heavy things into the kart to see if we could find the maximum load. Helmets and face shields were aplenty during this exercise, because even if the kart was only 1″ off the ground during it, the falling 20-odd pounds of steel were a concern.

Things piled into the kart include two truck disc brakes (60 pounds), the lead acid battery (50 pounds), the Defibrillator (a.k.a the kart charger, 25 pounds), one brushless Etek (25 pounds), a huge linear power supply (25 pounds), and a milling vise (40 pounds). Powered lifts and interrupted drops were attempted to put force on the mounting, but it was solid. I think it’s proved itself.

Assuming I did install the screws correctly and that the concrete is not crumbly, each 1/4″ concrete screw is rated to a maximum of 1,100 pounds assuming a 1.5″ depth. There are five holding the plate to the ceiling for a cool ultimate tensile strength of 5,000 pounds. Even accounting for imperfections, the winch should stall long before the screws pull out. It’s still unlikely that I’ll ever allow anything more than the kart by itself to be hoisted, or items of similar weight, because it can get overhead and that can end badly.

Yup, it’s a hoverkart. Any questions?


Jun 15, 2010 in Project Build Reports, RazErBlades, Reference Posts

After two weeks of nervous, anxious anticipation…

SMALL CUTE HALF BRIDGE BOARDS! They’re so clean… so shiny… so detailed… so…

… expensive…

I ordered 4 (+1 free) from Advanced Circuits shortly after posting about them. Over the course of 2 weeks, I got no less than 1 postcard, 1 thick envelope (which I thought contained my boards) full of brochures, a round PCB drink coaster, and three sales representative calls asking me how I’m doing and whether or not I had any order questions.

And with the boards, I got a little packet of free microwave popcorn.

Advanced Circuits is like a grandmother or gift-pushy uncle. I’d actually appreciate it if they laid off the customer appreciation and just got me my damned boards faster. That means more than any random token ever will.

Anyways, 5 is enough for one split-pi converter and 1 3 phase motor driver bridge. So there may be some more minor power conversion experiments in the future.

While waiting for the boards and the WHERE THE FUCK ARE MY BATTERIES, STILL? for Deathblades, I decided to make a second iteration of the “Double DECer” board.

Alot cleaner, isn’t it?

Shortly after finishing the previous iteration and  debating myself over component placement and available volume, I discovered there was really no problem at all.

In designing the most recent drawing of the ‘blades, I mistakenly constrained the top of the battery pack to be 5 millimeters under the edge of the aluminum sides. When I changed the battery pack spec, I only changed the part dimensions and not that constraint. In reality, then, what seemed like only 5 millimeters of space was actually 23mm. I thought it was a little weird to have a 31mm tall battery fill up a 54mm cavity almost to the brim.

I then remembered that PCBs can have two sides, which was instrumental in creating the new layout. If I put the Xbee and DECs on opposite sides of the board, then they won’t conflict with eachother volumewise!

The new layout reflects this. On the “top side” sit the Xbee, glue circuitry, bus capacitors, and I/O connections. The DECs, now turned to face eachother, occupy space on the board’s bottom, and the “overhang” they provide is used to park the 3.3v regulator. All the control pins are right there and there’s no more cross-board running of signals.

I was even able to add some real mounting holes. The outer dimensions are within Eaglol’s 4 inch X-limit, and the board is 1.5″ wide.

This is a board that is actually worth sending out now.

Deathblades: Enough for Cosplay

Jun 14, 2010 in Project Build Reports, RazErBlades

This week has just been a torrent of Deathblades work. I’m (kind of…) proud to say that the skate motors are all finished. Well actually, two of them still need their share of custom arc magnets, which I hope to take care of soon through Supermagnetgeorge again. At the least, they can support my weight and I can skate around unpowered.

In other words, I’ve successfully built a set of roller blades. Hurray.

Yesterday, I was able to terminate and test one motor, so today I repeated the process for all of the remaining ones.

Here they are, sitting on the “drying rack”. Again, I kept C-clamps on the pigtails so they would be pulled down as low as possible. This time, I mixed up some thin laminating epoxy and let it flow across the wires. The 5-minute stuff I used before was sort of gel-like and didn’t really flow well.

To make the thin epoxy set in under a day’s time, I added a few times the recommended amount of hardener. This probably trades off alot of strength, but it’s not really structural anyway.

Know what’s cool? Having two motors.

Know what’s not cool? Not having enough breadboard space to put another DEC rig on. I wasn’t that interested in pursuing the simultaneous control of both motors immediately, so I decided against mocking something up. To test the other motor, I just swapped wires.

What I found very interesting was that the motors were heavily timed – possibly up to 30 degrees difference between the two directions.  Both motors registered about 1,600 RPM in the “reverse” direction, where reverse is defined as the direction the frame would fly in if I dropped it on the floor with the motor spinning. They only achieved around 1,300 in “forward”.

Additionally, one of the motors required a cyclical shift of the phase terminations (i.e. motor-A to controller-C, C to B, B to A), but the other one only ran with A and C swapped but B unchanged.

Motors are strange.

The fake motors get the red wheels. I only ordered 2 sets of magnets and haven’t gotten around to ordering the rest, so for now one skate (the left side, as I’m right-dominant) will have dummy motors.

Or, if you think of it another way, motors with really really crappy Kt.

So what did I do with two dummy motors? Put the dummy skate together!

The stock ‘blades used a very unique M6 bolt with a very flat and broad head to attach the wheel frame to the boots. I wanted to keep that bolt since it was unlikely that I could find a similar bolt.

Consquently, I decided to extract the matching nut because there was no way you could get me to dig through all of MITERS for a M6 nut.  The stock wheel frames split in two after all hardware is removed, so extracting the nut was simple.

The stock nut was also a very broad kind, which translates to a bit more rigidity.  Unfortunately, I can’t remove the boot without also removing the wheels. Oops.

And here is the dummy skate.

I decided to orient the motors such that their cables faced inwards. This is probably a position that’s safer in terms of snagging. The good news is that they all reach to the middle of the frame, so any conceivable control board orientation is achivable.

The bad news is there’s no board to attach them to yet. Sigh.

And here’s both of them!

Clearly I’ll have to take these apart again to install the rest of the components, but in the mean time, publicity shot!

I took a short unpowered run around the hallway to see if they were still useful as.. you know, skates. The LRK winding and magnet arrangement yield very little drag and ripple torque. I suspect my bearings are contributing more loss than the motor drag. Overall, they “skate” well.

So if the motors or batteries ever become dysfunctional, the whole thing doesn’t become instantly useless. Such is the beauty of hub motors.


Deathblades: The Double DECer board

Jun 13, 2010 in Project Build Reports, RazErBlades, Reference Posts

Once upon a rainy day in Boston, Charles sat in his free scrounged office chair, slumped over the armrests. He was focused intently upon his 17″ LCD monitor, its glow filling the darkened, humid room. The ambiance was only disturbed by the sound of raindrops upon the dusty window, whose blinds were drawn such that he did not have to think about the fact that it was raining outside and he really, really hates rain and doing anything or going anywhere in the rain so he didn’t go MITERS to keep adding sensors onto the motors and…

Alright, that story went nowhere.

I did take today to think a little more about controlling the Deathblades. At this point, I knew that

  • I was going to use the Maxon DEC modules
  • XBEE radio units would handle communication between the input device and the skates.
  • … There will be a handheld control input device. With, like, an XBEE in it.

However, all these thoughts a controller do not make. Taking advantage of the rainy day, I took my Course VI skills out on a second test drive and began laying out the internal control circuitry for the skate motors. The DECs, as bare boards, aren’t really conducive to hacking together. I would need a solution which supplies them with power and auxiliary components, and as long as I have those on a board, I might as well put in communications as well.

Now, if you had asked me even a few months ago, I’d have just whipped together something out of protoboard. But in the interest of legitimacy and experience, I’m going to have a real PCB made.

I started by drawing out the schematic of the board. Core components such as the XBEE and DEC modules were added and “wired” first, then support circuitry added as needed. I had to make several custom devices for this board, one of which was the DEC module itself.

The XBee will used in just about the simplest fashion it can be – a direct, no-microcontroller, digital and analog I/O bridge. One of its analog (PWM, actually) pins will drive the speed input pin on the DECs, and a digital I/O will toggle the Enable pins so the motors can coast – otherwise, there’s a dynamic braking effect. Because the XBees run only on 3.3 volts (Digi should fix that, really), I added a 5v to 3.3v LDO regulator, which draws power from the Hall sensor output (VCC_HALL). The DECs are rated for “35mA” output each, so I’ll see how conservative that really is.

While making this schematic, I had the chilling realization that the XBee’s 3.3 volts maximum output will never drive the DEcs to full throttle.

Uh oh. So I had to somehow level shift 0-3.3v to 0-5v. My first instinct was a noninverting rail-to-rail op-amp set to 1.5x gain (which is about the ratio between the two voltages), but that was just… so analog. The next option is a bidirectional level shifter like this Sparkfun unit, which is available for an almost trivial price. Problem is, that meant making yet another custom component. I was getting tired of having to whip up my own parts at that point, even if all it amounted to was copying and pasting footprints and symbols.

… so I took the discrete path out and spec’d some SOT-23 signal MOSFETs and 1206 SMT resistors. This will officially mark my foray into surface mount parts, something which I PROMISED PROMISED PROMISED to never EVER EVER do. But TO-92 cases just looked bad on a board, so there. There are two stages of the inverter such that the PWM signal remains rectified.

After the level shifting, the signal goes through a low-pass RC filter with a break frequency of around 160Hz before splitting to the two DEC modules.

What happens after  you make a schematic? You hit the “Board” button and Eagle piles everything onto a blank PCB representation. You then unchain your inner OCD and watch the board come together.

Well, here’s most things. I discovered that even the DEC modules will have a hard time fitting inside the ‘blades. Two reasons contribute to this:

  • Eagle’s free version limits you to 100mm long boards. The DECs had trouble fitting in crosswise because the boards are 1.75″ wide, but the internal skate cavity is only 1.6″.
  • Within 100mm, I couldn’t fit the DECs “longwise” and still make room for the XBee.

So for now, I’m going to hedge my bets on the fact that the 2.6Ah lithium polymer pack is true to its stated dimensions. If they are, then the DEC boards will be elevated above the level of the aluminum side plates, which means the boards can be 1.6″ wide with no trouble. The layout above reflects that.

Most of the way completed. The tricky part of this circuit was, oddly enough, routing the power connections. Otherwise, it still has modest componentry and convenient routing characteristics, unlike some weird shit like this.

Now the board has been routed to my satisfaction. The top layer text says “DOUBLE DEC’ER BOARD” and the bottom one “ETOTHEIPIPLUSONE.NET”, and both are in copper.

I couldn’t decide on a more productive use of the “overhang” space under the left DEC – but maybe later.

With luck, I should get these boards in the same timeframe that the USPS and China Post figure out what to do with my battery packs.