Liar’s 3D Printing: Multiple Colors with One Extruder

Good 3D printers now have multiple hot ends. You ought to be able to print in different colors or print support material. However, a lot of us don’t have multiple hot ends. Turns out, you don’t have to have multiple hot ends to print in multiple colors. To accomplish that you need a lot of patience and the willingness to tell bald-faced lies. Don’t worry, though, you’ll only be lying to some computer hardware and software, so that doesn’t count.

You may have seen people talk about putting a pause between layers to switch from one color to another. That works, but it limits your options. For example, if you want to put some colored text on a different colored background, you have to either have the text poke out, or it has to be “under” the background. It can’t be flush if you only have a single extruder and hot end. My method is a lot more trouble, but it can generate good results.

Keep in mind, with hobby-grade printers, multiple color printing has a lot of problems even if you do have multiple extruders. This isn’t a panacea. But you can get results on par with a similar printer that has multiple heads.

Bottom Line Up Front

Here are a few pictures of test prints that use this technique. A Monoprice Mini printer with the stock extruder and hot end created them using different PLA filament. On the left is a test cube, with a color spot in the middle of the layers (as well as some spots on the top surface you can’t see). To the right is a plate with my call sign in a contrasting color. It is hard to tell in the picture, of course, but there is one surface. The text is at the same height as the yellow surface.

I didn’t spend a lot of time making these prints since I was more focused on perfecting the methodology. The layer heights aren’t very fine, the infill is sparse, and the print speed was fast. However, you could invest time into making better-looking prints. You can also use the usual techniques that you use with a “real” multi-extrusion printer (such as priming towers, ooze shields, etc.).

The Concept

As I mentioned, it is old hat to stop the printer between two layers and switch filament out at that point. Usually, you’ll manually edit your G-code or use a simple application or plugin. We’ve even seen people who just time it. I wanted a different approach that didn’t limit me to one color per layer.

The trick is to lie. Any slicing software that supports multiple extrusion has a way for you to tell it how many extruders you have. I use Slic3r and Repetier Host. In Slic3er’s printer settings, there’s an entry for Capabilities/Extruders. I simply told it than I had three extruders (you can tell it more or less, but three seemed to be a good number; you can always change it later). I then made the same change in Repetier’s printer settings. If you really had multiple heads, you’d need to tell the program how far apart they are and other details. But since ours are just pretend, we can leave the offsets at zero and don’t really need to include any other information.

Of course, that isn’t all you need to do. I also added to the Custom G-code setting, also under printer settings in Slic3r. In particular, I added this custom piece of code for a tool change:

M83 ; turn on relative movement for extruder 
G1 E-5.000000 F6000 ; retract filament 5mm 
G1 X0.000000 Y0.000000 F9000 ; home X and Y axis leave Z at current height 
G91 ; note: For Marlin this make E and XYZ relative; for some it just makes XYZ
G1 Z10.0 ; obviously, this limits your print height by this amount!
; Note Marlin treats relative different from others

M84 E ; release extruder stepper motor from 'holding' position 
@pause Change Filament for [next_extruder] and set [temperature_[next_extruder]] degrees ; pause print!
G90  ; back to absolute
G1 X0.000000 Y0.000000 F9000 ; upon resume, rehome X/Y in case position was bumped out 
G91  ; bring Z back
G1 Z-10.0
G90  ; and back to absolute
G1 E0 F6000 ; reset extruder, ready to push out plastic again 
G1 F9000 
M82 ; set extruder movement back to absolute ready for next layer

You may want to vary this code a little and–of course–you can omit the comments (the semicolons and everything after them). The basic idea is to pull the filament up to reduce oozing, move to location 0,0 and then use @pause to make Repetier stop and prompt. You can now change the filament out. You could, presumably change temperatures if you wanted to (I didn’t need to). If you are trying to get clean colors, you have to purge the nozzle (that is, run the extruder until the new color shows up). If you want an artistic fade, you could skip that step–totally up to you.

When you exit the pause, the script puts everything back the way it was and the G-code continues with the print. You will get some “bad extruder” errors as the G-code tries to switch extruders, but–at least on my machine–it doesn’t hurt anything.

By the way, it was tempting to try to move everything relative so that the script could put the head back in the right position. However, my printer doesn’t police going out of bounds, so that wasn’t really practical. On the other hand, Slic3r assumes you might have moved things around so after the tool change, the first thing it does is moves back to the known position. However, it would have been nice to line up on the old position in the XY plane and then bring the Z axis down. As it is, if you have a little too much extrusion, you could drag the head over your print. However, if your layer heights are accurate, you shouldn’t have that problem.

The Price

There’s no free lunch. The slicing software minimizes tool changes, but you still get tired of pulling filament in and out. Printing a 400 layer octopus with two colors is probably beyond everyone’s patience level. You really want as many layers as possible to be a solid color, just to save wear and tear on your hands and your patience.

You also need to plan your models so that there is sufficient volume of each color to show up. That’s true even with a multiple head machine, though. For example, on the callsign plate, if the callsign were a single layer of purple, it wouldn’t show up well at the 80 to 100 microns I usually use for printing. Also putting light colors on dark colors takes more volume. You will have better results with large things. You probably are not going to get the callsign  down to a four-point text size. Again, that’s true even if you had mutliple extruders with the same nozzle and layer sizes.

Making the Model

There are a few ways you can represent a multiple color model. The most common is to simply have a separate STL file for each extruder. Even though I only have one extruder, to make good on my lie, I need separate STL files, too.

