Computing stuff tied to the physical world

Posts Tagged ‘CNC’

Laser cutter electronics

In Hardware, Software on Sep 19, 2012 at 00:01

The last part of this mini series about a low-cost semi-DIY laser cutter describes the electronics and firmware:

DSC 3506

In the middle is an MBED microcontroller based on an ARM Cortex M3 chip (NXP’s LPC1768). It runs at 96 MHz, has 512 KB flash, 32 KB RAM, USB, and an Ethernet controller on board (but not the magjack).

The whole thing sits on the custom LaOS board, which includes an SD card socket, an I2C bus, some opto-isolators, power-supply interface (+5V and +24V), and two Pololu stepper drivers (or nearly compatible StepSticks).

There’s room for 1 or 2 more stepper drivers, a CAN bus interface, and more connectors for extra opto-isolated inputs and outputs. The on-board steppers can be omitted with the step/direction pins brought out if you need to drive more powerful motors.

The MBED was briefly mentioned in a previous post, and can also be replaced by a suitably modded LPCXpresso 1769 board, at less than half the price.

The software is open source and has just been moved from the MBED site to GitHub. Note that at this point in time, the software is still based on the “” runtime support library, which is unforunately not open source. Work is in progress to move to a fully open source “stack”, but that’s not the case today – the Ethernet library in particular hasn’t been successfully detached from its MBED context yet.

Ethernet connectivity is based on the lwIP code, which in turn is the big brother of uIP. Big in the sense that this supports a far more capable set of TCP/IP features than would be possible with an 8-bit microcontroller and its limited memory. Having 512 KB flash and 32 KB RAM in this context, means that you don’t have to fight the constraints of the platform and can simply focus on getting all the functionality you want in there.

Right now, the LaOS firmware drives the steppers, using a Gcode interpreter adapted from gbrl, and includes support for Ethernet (TFTP, I believe) and the SD card. It also requires the I2C control panel. As a result, you can send a “job” to this thing via VisiCut, and it’ll save it on the SD card. The I2C-based control panel then lets you pick a job and start it. Quite a good workflow already, although there are still a fair number of rough edges.

(Note that if you listen very carefully, you can hear all the pioneers on this project scream for more volunteers and more help, on all sorts of levels and domains of expertise :)

What excites me about all this, apart from those über-cool laser cutting capabilities of course, is the potential to take this further since all the essential bits are now open source – and it’s not even really tied to a specific brand of laser.

So there you have it. It cuts, it burns, it smells, it’s yearning to be taken to the next level :)

What’s in a laser cutter

In Hardware on Sep 18, 2012 at 00:01

Let me describe this thing I ended up with:

  • mechanics: the main part is a solid bright red metal box with a few compartments:
    1. left = X-Y table
    2. right = electronics
    3. back = laser tube
  • electronics: the LaOS main board and an ATmega168 as I2C-connected control panel
  • water reservoir + circulation pump, for cooling, must be on when the laser is on
  • air pump (noisy aquarium type) – for “air assist”, keeps the fumes away from the lens
  • exhaust ventilator, mounted on the back, pushes the smelly & smoky air out

The pumps and ventilator are manually turned on from the front panel with separate switches. Not perfect, since this leaves room or operator error, but hey – it works.

Here’s a peek inside, with some packaging plastic still in place:

DSC 3512

The shiny plate height can be adjusted using 4 connected screws turning in tandem.

You can see a little fluorescent light in the top center, and the air exhaust underneath it.

A 35 Watt infrared laser is serious stuff (it actually requires a few hundred Watt to generate that sort of power). Once focused, that beam can do major harm – cutting through stuff is what it’s supposed to do, after all.

Safety comes in the form of a reed relay which triggers when the lid of this thing is lifted (top right above), another one when the lid of the laser on the back is open, and a mains power switch with a key. The lid for the electronics is locked (from the X-Y compartment). The transparent viewing area is of a special type which blocks laser light, and the whole thing is made of fairly solid steel.

