Saturday, July 27, 2013

Drew's Rostock: Replacing the J-head

Several months ago after slightly reworking the wiring to the J-head, the thermistor slipped slightly loose from its socket in the heater block.  The temperature monitoring code in the controller will detect a short or open connection on the thermistor and shut down the heater, but it can't do anything to detect a thermistor that is simply no longer thermally connected to the block, and the heater stayed on long enough to drive the heater block far above its normal operating temperature.  I knew something was wrong when the plastic coming out of the nozzle was bubbling.  Fortunately I noticed and shut the printer down before the plastic J-head barrel was completely ruined, but there was still damage done.  Ever since then the head's been prone to jamming, hard to feed filament into, and reluctant to let go of the filament when I'm trying to change colors.

I noticed a marked drop in reliability while printing the second version of my Tardis Transformer.  Trying to print faster than 30mm/sec inevitably led to a complete filament jam, often requiring a complete dis-assembly of the entire extruder from hot end to pinch wheel to fix.  Finally the entire thing jammed up with a plug of plastic in the barrel that just couldn't remove without destroying the J-head.  Fortunately I had already ordered another J-head, this one with a 0.35mm nozzle as I wanted to experiment with printing more detailed part.

Here's the new head, mounted in the plastic carrier that I use to attach it to the end effector on my printer.  The carrier is two pieces of PLA that clamp the end of the J-head, with guide holes for wires and a place for the push-fit connector to screw in.  In theory, I shouldn't be using PLA to clamp the hot end, since the hot end gets more than hot enough to melt PLA.  In practice, the top end of the plastic barrel never seems to get even close to being hot enough to damage the plastic clamp.

The new J-head seems to be using a different kind of plastic than the previous one was, dark-colored as opposed to the pale tan of the older one.  I'm not sure if this makes any difference, I suspect not.
Wiring the hot end is always tricky.  This part of the printer sees constant vibration, and the wires need to be able to flex freely yet not crack from flexing or vibration.  I've secured the heater resistor and thermistor into the heater block with fire putty, and additionally secured the thermistor cable to the J-head barrel with heat-shrink and copper jewelry wire.  This should help keep it from pulling out of the head again, as well as help protect the fragile thermistor wires from vibration-induced failure.
The final step is to wrap the heater block with insulation tape and Kapton.  This might not be strictly required, but it seems to me to help the head maintain a consistent temperature.  A few overwraps of Kapton tape also additionally helps keep the thermistor in place.
 The main downside to moving to a smaller nozzle is that it will take more force to push filament through the nozzle.  Rostock-derived printers already need a lot of force, with the long Bowden tube and (ideally) high print speed, and even with a 0.5mm nozzle it's not hard to exceed the torque your stepper motor and motor driver chips can deliver.  Fortunately I'd installed a geared extruder on my printer months ago, while trying to push the upper end of its printing speed.

I could have bought a geared stepper motor, or fit a gearbox on to my existing stepper, but to save money I decided to try and build my own gearbox first.  I got the idea after printing this amazing 6-speed automatic transmission model.  Printing and building it convinced me that the quality of parts from my printer were high enough to actually make working gears, so I set about designing my own geared extruder.   While the gear teeth were perfectly fine, the plastic-on-plastic bearings had far too much friction for an actual functional part, so my gearbox was designed to have R4RS bearings (chosen because I had 10 of them on hand) pressed into each gear.
I also replaced the plastic pins in the original transmission with metal shafts.  Here I'm using three 1/4" shoulder bolts (again, chosen because I had them on hand) with the heads cut off to couple the planet gears to the gear carrier, and a M5 machine screw as the shaft to connect the carrier to the filament drive pulley.  Using a machine screw as an output shaft is sadly not optimal.  I've managed to size it so the drive pulley is completely on the unthreaded part of the bolt (rather than resting on the threads), but the bolt isn't exactly the same diameter as the bore of the pulley, so there's a little bit of eccentricity as it turns.  That translates to a slight variance in punch pressure as the extruder runs.  This doesn't seem to be a problem yet, but I'd really like to replace that part with something custom-machined.
The extruder itself started off as a modified Airtripper design, but as is typical I've completely redesigned it from scratch.  Rather than two or four compression bolts I have a single bolt with a large hand-friendly knob pressed onto it.  This lets me easily and without any tools adjust the pressure on the filament.  It also lets me easily unclamp the pinch mechanism to completely release the filament, which I prefer to do when changing filament colors.  It's still not an ideal design - it takes a lot of turns to completely release the filament, and the threads on the screw strip after a few hundred cycles.  I've been meaning to redesign this with some kind of clever fast-release over-center clamp mechanism.
The completed extruder is admittedly huge.  The plastic gears work wonderfully, and have run for hundreds of hours of printing without any problems, but I did have to make them fairly large to handle the load.  A metal gearbox wouldn't have been any wider than the motor itself.  It's not really a problem since the extruder doesn't need to move or fit in a compact space, but can just sit out of the way at the top of the printer.

