Loading
Hey! This thing is still a Work in Progress. Files, instructions, and other stuff might change!

CodeThread - GCode from Processing

by diatom, published

CodeThread - GCode from Processing by diatom Mar 27, 2011

Featured Thing!

Description

CodeThread is libary for processing that lets you create g-code as you calculate coordinates for a toolpath.

One of the things we love about makerbot in contrast to commercial printers is that you have complete control over every aspect of the print technique. We think there is a lot of opportunity to develop new printing styles with makerbots, beyond traditional solid prints.

We wanted to experiment with the materiality of makerbot prints by working directly in gcode with processing, so we made this small library that provides some simple functions for generating gcode commands, and prints a gcode file.

Library (v1.1.2):
diatom.cc/code/processing/libraries/codethread/codethread_1.1.2.zip

Documentation:
diatom.cc/code/processing/libraries/codethread/reference/

Github Repository:
github.com/DiatomStudio/CodeThread/

Our experiments (including some description of the images attached here):
blog.diatom.cc/codethread

It's still pretty fresh, hope to have some more updates and examples soon!

Recent Comments

view all
Hey do you have a link to your project? I'd love to get some advice for doing something similar! :)
Saw some of those Cubes, in Lisbon! :)
nice! i hacked something to turn 2D processing shapes into gcode for our penplotter reprap mod.

but this seems much more worked out ;)

will test it out !

Liked By

view all

Give a Shout Out

If you print this Thing and display it in public proudly give attribution by printing and displaying this tag. Print Thing Tag

Instructions

For example, here is some code for a 30mm thin-walled cube:


CodeThread codeThread= new CodeThread();

int feed = 1200;

codeThread.setDefaults();
codeThread.extruderOnFwd();

codeThread.generateRaft(40, 40, 560, 1500, 2.5, 1.5);

for(float i=0; i(less than)30; i+=0.35) {
codeThread.moveTo(15, 15, 1.27+i, feed);
codeThread.moveTo(-15, 15, 1.27+i, feed);
codeThread.moveTo(-15, -15, 1.27+i, feed);
codeThread.moveTo(15, -15, 1.27+i, feed);
}

codeThread.extruderOff();
codeThread.writeToFile(sketchPath + "30mmbox.gcode");


note: replace (less than) with 'less than' sign. For some reason that character wouldn't post.
Saw some of those Cubes, in Lisbon! :)
nice! i hacked something to turn 2D processing shapes into gcode for our penplotter reprap mod.

but this seems much more worked out ;)

will test it out !
Hey do you have a link to your project? I'd love to get some advice for doing something similar! :)
This is pretty badass.
Top