The beam is invisible (scary, eh?), but a tiny red “pointer” laser is mounted inside, showing roughly where the beam will hit. Extremely useful while doing dry runs – which in turn is very easy to do: just start the laser with the lid open, and you can see where it’s going to cut. Given that the cutting area is only about 20×30 cm, that’s not a luxury – you really have to check whether the material is properly placed. Here’s that last mirror, deflecting the beam down into the final focusing lens:

DSC 3489

(Note: that’s not smoke, but the red panel’s reflection on the aluminium work surface)

The hollow tube is the “air assist”, blowing air to push the smoke away from the beam.

All the mirrors come pre-aligned and secured with a bit of hot glue. No need to tweak.

On the side is that little pointer laser. Since it’s tilted, the position of the spot is not exactly where the laser will hit, depending on how far into the material you place the focus spot. Focusing is actually quite simple: the laser comes with a little (lasered) acrylic piece, the side of which has a specific length. To focus, you place that on the work piece, and then lower or raise the object until the plastic spacer aligns with this metal mirror mount.

Raising / lowering the work piece is done manually. The whole thing sits on a (fixed size) “honeycomb” bed, which in turns sits on a manually adjustable metal “table”. Adjustment is done with a screw sticking through the bottom of the laser – and in fact the very first thing you need to cut is a piece of wood to act as large adjustment ring, which can then be grabbed from the front of the laser. Bit hard to explain, but then again this isn’t meant as assembly instruction – I just want to give you an impression of what sort of issues you have to deal with in such a setup. On the plus side: pioneering is fun! – with lots of opportunities to come up with clever improvements :)

Tomorrow, I’ll describe the electronics. This board (and the software developed for it) replaces the original board, which I’m told was hard to use, came with crude Windows-specific software, and was impossible to hack on and improve. The LaOS board has a microntroller, two stepper motor drivers, an Ethernet port, and various other bits and bobs needed to deal with everything in the HPC laser. It’s actually quite general-purpose.

Hello, Laser Cutter!

In Hardware, News on Sep 17, 2012 at 00:01

Yep, it has finally happened… it all started in July, when I got this (without the electronics board) and this (called the LaOS board).

The laser arrived like this:


This summer, a couple of early adopters in the Netherlands got together to figure out all the pesky little details that come up when you’re really just in pioneering mode. Make no mistake: this thing is far from ready for mainstream use. The laser itself is quite nice and ready to go, and definitely workable as far as all the mechanics go. But the electronics and software are still work-in-progress (I’m using the VisiCut software – which includes a driver that talks directly to the laser’s firmware over Ethernet).

Nevertheless – early as it may be, the total cost is less than €1,500 and you end up with an A4-sized laserable workspace which can cut up to 5 mm wood panels and 6 mm acrylic (engraving is more involved, but getting there). One of the first things we tried was this:

Image 1

Sure enough, the circle is a snug fit and turns perfectly. Excellent alignment!

I’ll describe a few more details of this setup in the coming weblog posts, but also want to point out that you too can end up with such a laser cutter (just make sure to arrange for ventilation – you’ll quickly get very tired of the burning smell and fumes).

There’s a project by the designers of the replacement electronics, called LaOS (Laser Open Source) – and it’s definitely the best place to go right now if you want to find out what’s going on. Warning: the site is currently undergoing a messy transition to a new wiki – I’ve helped out a bit and am sure they’d love to see more people join in the effort of making this thing more practical for the non-hacker crowd.

One little gotcha: these 35 W laser cutters are produced in China and then tested/resold by a company in the UK, and they are really large and heavy. Having one shipped from the UK to you is fairly expensive, because of the delicate glass laser tube (several hundred Euro, most likely). We got around that by getting organised and doing a “group buy”, with one person actually volunteering to go to the UK, load his car up with a bunch of laser cutters, and driving back (!). Still pricey, but less so, and I think the UK vendor is in fact willing to make arrangements when enough units are being purchased and shipped at the same time. Anyway – it’s an aspect to keep in mind.

But oy, oy, oy, this personal fabbing is fun :)

This logo is real!

In Musings on Sep 16, 2012 at 00:01

Real as in tangible, that is! (thanks, David)

DSC 4142

That’s MDF, sprayed in black and red, along with a plexiglass inset to hold it all together.

