Generating Laser Cut Boxes in C

[Mike] is a laser cutting newbie and has never had the opportunity to create a file and send it off to a laser for cutting. He knew he didn’t want to squint at a CAD package, nudging lines by tenths of a millimeter, only to screw something up and have to do it all over again. His solution, like so many other automation tasks, was to create a program that would generate a box of any size in .SVG format.

[Mike]’s program runs in C, and only requires a few variables set in the program to create a box of any size. There’s no argc or argv for the program – the one thing that would turn this into a command line utility that simply creates SVG boxes. Perhaps another time.

The rest of [Mike]’s hackerspace, Fab Lab xChc, was impressed the program worked the first time. With this small bit of C code, [Mike] has an easy, simple tool to generate laser cut boxes. The only remotely complicated bit of C this program uses is printf(), so even an Arduino can spit out the SVG for a laser cut box.

Turning the Raspberry into a CAD Workstation

Inventables has been working hard on a successor to the extremely popular Shapeoko CNC milling machine, and to bring digital fabrication to the masses, they’ve created Easel, possibly the easiest 3D design software you’ll ever use. [Sacha] was trying out the beta version of Easel and mentioned to the dev mailing list he was running his installation on a Raspberry Pi. One of the developers chimed in, and after a bit of back and forth we now have a workflow to use Easel with the Raspberry Pi.

Easel is a web app, but since the graphics, design, and g-code generation are handled locally, even the most rudimentary CAD suite would choke the decidedly low power Raspi. Instead, [Sacha] is using the Raspberry to grab 2D and 3D files, turn that into g-code for a machine, and send it off to a Shapeoko router.

Easel doesn’t yet have local sender support that works on Linux, so a separate piece of software is used to shoot the g-code over a serial port to the machine. That’s something that will probably be added in a later version of Easel, making a Raspberry Pi a great way to control router or milling machine.

THP Entry: Etch-A-CNC

etchacncCNC machines have been around for decades, but only recently have small desktop routers, 3D printers, and laser cutters brought G code to the tabletop. Obviously, this is a teaching opportunity, and if you’re trying to get kids interested in the inner workings of machines that build things, you can’t begin with obtuse codes understood only by machines and CNC operators.

[johnyang] is building his own CNC controller based on something just about every kid is already familiar with: the Etch A Sketch. He’s retrofitted a small, travel size Etch A Sketch with an LCD, buttons, rotary encoders, and a Raspberry Pi to turn this primitive drawing toy into a machine that generates G code for a Shapeoko 2 CNC mill.

The user interface for this CNC controller is as similar to the Etch A Sketch as [johnyang] can make it – two rotary encoders draw a shape on the LCD, and G code is generated from the drawn shape. Adding a third dimension is a bit of a challenge – it looks like two buttons take care of the up and down movement of the spindle. Still, [johnyang] plans to add the definitive Etch A Sketch feature – holding it upside down and shaking it will reset the CNC to its original state.

There are a few videos of [johnyang]’s progress. You can check those out below.


SpaceWrencherThe project featured in this post is an entry in The Hackaday Prize. Build something awesome and win a trip to space or hundreds of other prizes.

Continue reading “THP Entry: Etch-A-CNC”

Hackaday Links: November 17, 2013

hackaday-links-chain

If you purchased a knock-off FM transmitter and were unhappy with its broadcast range [Thiagohersan] shows how to double the range with a simple transistor amplifier circuit. He also hacked it for used without the 12V car socket.

[Patrick Herd] had a project that required him to strip about twenty Mindstorm batteries from their plastic enclosures. It’s not too tough getting into them but it does require drilling out the plastic rivets. He made a jig and used a CNC mill to automate the process.

Speaking of CNC, [Bertho] added some abstraction to distance himself from what he calls the “50+ years archaic syntax and grammar that G-code programs have”. The project is a meta-compiler for G-Code.

If you need a cold one and don’t have a HaDuino on hand you’ll thank yourself for hacking together this five-cent workbench bottle opener.