Looking up into the top of the printer.  The extruder mechanism is at the center.  The filament reel is on the top of the printer, with the filament fed down through a hole in the center of the upper plate.  Two small white LEDs are aimed at the point where the filament is pressed against the drive pulley, these cast enough light on that spot to let me see the filament drive is working properly.  I also have three fans arranged around the top end blowing air down into the print volume.  I'm not sure if these do much useful, but they look kind of cool.  You can also see my cheap little printed cable clamps, the heatsink for the 5V regulator for the fans and LEDs, and the terminal blocks which let me easily disconnect the cables to the end effector.

In addition to replacing the J-head, I've been experimenting with smaller layer height.  The default layer height setting on Slic3r is 0.4mm, which worked well enough for me when using my old 0.5mm nozzle.  The first few prints with the new nozzle were at 0.3mm, which along with the smaller nozzle made a noticeable improvement in print quality.  I tried pushing the layer height smaller, and discovered the microlayering function in Slic3r, which allows you to have different layer heights for perimeter and infill layers.  Unfortunately, when I tried printing objects at 0.135mm (with 0.27mm infill) I ran into an annoying bug where the printer would consistently freeze up mid-print when printing certain objects.  I've backed off to 0.18mm (with 0.36mm infill) which seems to be a sweet spot for reliability and detail on my printer.

Why those particular oddball heights?  My printer uses 36 tooth, 2mm pitch pulleys, motors with 1.8 degree step angle, and motor drivers with 16:1 microstepping.  If I've done the math correctly, that means that the physical resolution limit of my printer is 0.0225mm.  I had the idea that for consistent prints the layer Z-height should be an integral multiple of this resolution.  0.18mm is exactly 8 times the resolution limit, or equal to one half of a full 1.8 degree step of the motor, and the 0.36mm infill is happening exactly once per full step.  Given the way that a Delta printer works, where the physical Z height is determined by the combined action of three different motors, this may not matter as much as it would for a conventional cartesian axis printer.  I figure it doesn't hurt either, and with the 0.18mm/0.36mm layer height I'm getting some amazing print quality.

Monday, July 8, 2013

Tardis Prime - Version 2

I designed the original version of this toy as a personal challenge to see if I could - and in the process learned a lot about how to design complex moving parts for 3D printing.  The design was vastly more successful and popular than I expected, resulting in a lot of requests for printed copies, but I wasn't really happy with it.  The major body joints - hip, knee, waist, elbow - were all too wobbly and weak.  In robot form, the toy couldn't stand on its own, and the legs would sometimes even fall out when it was picked up.  The Tardis form didn't lock together well, with the legs spontaneously unfolding sometimes when picked up.  Several of the pin joints were prone to breaking, too much force applied across the grain of thin plastic pins.  It was also expensive and time-consuming to print, taking over a pound of plastic and several days of machine time.