Created with my own laser cutter (sort of). And you can make a laser too, stay tuned :)

Parallel port UltiMaker

In Hardware on Nov 11, 2010 at 00:01

I’m currently building the Mantis – a little CNC router designed specifically to help create custom PCB’s. Actually, mine will look more like this.

I’m not convinced yet that this thing will be able to do PCB isolation routing, but I’m willing to give it a try. It’d make it much simpler to do one-off’s, instead of having to live with this:

But I’m not quite willing to dedicate an Arduino Mega and the UltiMaker electronics that is offered as option in the workshop. If you’re interested in 3D printing: the UltiMaker is derived from the RepRap and the MakerBot CupCake, as described here.

So instead of following everyone using the MPU-based approach, I’m going to re-use my parallel-port laptop running the EMC2 software, and let the laptop do all the work, instead of yet another dedicated board. I can always switch to a microcontroller setup later if this machine is practical enough to use it frequently. And if it doesn’t work out, my investment will have been relatively low.

There’s also a second reason for doing it this way: I’d like to build my own electronics for this CNC/3D stuff one day. I think there are better ways to do this sort of thing, more modular, more extensible, and more flexible (why not Ethernet? why not closed-loop servos?). But it wouldn’t be realistic to think I can take on that challenge as well, with everything else also going on at Jee Labs. So for now, the parallel-port shortcut will have to do.

Driving CNC stepper motors from a parallel port is a proven (but by now somewhat outdated) concept. Either way, it all ends up doing the same thing: executing the CNC world’s de-facto standard G-Code scripts.

You still need stepper motors, and stepper motor drivers, since a parallel port can only send out feeble 5V signals.

To save some time, I decided to try something a bit whacky by re-purposing an UltiMaker electronics board to hook up its motor drivers to the parallel port:

Screen Shot 2010 11 10 at 17.49.08

Lots of stuff on there I won’t need: heater control, extruder control, PWM…

Here’s a minimal setup, using just 3 stepper drivers and a little JeePlug board sitting on top of some extra headers on this board:

Dsc 2242

I patched a 5V regulator (plus LED) on there to feed the logic levels of the Pololu stepper drivers, and left everything else off, basically. Only thing left to do is wire up 7 signals + ground between the parallel-port breakout board and the JeePlug.

And then figure out the software side of things…

3D printing again

In Hardware on Oct 23, 2010 at 00:01

Finally found some time to fix the clogged extruder Mk4 I had on the CupCake. A new heater + extrusion head did the trick. Well, almost… watch the leaked blob of ABS on top of the extruder heat barrier:

Dsc 2138

As a result, the first part I printed did not contain enough material, and ended up too fragile for actual use. That’s part of a micro-lathe I’m printing for someone else, btw.

So I disassembled the extruder again, and replaced the PTFE rod with a new black one:

Dsc 2141

Yippie, now it’s working again. I’ve also upgraded to a heated build platform, which works great – no warping and the parts come off real easy, with raft and all:

Dsc 2148

Here’s a component from the Wade extruder which I’ll need for the Mendel:

Dsc 2151

Alas, not all is well yet. This was supposed to be the other half of that gearwheel pair:

Dsc 2150

Hmm, looks more like a cupcake to me…

The other nasty problem is that the main body of the Wade extruder I’m trying to build is too large for the CupCake. I can’t print it! Now I’ll either have to buy a complete extruder for the Mendel or find some other extruder which works with it. So as far as the next-generation “Mendel” is concerned, I still need to assemble the electronics and find some good extruder for it. Drat, it’s always those last 20% that bite…

Improved bracket

In Hardware on Feb 12, 2010 at 00:01

Encouraged by some comments on yesterday’s post, I printed the same bracket again, laying on its side:


The horizontal base comes out ok (I cleaned up the hole):


Interestingly, the top of the bracket isn’t filled in, which is actually better:


The sides look much better as well:


(the Skeinforge settings aren’t perfect yet, layers could be mashed smoother together)

But wow – what a difference this makes! Thanks for the tip!

Here’s another object, a Geneva Wheel from Thingiverse:


Turning is not very smooth, had to cut off some plastic from the round shafts, but hey: it works!