Next time I’ll show you how I created those models and how to load them (or any multi-extruder STL files) into Repetier Host. It is a lot of work. But if it makes the difference between getting the job done and having to send it out, maybe its worth it. Meanwhile, you can download the STL and the source files, if you want to experiment.

11 thoughts on “Liar’s 3D Printing: Multiple Colors with One Extruder

  1. People are already using Y adapters and modifying g-code intended for multiple extruders.

    You still need a wipe tower when changing, of course, but you use a bowden setup with a Y immediately before the hot end, and dual extruders.

    G-Code retracts current filament back past the Y, then pushes the new filament out to the hot end.

    It works pretty well, is a very simple setup even for a printer like the Monoprice Select Mini because you don’t need to add carriage weight/mount a new hot end, and account for offset for multiple hot ends, you just need a second extruder *somewhere* to drive the second filament.

    It works reasonably well, though you do need to have a tower being built where you can purge the remaining melt in the hot end to ensure a nice color change and no blobbing on startup.

    1. Yep, this is exactly how the guys at Prusa implemented it. It’s a simple and clever system. I will try something similar on my printer for sure – looking forward to 2 color prints.
      I am not a big fan of manual filament change – to change it once or twice per print, OK. But to change it twice every layer (and still have spills from the first non-retracted filament), no, thanks.

      1. The simplicity is what appeals to me. I’ve got a mini myself, building a d-bot, and the d-bot will have a two-color setup this way.

        It’s more practical than a dual hot end setup, though it does entail dealing with the limitations (and advantages, to be fair) of a bowden setup. What’s more, the software support already exists, as it’s fundamentally the same as running a dual hot end setup (which also uses two extruders).

        It’s the best implementation for multicolor/multimaterial printing I’ve seen to date, and the simplicity is a big part of why.

    2. Yeah there have been plenty of 2 and 3 head hot ends. But if you have a single extruder/hot end, I wanted to illustrate how you CAN do actual multicolor if you are willing to trade off your time and effort. Not for everyone, but not really the same as installing new extruders and an adapter or mixing hot end.

      1. That’s the point of this, though – it’s a middle ground. You DO need another drive, but NOT another head/hot end. So, it’s not a trivial retrofit, no, but it allows multicolor printing without manually changing filament every layer which would be absurdly time consuming.

        Installing multiple hot ends is way more complicated as you still need multiple drives, but you also impact the speed you can print at an accuracy by increasing the mass you’re moving.

        Manually changing filament is possible, but… Having tried it once, I can sincerely say that it’s a horrible process fraught with peril.

        Adding an extruder and a Y adapter on your hot end is a much better way to get into multicolor/multimaterial printing imho.

        Don’t get me wrong, I’m not faulting the article here. It’s good stuff, and the gcode script is gold, just saying that taking this one step further is not very hard and makes printing a 400 layer multicolor print a breeze.

        Brought it up mostly because the Y adapter/dual extruder/single head setup is a fairly newish approach and not as well known as muktihead setups.

        1. Well not to knock Josef who has done so much for the community, but E3D had the Cyclops out years ago which is 2 in and 1 out. The Diamond hot end (http://reprap.org/wiki/Diamond_Hotend) has been around awhile too. What I see lacking is mainstream slicing support (or maybe documentation of; I know Slic3r has a mysterious checkbox to tell it that you only have one real hotend, but I don’t know how that affects its output) or at least examples of tool change scripts (like this one) for those heads.

          Don’t get me wrong. I’m not suggesting that manually changing filament is the best way. I’m saying it can be done if you are hard up enough to do some spot color and you don’t have a machine that will do it. I have seen a lot of discussion about changing color per layer, but it surprised me I’d never seen this trick before because it seems obvious, though tedious. Maybe just no one has the patience to do it ;)

          1. Yeah; in all honestly I wasn’t aware Josef had added it to the Prusa project at all, I’ve only seen it actually done in the Mini and DBot communities (this is likely simply a factor of where I tend to hang out, mind you).

            It’s still in it’s infancy, though, there certainly isn’t any mainstream slicer support.

            Manual filament changing has been a thing for a long time, though, but as you said nobody really has the patience for it – the recommendation is usually a simple pause+manual change+resume, but it’s something people try once and never do again because it’s a nightmare :)

            The only time it’s really not “I’d rather poke my eyes out” is when you’re looking at just changing from one filament to another once, but two colors per layer with manual changing…. *shudder* Even with my mini, I run a .0875 layer height; a 1cm high two color print would involve ~120 filament changes. Gross :(

          2. I have seen lots of manual filament changing done on layer height or filament length or time but that gives a crude result. Josef’s web app to do a manual switch at layer height was what got me thinking about this in the first place.

          3. The e3d diamond is a heavy old chunk of metal (brass) when you get it all assembled though, I bought one and was going to fit it to my printrbot simple metal and run 3 bowden extruders but it just felt too heavy, so I’ve gone to a much lighter dual kraken style nozzle bolted the side of the head fed by two bowden tubes and kept my direct drive original.
            The diamond is getting used in a qc30 holder to turn my bridgeport cnc into a large format 3d printer for those rare occasions I need to print something bigger than my printrbot can handle so not all is lost…
            There’s a diamond group on facebook dedicated to working through multi colour firmware/printing issues. Probably loads of forums too..

    3. This sounds a lot easier than my idea to have a station that the head parks under, which retracts the filament, then moves the head to another station and extrudes new filament into the extruder, just like changing it by hand with your fingers.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s