I started over from scratch with the design, to make something more suited to be a mass-produced toy.  I scaled the original Tardis form by two-thirds (originally tried one-half scale, but my machine couldn't print the details small enough) and rethought every part of the toy to be simpler, easier to make, and more durable.  In the end I managed to reduce the weight to only six ounces, and reduced the part count from 71 to 36.  I also greatly simplified the leg joints, replacing the troublesome hip mechanism with one that used only horizontal pins that wouldn't fall out when the toy was picked up yet were still stiff enough to allow it to stand.
The torso has been significantly changed.  I kept the same shoulder articulation, but eliminated the sliding panels and telescoping neck in favor of simply rotating the head out through the open back.  The swinging windows panels are also eliminated, the back of the torso instead being closed by a piece of the lower back which swings up as the abdomen folds in.

The back of the legs are still fairly open, and the feet are basically just empty bits of body shell folded forward.  The legs were a major hassle to design, the new torso and abdomen structure took up a lot of the interior and in the end I was having to try and figure out how to fold stray scraps of Tardis shell panels into convincing legs and feet.
It can still sit down, but that's pretty much the extent of the leg articulation.  I had to sacrifice a lot of degrees of freedom in the waist and hips to make the body stiff enough to stand on its own.  The arms still have most of their mobility, although I did have to sacrifice the wrist joint.  There's just not enough room in the scaled-down hands to fit a plastic rotation pin inside.
Transformation starts by pulling down on the hips, unfolding the abdomen, lining up the lower back and hip plates, and then swinging the head back into the torso.

You then pull the telescoping black bar (that holds the head pivot stable in robot mode) upwards, swing the shoulder blocks inwards, and slot them together as shown.  This locks together tightly to make the top of the Tardis.  It took a lot of tweaking to get this to work properly, and I still think the bar is a little looser than it should be.
Getting the forearms into place is a little tricky.  There are pins and holes on the torso and forearm parts which lock them together in Tardis mode.  They're a little too secure - it's difficult to get the arms into place, and once in place they really don't want to come loose.  I still might need to adjust the clearances on these parts.

Transforming the legs is simple.  The feet fold back 135 degrees, making the flat bottom of the Tardis.  Note the recessed area and slot on the back of the folded leg assembly.

Then the legs fold forward and up.  A small post on the inner corner of each lower leg piece slots into a recess on the underside of the torso block, and the indented part on the back of the folded foot tucks into a locking ridge on the hips.  I didn't want this version to have the same problem with the legs spontaneously unfolding when picked up in Tardis mode.

It locks together extremely solidly in this form.  You can pick the Tardis up by any part of its structure and carry it around and it won't unfold or come apart - a huge improvement on the earlier version, which needed to be supported from the bottom when carried.
Still to do on this one:  make decals.  I wasn't happy with the look of the glued-on paper labels on the earlier version, so I'm looking for sticker paper that will work in my inkjet printer.  I'm also not sure how legible the labels will be when scaled down to this size.  When in Tardis mode, it's a surprisingly small toy - it's only four and a half inches tall, and two and a half inches wide.  Even in robot mode, it stands under nine inches tall.
It's almost like one of those puzzle boxes in this form, where you need to know exactly where to push on the outside to unlock it.  You start by pulling downward on the feet, at the back rear of the Tardis to unlock the friction tabs holding them in place.
You then pull the legs downwards and straighten them out as shown.  The pin joints in the hips and knees are angled such that the legs spread out slightly when unfolded.  Unfolding the legs also lets you loosen up the abdomen and torso parts enough to free the arms and shoulders.
The shoulder joints slide sideways with a little force, and the forearms come out at the same time.  It can stand in this form, even through the abdomen isn't properly locked together yet.

After freeing up the arms and shoulders, you rotate the head assembly 180 degrees to bring the head out of the torso, then slide the abdomen up to fold and lock the body.  The black bar on the back locks into the notch at the top of the abdomen and holds the head-pivot in place.  The rest of the back of the Tardis splits, the upper half becoming the rest of the back, and the lower half a sort of plate around the hips.

Straighten out the legs, and the robot stands easily on its own.  It's not very poseable, but I've decided that being able to stand is better than being a highly flexible plastic ragdoll.

That's version 2 of the design.  Like the original version of the toy, it was Featured on Thingiverse within a few days of being posted.  As of this writing the original version is at the top of the Popular Things list.  I don't expect this version to do quite as well - honestly I'm surprised that it was Featured at all - but it's gratifying to hear that other people are already printing their own copies.

Version 2 of this toy was a lot harder to design than the original.  Making something robust enough to be sold or given out as a toy is a lot more challenging than making a one-of-a-kind static model.  This design is still fairly crude compared to the actual commercial Transformer toys on the market now.  I've gained a lot more respect for what professional toy developers go through.

As with the previous version, a lot of people are asking me if I'm going to sell these.  While I may make a handful as gifts or to sell at upcoming conventions, I'm not intending to go into any kind of mass production.  3D printing simply isn't a cost-effective way to make a lot of something.  It's great for making prototypes, or limited runs of unique specialty items, but can't even remotely compete with traditional mass-production techniques like injection molding.  It takes my printer a full day of running nonstop to make the parts for one of these - and then an hour or so of my work finishing and cleaning up all the parts and assembling the toy.  I can't make these fast enough for it to be worth my time as a business.  Setting up mass-production is also out of the question - both due to the steep startup costs of having molds and tooling made, and because any actual commercial endeavor would bring down the wrath of the BBC's copyright lawyers (and possibly Hasbro as well).