PS. Don’t worry, I’m working most of my time on JeeNode stuff, hardware and software that is… ;)

JeeNode bracket experiment

In Hardware on Feb 11, 2010 at 00:01

I just had to try making a little mounting bracket for JeeNodes…

Here’s the design:

Screen shot 2010-02-08 at 11.13.51.png

The design dimensions are 25 x 12 x 10.5 mm. It was created with OpenSCAD, which takes a description of the object and generates the solid model shown above:

Screen shot 2010-02-08 at 11.14.06.png

Does it work? Can it be printed? Can it be used? Yeah, sort of…


Works for JeePlugs too, since all the boards have the same 21.1 mm width:


Took me three tries to get the sizes and the little ridge right (the middle one):


Pretty ugly stuff, when seen up close. But hey, that’s what pioneering looks like!

The ridge which holds the board doesn’t come out very clearly – the features are not yet a match for what the JeeCake 3D printer can do (or should it be the other way around?):


But despite appearances, this bracket is already surprisingly functional. Apart from the awful surface and rough shape, it’s a springy and very robust little piece of ABS plastic. It could easily be screwed down, and it would hold the board quite well.

Fascinating, it’ll be fun to see how this evolves over the next few years.

Wireless works, sort of…

In Software on Feb 10, 2010 at 00:01

Ah, now we’re getting somewhere!

This is my current test setup:

Screen shot 2010-02-07 at 21.23.55.png

The JeeNode on the printer side implements a packet pass-through system, receiving command packets from the JeeLink and sending back response packets. Here is the sketch which does all the work:

Screen shot 2010-02-08 at 01.02.16.png

On the Mac/PC side, some Tcl code was added to go through the RF12demo text-mode protocol to send and receive arbitrary data, using the “a” command. Still work in progress, but the basic transport encapsulation works.

The tricky part is timing … it always is with this sort of real-time control stuff. Unfortunately, the current G3 software on the CupCake isn’t quite as responsive as defined in the specs. Some responses take way over 80 milliseconds to come back from the motherboard. This is the case when scanning the SD card, as well as when stopping the extruder motor.

So what this sketch does is wait up to 500 ms for a reply to come in. Even if there isn’t one, an acknowledgement packet will be sent back. The new code on the Mac in turn waits up to 1 second for that ack to come back.

If no ack came back, then there was an error in the wireless connection (this can happen either during the request or during the ack, there is no way to tell!). Probably best thing to do would be to resend the command.

If an empty ack came back, then the response packet did not arrive within 500 ms. In this case, we could send an empty command and wait for its ack. This hasn’t been implemented yet, but it will allow dealing with even the slowest responses, simply by polling a few more times with an “empty command”.

But hey – it works, and the output is the same as before:

Screen shot 2010-02-07 at 21.26.39.png

This is probably the first wirelessly controllable CupCake in the world :)

What I should mention though is that this doesn’t yet work reliably due to those very loose timing behaviors and the fact that packet errors are not yet dealt with. Test runs fail occasionally – mostly in the SD card access code, i.e. while grabbing all the filenames with NEXT_FILENAME.

Connecting to a CupCake

In Software on Feb 9, 2010 at 00:01

To follow up on yesterday’s post, I wrote some test code to request the extruder nozzle temperature from the JeeCake and send the results out over wireless. Here is the full “jeeStatus.pde” sketch:

Screen shot 2010-02-07 at 16.19.43.png

And sure enough, it works:

Screen shot 2010-02-07 at 16.08.55.png

You’re seeing the nozzle cool down, after heating it up via ReplicatorG. The connected JeeNode has been given node ID 19, and it’s transmitting in group 5 of the 868 MHz band, so I can simply track these incoming packets through the JeeLink which is already collecting all sorts of data anyway.

So much for the easy part – the real software will be more work!

Wireless CupCake

In Hardware on Feb 8, 2010 at 00:01

JeeCake, the CupCake 3D printer here, is an interesting mix of machine, electronics, and software.

The RepRap Motherboard is the main on-board controller, based on an ATmega644. It drives 3 stepper motors, communicates with the Extruder board, and talks to a desktop computer via its FTDI interface and a USB cable.