Just make sure you do all the lathe work for a custom speaker enclosure before you start pounding back those brewskis. Not only does [Shaun’s] creation look modern and stylish, but it boasts more than enough power to bump some tunes.

Here’s a project that adds LED feedback to your XBMC installation. It uses a Raspberry Pi to run the media center software, and a script to monitor it and actuate the lights on an Adafruit add-on board. At first glance you may not think much of it, but this is all the logic control you need to automate your viewing room. Who doesn’t want a home theater that automatically dims once you’ve made your viewing selection?

And finally, [08milluz] snagged some reactive electronics in the form of Disney’s Mickey Mouse ears. Apparently they glow different colors at live shows and based on where they are worn within the park. He did a complete teardown to show off the hardware within. It turns out to be controlled by an MSP430 which are known for their low power consumption. [Thanks Spikeo55]

HHH: Sniffing Proprietary CNC to Hack in G-Code Support

hhh-proprietary-g-code-hack

Here’s a beautiful desktop CNC mill which had one big drawback: it used a proprietary interface for driving it. To increase the flexibility of the tool it was hacked to work with G-Code.

The project is a Hackaday Hackerspace Henchmen submission from rLab, the Reading Hackspace in the UK. [Barnaby] explains the entire project after the break. The machine itself wasn’t altered, but a translator script was written in Python after capturing a bunch of packets and working out the protocol. This script listens for G-Code and does the translation into the type of commands the machine is expecting to receive.

If you know of a CNC hack from your own hackerspace send us the story for a chance to win some loot.

Continue reading “HHH: Sniffing Proprietary CNC to Hack in G-Code Support”

Turn a decommissioned robot into a CNC machine

adeptRobot

Some of us may have been accused of living in Mom’s basement – [Benjamin] kicks it up a notch by keeping an industrial robot in his parent’s attic shed loft.
[Benjamin] was tasked with stripping down some retired equipment at work. It turns out the “retired equipment” was three Cartesian robots from Adept Robotics. These are large industrial XYZ platforms capable of high speed movements (3000 IPM rapids!).

Getting from a decommissioned machine to a working CNC is never a simple path. In this case [Ben] was able to make the transition relatively easily. Each axis of the robot has a 400 Watt Yaskawa servo with a 65k encoder and brake. The original Adept servo amps and control system was still working, so he kept it. The controllers were new enough that they communicate over a daisy chained IEEE1394 (Firewire) link. That is relatively modern compared to some of the conversions we’ve seen in the past.  The final piece of the puzzle was G-code creation Translating common G-code to a format his machine could recognize. Ben chose MeshCAM for the task.

One problem [Ben] ran into was stuttering on the X-axis. The original machines only had a single sided drive system on the X-axis. Single side is fine for an assembly machine that doesn’t see any tool load. However for a CNC machine that will see spindle loads, a single side drive creates a twisting force which threatens to rack the entire frame. He used one of the drive systems from his spare robot to convert his main machine to a double-sided drive, eliminating the issue.

Continue reading “Turn a decommissioned robot into a CNC machine”

GRBL compatible Arduino CNC shield

By the time you get to the point in a home CNC build where you’re adding control electronics you may be ready for the simplest means to an end possible. In that case, grab your Arduino and heat up that etching solution to make your own GRBL compatible shield.

This familiar footprint manages to contain everything you need for a three-axis machine. The purple boards slotted into the pairs of SIL headers are Pololu Stepper motor drivers. Going this route makes replacing a burnt out chip as easy as plugging in a new module. The terminal block in the center feeds the higher voltage rail necessary for driving the motors. The DIL header on the right breaks out all of the connections to the limiting switches (two for each axis), spindle and coolant control, as well as three buttons for pause, resume, and abort. There’s even a header for SPI making it easier to add  custom hardware if necessary.

This is a dual-layer board which may not be ideal for your own fabrication process. [Bert Kruger] posted his Gerber files for download if you want to put in a small run with OSH Park or a similar service.