On the PC side (which can be Windows, Mac, or Linux), there is a Processing-/Arduino-like package called ReplicatorG to control the machine. It takes G-code, which is not related to Google in any way, but rather an ancient CNC control language from the 60’s.

ReplicatorG then converts this to a binary RepRap 3G protocol, as documented here and then uses that to drive the CupCake. Everything from moving the axes, adjusting the nozzle temperature, controlling the extruder motor, to writing settings in the machine’s EEPROM memory.

The neat part is that the v1.2 motherboard has an SD card adapter on board, and that the CupCake can run unattended by getting its detailed build instructions from files stored on an SD card.

Except for one little detail: there are no controls or displays on the CupCake, other than a few LEDs. This is not enough to select which file to print, adjust the zero position, or start a build. It looks like a new “Generation 4” design is on the way, including an interface board with an LCD screen and some push buttons.

Right now, you have to connect the machine via USB, start everything up via ReplicatorG, and then you can yank the USB plug and it’ll happily continue printing what it started, right to the end (well, except that on Mac OS X 10.6, yanking USB cables can lead to kernel panics – looks like a serious bug in the FTDI USB driver).

Anyway, I don’t really care for controls, or even displays on the CupCake. All I want is some way to control a unit sitting on the other side of the room, or in a nearby room. It can be fairly noisy due to some sort of occasional wood panel resonance, and having it printing right next to me is not really my idea of fun.

Which is where JeeNodes come in: wouldn’t it be nice to be able to control the CupCake via wireless? The protocol is already perfectly suited for it, since it uses packets of max 32 bytes – well within the 66-byte limit of the RF12 driver. And if the object being printed is already on the SD card, then only a few packets need to be exchanged to get going. During printing, some status info could be sent back – again very low rate stuff, easily within the JeeNode’s wireless constraints.

Here’s the idea:


Hook up a JeeNode to take the place of the USB cable, and let it behave as a RecpicatorG control program.

The interface needs to swap RX and TX for this, and because the CupCake’s signal levels are at 5V, two 1 kΩ resistors need to be inserted to prevent excessive current. One more detail is that the power pin on the FTDI connector is not connected, since the motherboard is powered off its own PC supply. So a separate wire needs to be added to power the JeeNode off the ISP connector right under the FTDI connector:


The one wire not shown here is the ground wire, running from top right to bottom left on the other side of this little custom interface board.

It turns out that the motherboard is actually powered from the 5V standby supply pin, so it’s always powered, even when the power supply is in standby mode.

I’ve started writing some code on the PC/Mac side to control the CupCake without using ReplicatorG. Here’s some sample code in Tcl which works when connected directly through USB:

Screen shot 2010-02-07 at 15.05.08.png

And here’s the corresponding output:

Screen shot 2010-02-07 at 15.04.35.png

As you can see, it can access all sorts of status info, read the file names on the SD card, and control the machine. This is part of a larger project, the beginnings of which are now in the subversion code repository.

It takes a lot of work to make hookups like these work, because there are so many different bits and pieces (literally) involved. The next step is to see if the JeeNode can indeed communicate with – and control – the JeeCake, and then code needs to be written to replace the current direct-USB connection by a packet-based wireless hookup through a JeeLink + JeeNode.

Oh, and then I need to create some sort of little on-screen control panel to adjust the nozzle temperature, jog the Z axis up and down, pick a file to print, and start the print job! Not to mention making it robust and secure…

Custom object

In Hardware on Feb 6, 2010 at 00:01

This is not what you might think it is:


I’ve been placing my headphone next to me on my desk for ages. There is of course never enough room on top, but plenty of spare room underneath:


So here’s my home-made headphone bracket:


Here’s the design, made with Sketchup:

Screen shot 2010-02-03 at 14.22.47.png

I just picked a “2” in a suitable font, re-sized it, “drilled” some holes in the base, and then “printed” it.

Piece of JeeCake!

PS. Given that CNC and 3D printing is not really the main focus of this weblog, I’ve set up a page on the wiki.

Update – design files added to Thingiverse.

One more 3D post

In Hardware on Jan 29, 2010 at 00:01

Ok, one last post on the CupCake CNC trials before I get back to JeeNode stuff.

The raft is now very solidly stuck to the base:


This thing really sticks well, with plastic pushed down into the criss-cross grooves of the acrylic base. The trick is to place a plain paper sheet between the extruder head and the base, and to lower the Z axis until the paper slides away with just a tad of friction.

Unfortunately, the next problem comes up – as seen in this first Geneva Wheel trial:


It turns out that the next layer of the raft doesn’t stick well to the first one. I solved this by raising the default 230° setting to 240° for the raft.

Another serious problem was that there is a lot of plastic on the right end of the raft as the print nozzle paused (!) on each turn. And the second layer of the raft doesn’t extend all the way to the end. This was solved by adding three noise-suppressing 0.1 µF caps to the extruder motor and disconnecting all the end-stop optocouplers.

The object itself seems to come out fairly well, though there were some blobs of plastic around the nozzle during printing which clearly interfered with the X-Y motion at times.

Here are over a dozen more parts, printed using black ABS for a change:


These all came out ok, but note that even these small parts take 10..15 minutes to print – each.

The biggest remaining problem is “warping” – it’s causing over half my trials to fail:


This part failed to build (should have been 20 mm high), it slowly came off the base and started interfering more and more with the extruder nozzle. At some point the nozzle got stuck in fact. Note how the thickness of the part is completely uneven. This is caused by the ABS cooling down and shrinking a bit – slowly pulling itself off the raft (with considerable force). A heated baseplate seems to be the hack to solve this – but that will require a lot more tinkering.

Oh well. We’ll get there… eventually :)

Update – upgraded to ReplicatorG 0012 with Extruder firmware v1.8 and switched to Zach Hoeken’s thermistor settings (raft setting reverted to original 230°). The last change was to shine a halogen light on the platform and object, to heat it up a bit – this seems to get rid of just about all the warping, yeay!

More 3D trials

In Hardware on Jan 28, 2010 at 00:01

It’s not as simple as it seems…

Well, the CupCake worked straight out of the box, which is of course fantastic. But printing does seem to have two tricky bits, called “extrusion” and “rafts”.

Here’s the printer making its third part:


What’s about to happen, is that the “raft” (that woven mat laid out on the bottom to hold the rest of the construction) is about to come off the base. In the above picture you can see two other problems: the raft itself coming apart, and a blob of plastic (front right) when the printer decided to pause for a few seconds, while the extruder kept pushing out plastic…

The problem seems to be that when the plastic cools down fully it becomes quite springy and rigid. Which is great for the final object, but causes trouble in keeping it stuck to the acrylic base. I suspect that the heated platform which people are experimenting with is to overcome this problem, by keeping the base slightly sticky for the duration of the build.

Or maybe a few wires extending further out from the raft would help, by “tacking down” the whole thing.

The other purpose of the raft is to even out the surface. In my case there is a slight difference in height across the base. I should probably try to get rid of that first.

Anyway, here are the objects made so far:


The meandering plastic retains its shape – that’s probably part of the magic behind all this.

PS. The stepper motors are noisy. I don’t think the software I’m using is micro-stepping right now.

CupCake #361 is alive!

In Hardware on Jan 27, 2010 at 00:01

Just got the missing part for the CupCake CNC 3D-printer in from MakerBot – partly their mistake, partly my mistake, long story… anyway – in the end they were extremely helpful in coming up with a good solution.

Which I had to try right away, of course ;)

After a bit of head scratching w.r.t. firmware versions and uploading, everything came together at last.

Here’s the first object getting printed at Jee Labs – whee this is fun:


After 8 minutes, it’s done and steps aside:


Mystery object…


After removing the “raft” and cutting off some loose ends:


So what is it? Oh, nothing spectacular really – it’s a Z-endstop for the machine itself. I figured that after us people doing so much to get it going, this machine might as well start working on improving itself right away…

I’m astonished by how well this first part came out. Very clean, very plastic’y, much sturdier than I expected.

All that’s left is to give this new beast a name – Jee3D? JeeCup? JeeCake? CuppaJeeno?


In Hardware on Dec 27, 2009 at 00:01

Spent a day with the family on assembling the CupCake CNC 3D-printer. Great fun!

Here’s where we are now:


The enclosure and all three axes have been assembled. As seen from the top:


Still remaining: the plastics extruder and the electronics – next week, hopefully!

Yeay, it’s drawing!

In Hardware on Nov 22, 2009 at 00:01

Baby steps in CNC land, but still a milestone for me:


With a pencil, the worst that can happen is a broken tip. I’m not quite ready to put a Dremel on there, turning at 10’s of thousands of RPM, and chewing its way through anything that happens to be near it. Need to get the limit switches and the relay board going first, so it can be turned off under computer control. Besides, it’ll be noisy and get very dusty.

The red-black wire hanging down the “gantry” (yeah, new words every day) is for the limit switches, which have been glued in place but not yet hooked up. The switches have been connected in series, two per axis and using the Normally Closed pins so that the circuit gets broken when a limit switch trips. That way it will also act as stop signal when a wire gets pulled loose.

I’m still exploring, but I think I’ll call the longest axis (towards the camera) the X axis, and the sideways one the Y axis. Let’s just stick with Z for up and down ;)

The drawing is the standard demo built into EMC v2, and I had to move the paper during while drawing because it would have run off the edge otherwise:


Some oddities in there because the pencil is not rigidly attached to the tool holder, but basically it’s doing all the right things. And making funny sounds as the steppers go through curves such as for the “C” and the “S”. Can it draw an accurate rectangle? I hope to find out soon.

So now zee Jee Machine is writing on paper! Onwards!

CNC progress

In Hardware on Nov 20, 2009 at 00:01

The CNC router is coming together nicely. The controller board works so far, and so does the EMC software running on a Dell laptop:


Here’s the complete setup, next to the V90 (the electronics will go inside once finished):


And here’s the EMC 2.3.4 software, running under Linux (Ubuntu 8.04):

Screen shot 2009-11-15 at 16.10.16.png

It just finished “doing” the demo, i.e. making the motors turn in lots of mysterious ways.

Some tech specs: the laptop has a worst-case real-time jitter of around 17600 nSec, which means the computer can send out up to 30,000 steps per second. I’m using quarter stepping, so that translates to 800 steps per rev, 4000 steps per inch, i.e. max about 7.5″ per second on the X and Y axes (which the motors can’t handle anyway – I may switch to 1/8th micro-stepping later). The system uses imperial units for the screws, so that’s what I’m sticking with, but I’ll probably do most designing in metric units. Resolution of the machine is about 0.006 mm for X & Y, and even higher for the Z axis. Don’t know about accuracy, repeatablity, and backlash yet – that’s where lots of tweaking will probably be required.

Next step is to mount the motors on the V90, and then go through all sorts of adjustments to make this thing move properly in all three axes. Oh, and hooking up the emergency button and the six limit switches.

And that’s just the CAM side of it all… CAD will be a completely different story!

CNC electronics

In Hardware on Nov 18, 2009 at 00:01

First step to CNC was the mechanical assembly of the V90. Little to report here – it took an hour or two. Adjustment and tweaking will probably take a bit longer, once things start to move.

The next step was a bit more work – here’s the power supply + electronics stuff, mounted on some scrap wood. It was made flat enough to mount inside the V90, underneath the work area and X-axis (Y-axis?) slide:


At the top what this is all about: connections for three stepper motors and a strip to hook up limit switches and the emergency stop button.

The power brick in the bottom right supplies 5V to the parallel-port side of the RF-isolated breakout board and the opto-isolated relay board. That means the 24V @ 6.5A supply can’t ever reach the computer. It also avoids 1A current through the linear voltage regulator to supply the relays (i.e. 20W of heat, just to go from 24V to 5V).

End stop switches, heat sink, and relay board have not yet been added / connected. Plus some power cable fasteners at the bottom, so they can’t be yanked loose.

All the high voltage is in one area at the bottom, to be covered by a shield. But even without the shield: all the exposed metal is recessed so it can’t be touched without sticking some sharp object in there – 220V scares me!


In Hardware on Nov 16, 2009 at 00:01

Heh, heh. Some crazy stuff is about to happen in the Jee Labs…

I’ve received a CNC router kit, i.e. the subtractive way to create 2D and 3D shapes. This one:

Picture 2.png

It’s one of the simplest CNC units available, from what I can tell. The work area is about 30 x 45 cm (A3).

Got various ideas to try out – from one-off pcb’s to front-panels. And more.

CNC routers can be very noisy and dusty, so this thing will be placed in a corner of the garage. A trusty ol’ Dell Inspiron 5000 laptop will sit next to it, running EMC and driving it all via the parallel port.

I’ve also ordered an extruder-type machine, i.e. the additive way to create 3D shapes. This one:


I don’t expect any of this to be a time saver – on the contrary, getting all the details right for CNC is going to take a huge amount of time and effort. But if it helps me try out ideas and explore new avenues, then so be it.

Yeah. Totally. Crazy. I know…

CD drive as X/Y table?

In Hardware on Aug 20, 2009 at 00:01

(Warning: this post is a digression into robotic tools…)

I’m still struggling with the assembly of JeeLinks: after 4 attempts, none of my boards work and each with different results – not good :(

The answer is probably to have SMD stencils made to apply the solder paste evenly and in precisely the right spot. Manual parts placement with a tweezer is tricky but it seems to work ok for me.

But I’m hesitant. Stencils add a considerable cost overhead to each pcb run, and I’d like to be able to do lots of prototype runs in the future.

The other way to do this is to automate. Unfortunately, SMD machines are expensive – even the manual-assist or “semi-automated” ones are in the multi-$1000 range. And I don’t really need a CNC router with extreme precision or a 50x50cm work area plus a full 3D Z-axis. I just need to deal with printed circuit boards of say 3x12cm and position them within 0.2mm or so. Plus a reasonably accurate automated solder paste dispenser.

Hm. Wait a minute. That’s essentially the range of a CD/DVD drive: the tray comes out about 12 cm, and the laser inside moves about 3 cm. Why not take apart an old CD drive and mount the laser motion system on top of the tray and perpendicular to it?

Here is an old Philips drive I still had, disassembled:


Here is the drive, “reorganized” to perform X/Y positioning, with both actuators at the opposite ends of their respective travel:


Here’s another one from AOpen:


A close-up with the laser platform turned and on top of the tray:


The motors in both drives create a smooth and not overly fast motion when driven by 1.5 .. 3V, but the tray motor from AOpen draws much more power (about 250 mA).

The main idea is that such a setup can move the laser platform over an area of 3x12cm. But instead of turning on the laser, some sort of pcb holder could be attached to it so that the board is positioned. Then, all I need is a syringe mounted in a fixed spot over this X/Y table and some move-down-and-dispense mechanism.

Voilá – a dirt cheap automated solder paste applicator for small PCBs!

Given that there is no sideways strain, I hope that the tray/X-axis positioner (which has some slack) can be made accurate enough for solder paste by spring-loading it. The laser/Y-axis accuracy should be ample without much effort.

One problem with both drives is that they use linear motors instead of stepping motors, so there is no easy way of figuring out the current X/Y position.

Hm again. Could we somehow accurately measure the position of the X/Y table? Adding quadrature encoders to both rotating shafts would solve it, but that means hacking the mechanism – which I’d rather not alter. Not to mention getting suitably small encoders.

So here’s a second idea: the X/Y table positions the pcb, but perhaps it could also move around a bit of graph paper, attached alongside the board. And then… maybe an optical mouse could be hacked to detect the changes? Though I don’t know how hackable optical mice are. Another option might be to use IR proximity sensors, but that’s pushing it and would require precise calibration.

The third issue is the solder paste dispenser. Some sort of syringe, with the plunger tied to a servo, perhaps?

There’s a second, simpler, use for such a system: a PCB inspection system. Just place a loupe or microscope on top and meander the board underneath it.

I’ve even got an old Ikea drawer to fit the entire thing into:



I know, I know, it’s crazy. But still… ideas are cheap, and so far my materials cost is zero!