Hello World! Notes on using TinyG with Shapeoko

Alden Hart of synthetos, creator of the grblShield and tinyG motor controllers, took some time to write about using tinyG with Shapeoko. We followed his advice and hooked up one ourselves, and I have to say that we're really impressed by the difference- Shapeoko feels like a totally different animal with tinyG in charge.

Here's a video of tinyG controlling the machine to run a "hello world" job:

Here are the tgFX panels showing the correct settings for Shapeoko. Note that you may need to change the axis assignments and polarities for each motor depending on how you wired it up, which is one of the nice features about tgFX- just pay attention to your motor's coil pairs, and then do all the rest in the software.

And as a special treat, Alden's rundown of the setup, and explanation of the control principles. Thanks

Shapeoko and TinyG

Shopeoko and TinyG are a great fit. The combination make a good upgrade to support very smooth, fast motor operation, built-in support for dual Y axis configurations, and other enhancements.

What Does It Do?

TinyG's motion control is very smooth due to precise timing and constant jerk acceleration. This means a number of things to the Shapeoko user. TinyG has an optimized, low jitter step generation coupled with constant jerk acceleration management. As a result TinyG gets a lot out of your motors. If you think you need to upgrade from NEMA17 motors to something larger you may find that more precise control offered by TinyG is really all you need.
The constant jerk acceleration management also makes for extremely fast rapids (traverses), which helps cut down job times. It does all this with minimal shaking of the machine and toolhead, making for smoother cuts, better surface finish, and less chance of skipping, chattering, or other artifacts.


TinyG works with tgfx, a cross-platform control program available for Mac, Windows and Linux. Tgfx provides a graphical user interface that lets you configure, run and monitor jobs.


Setting up Shapeoko to use TinyG is pretty straightforward. This page provides all the settings neededhttps://github.com/synthetos/TinyG/wiki/TinyG-Shapeoko-Setup
A few things to keep in mind.
  • TinyG treats motors independently from the axes. So it natively supports dual-y configurations. 2 motors map to the Y axis - and both are driven by Y axis controls. But they must be going in opposite directions (i.e. have reverse polarity settings) for the gantry to move as a unit. Polarity can be handled electrically by reversing one of the coil pairs on one of the motors, or under software control by setting the polarity motor parameter. I prefer firmware as this way all the motors are wired the same and are interchangeable.

Tuning Shapeoko and TinyG

Once you are set up you can tune the Shapeoko/TinyG system for optimal performance. There is a page on the TinyG wiki about tuning that the following was adapted from. What follows are tuning instructions and guidance specifically for the Shapeoko/TinyG combination.
Tuning the machine is about getting the maximum performance from the system while setting the "envelope" in which the machine can work. The envelope defines the reliable limits on all parameters. TinyG is written such that if Gcode asks for more than the machine can deliver (e.g. too high a feed rate) the system will execute the Gcode to the best of its ability while not exceeding the performance envelope. So it's important to tune the machine so you avoid over-specified Gcode files causing jobs to fail.


A well functioning mechanical system is the heart of tuning. The electrical system can at best compensate for the mechanical system, but can never fundamentally improve it. Here are a number of points to make sure the Shapeoko itself is tuned up.
  • Make sure the machine is in perfect alignment and belt tension is correct. All parts should be square and the belt axes (X and Y) should be tight but move with almost no resistance. Test that pulleys and wheels rotate freely and do not bind or wobble. Test that shaft couplers are well seated and tightened with minimum eccentric wobble ("runout").
  • It's a good idea to test slide resistance with no motors mounted. Look for any rough spots in the slide, or any points where resistance is greater than others. Test again once the motors are mounted. When motors are mounted make sure they are electrically disconnected from the stepper board, and their winding leads are not shorted (as this will cause mechanical resistance to go way up).
  • The Z axis should turn as smoothly as possible with no binding. Many people upgrade to an Acme screw for this reason. Observe similar guidance about mounting the motor.


Once the mechanical system is working well you can start in on the settings. Do these one axis at a time then in combination. All values are in millimeters using the X axis as an example. Other axes are similar.
Some terms:
  • The velocity maximum - aka traverse rate - is the top speed of an axis under no cutting load. Traverses (G0's) move the machine at the maximum velocity and generally don't change from job to job. A good maximum velocity will drive the motor reliably at high speed and allow for a little headroom where the motor is still running well. Attempting to set this rate above this speed may cause the motor to operate erratically, drop steps, or stall. These will be obvious if the motor makes grinding or other bad noises.
  • Bear in mind that with traverses (G0) the actual speed of movement may well be above any of the traverse rates of the individual axes as it's the cartesian sum. For example, if xvm and yvm are set to 10,000 mm/min a G0 from (0,0) to (100,100) will actually run at 14,142 mm/min (assuming it has room to accelerate to the target velocity).
  • The feed rate is the maximum cutting speed the axis can sustain for a given tooling, material and type of cut and may change considerably from job to job. The max feed rates set here are just an upper limit that a Gcode file cannot exceed. The actual control of feed rate should be done from the F words in the Gcode file itself. The max feed rates should generally be set lower than the maximum velocity.
  • The jerk is the rate of change of acceleration - technically the derivative of acceleration or the third derivative of position. In practical terms, jerk is a measure of the impact to the machine due to rapidly changing velocity. It causes the machine to - well - jerk. When setting jerk values you are looking for two things. (1) finding the minimum time the axis can get up to speed without stalling or missing steps (which you will be able to hear), and (2) finding the maximum jerk the machine can withstand along that axis without shaking too much. These might be different. Optimize for (2) over (1).

Axis Tuning

Axis tuning starts with getting good values for the following:
  • Velocity Maximum ($xvm)
  • Feed Rate Maximum ($xfr)
  • Jerk Maximum ($xjm)
  • Motor Currents (potentiometer settings)
CAVEAT: Be sure your machine is in mm distance mode before starting. 
The distance mode should be obvious from the command prompt:
  tinyg [mm] ok>      not:
  tinyg [inch] ok>

Enter G21 to change to mm mode (G20 to change to inches)
Do these steps for each axis in turn.
  1. Ensure the Motor settings for step angle ($1sa), travel per revolution ($1tr), microsteps ($1mi), and polarity ($1po) are correct for each motor. Verify that the Axis settings for velocity maximum ($xvm) and jerk maximum $(xjm) are set correctly. If in doubt, go back to theTinyG Shapeoko Setup page
  2. Locate the X axis current setting potentiometer on the TinyG board and start with it at the middle position - 12:00. Never force the potentiometer or exceed the potentiometers' range of motion, which is 270 degrees, or from about 8:00 to about 4:00.
  3. Test a traverse with a long G0 move, such as G0 X100 (Be sure you have 100 mm of clearance on the X axis before you do this!) The motor should accelerate, cruise at speed, then decelerate to a stop - all in less than 1 second. The motor should not stall or fail to start. Lower the velocity in increments of 1000 mm/min if this is the case. You may also need to back off the jerk max - try increments of 1 billion (e.g. 5000 --> 4000).
  4. If the motor hums but doesn't start it's probably not getting enough current. Turn it up to 1:00 or 2:00. Alternately, if the motor stops and starts; or stutters; and the driver chips are excessively hot the motor is getting too much current. Turn the pot down a bit. Too much current will give just as bad results as too little. These drivers do not go to "11".
  5. If the the motor more or less works but seems to be dropping steps it could be any of the mechanical system (too much friction), the current setting, or the velocity max being too high; or possibly some combination of all three. Experimentation is required. It's best to try to fix them in that order. Start with the mechanical system, then the current, then the setting.
  6. Once you have the axis working you can see if raising the velocity ($xvm), the jerk ($xjm) and providing more current can increase the top speed. This is a case of experimenting. Try to avoid excessive current, however, as after a point the current setting provides diminishing benefits and only heats up the motors and risks thermal shutdown.
  7. Once you have the maximum velocity where you want it set the max feed rate to the max velocity value or somewhat lower. The max feed rates often require adjustment for a given job or material as the cutting loads may vary. The traverse rates should not require job-by-job adjustment.
It's worth noting that the mechanics of the axes may not be identical, and the achievable traverse rates may differ for each axis. You can set them optimally for each axis and moves in more than one dimension will takes the individual settings into account.
It's also worth noting that on some machines mechanical resistance is greater in some parts of the travel than others (e.g. more resistance at the ends of travel due to shaft coupler runout or other mechanical factors). Be sure to test the entire travel for each axis before finalizing the settings.

Tuning the Cornering Speeds

So far all the tuning has been about straight line movement. Cornering is is the rest of the story. Corner velocity is the maximum velocity the tool head can move through a corner without exceeding a setting to limit centripetal acceleration.
The centripetal acceleration limit is called Junction Acceleration ($ja) and can be found by looking at the system parameters by typing $sys. This value applies to all axes, as cornering is inherently a multi-axis movement.
Each axis is controlled by by its Junction Deviation value ($xjd). This sets how tight the "corner" is for that axis. The larger this number, the faster that axis can corner.
The settings provided in the Shapeoko setup are a good starting point. If you find the job is stalling or skipping in tight corners you will want to lower one or the other or both of these values.

You spin me right round baby!

We had a little fun with the new Knob with Crank for NEMA 17 and 23 stepper motors. For the record, you can use one stepper motor to generate enough power to turn another one, but the efficiency of that energy transfer is a little low...

If you want to turn this .gif into a dance party, here's your soundtrack- just hit play:

Upgrading your Shapeoko 2 with NEMA 23 motors

A lot of people ask us about upgrading their Shapeoko 2 to use NEMA 23 motors on the X and Y axes. To make that process a little easier for everyone, we decided to offer up a project that includes all the components necessary, click here for the shopping list.

Important notes: 
  • This is an experimental modification
  • Your results may vary
  • You might do something weird and accidentally burn out your motor driver board
  • If that or something else catastrophic happens this is not our fault, you crazy hacker!

That said, here's the instructions. You crazy hacker you.

1. Head on over to the project page and order the list of parts. There's a convenient "add to cart" button that has everything you need.

1. Remove the motor carriage plates from your shapeoko. This basically means: disassemble your Shapeoko most of the way. You need to remove the motor carriages completely from the makerslide, and the easiest way to do this is to remove the screws that hold the makerslide to the plates and frame.

2. Remove the NEMA 17 motors and all the mounting hardware. You should now be left with something that looks like this:

3. Organize your mounting hardware for the NEMA 23s. Each one will need 4x button head cap screws, 4x spacers, 4x washers, and 4x hex nuts.

4. Mount the screw through the motor's mounting hole, then add a spacer, then pass it through the plate, then a washer and the hex nut and tighten it down. It's easier to get all 4 screws in and put the spacers on, then push them into the motor plate all at once. You might want to leave them a little loose until the later steps.

5. Repeat for the other motor mount plates.

6. Attach the pulleys to each motor shaft. You'll want to line each pulley up with the smooth idlers so the belt can travel in a straight line.

7. Once you've got all the motors mounted, you need to slide the motor carriages back onto the Makerslide and reassemble the machine. Here's where it gets tricky:

The NEMA 23's must be mounted on the bottom of their path of travel for the X-axis makerslide to be able to mount properly. Otherwise, the motor will get in the way and it won't work. it will be very frustrating.


Here's that same error from another angle:

If you move the NEMA 23 to the bottom of the mounting holes, it will look like this:

Once you do that, the Makerslide will drop into place easily and square up. So satisfying!

8. Once you get the mechanicals back together, reattach and thread your belts and tighten and calibrate everything. You're now free to experiment with this radical and unorthodox means of Shapeoko movement, including the highly dangerous process of adjusting the amperage on the Gshield motor controllers to give these 23's a little more oomph. 

Good luck, and you should probably check in on the Shapeoko forums to see how other folks have fared before you attempt this.

-Michael Una

Makerbot Replicator 5th Generation

We just got in some of the new Makerbot Replicator 5th Gens, and they're looking good!

Big improvements over the last model include:

  • Integrated camera so you can monitor/record your prints
  • Bigger, color LCD screen 
  • Wi-Fi connectivity
  • Updated Makerware software
  • Easier leveling
  • Glass build plate can slide out of the machine when your job is done
  • The new Smart Extruder system which allows
    • Magnetic mounting for easy replacement
    • Sensors to pause your job if it runs out of filament

The build volume is 7,522 cubic CM (456 cubic inches), about 11% larger than the Replicator 2. The print resolution is 100 microns/layer, and it's optimized for PLA filament.

We have a limited number of these highly sought machines in stock right now, so you might want to act quickly. After our initial supply is exhausted, we're looking at a ~6 week lead time.

Kate Sullivan of CBS News features Inventables on the "Your Chicago" Segment

Kate Sullivan is co-anchor of CBS 2 Chicago News at 5 p.m. and 10 p.m. with Rob Johnson. Kate, who has won several awards – including an Emmy Award and the Associated Press First Place Award for Breaking News – joined us at Inventables for a tour, interview, and a little bit of making.

Kate Sullivan

Kate does a recurring segment for CBS called "Your Chicago".  Every Friday at 10pm Kate or her co-host Rob Johnson get out of the studio and explore Chicago.  Last week she came over to Inventables.  Kate was interested in learning more about our new free software called Easel and the Shapeoko 2.  She rolled up her sleeves and became a maker in minutes!  

We even got her into a pair of safety glasses!

Watch the full segment on the CBS News website.

The Inventables team, all in one place!

We had a rare occurrence this week of nearly every single Inventables employee being in the Chicago office at the same time. (Sorry Joanne, we'll have to photoshop you in!)

Here's a group photo we took to document this astronomical event:

Greetings from everyone!

Easel Development Update

Hi, I'm Paul Kaplan, software engineer on the Easel team here at Inventables. The dev team has been thrilled to see the excitement about Easel, and we wanted to let everyone know how we'll be rolling it out to more users. We wanted to elaborate on our motivation for building Easel, and explain the next steps towards expanding access to everyone.

Here at Inventables we’ve been hard at work on Easel, a web-based app for CNC machines like the Shapeoko 2. Our goal with Easel is to make it fast, easy, and fun for anyone to go from having an idea to making a finished product.

Our team recently went down to South by Southwest Interactive, where over 400 people had the opportunity to make custom bottle openers using Easel and the Shapeoko 2. Our CEO Zach officially announced Easel and was even joined onstage by Chicago mayor Rahm Emanuel. We take some pride in the fact that Easel is so easy even the mayor can use it! From a developers point of view, more important than seeing the mayor use our software was seeing young children also able to use Easel throughout the weekend.

IMG_1536 copy.jpg
One of our youngest Easel users yet at SxSW
Chicago Mayor Rahm Emmanuel and Inventables CEO Zach Kaplan running Easel onstage at SXSW

What is it?
Easel is a browser based app to design and create projects on your Shapeoko. Instead of a complicated workflow with multiple pieces of software, Easel takes care of everything with one app. And it's totally free.

Why are we making Easel?
We believe that the distinction between artist and engineer is a false dichotomy. Here at Inventables, nobody is just one thing: we are programmers, makers, artists, and designers, often all at the same time. Software should give people the tools they need to cross those boundaries. An in-depth knowledge of technical settings should not be a prerequisite to designing a wooden sign, nor should a lack of design training stand in the way of making a cool product.

When can I use it?
Right now we are looking for Chicago area Shapeoko owners in order to learn the most from our beta testers. We hope to be able to release Easel to everybody on the early signup list by early summer.

We are looking for people who: 
live in the Chicago area
own a Shapeoko
are willing to meet with our developers in person to give feedback.

If that describes you, drop us a line at easel@inventables.com and join our beta test. 

As we continue to build out Easel, we’ll be able to roll out access to more and more users over the coming months. You can sign up for the waiting list at easel.com

We are so excited about making it easier than ever to use your Shapeoko. We are working furiously towards opening Easel to everyone on the signup list by the summer. We will try to provide weekly updates from the dev team on what we are working on.

Some of our team at SxSW
P.S. We’re hiring! If you’re a software engineer and want to help us build the future of digital fabrication, take a look at our careers page.

Inventables Announces the Release of Shapeoko 3!

The Shapeoko legacy continues with this newest update to the world's fastest-selling desktop milling machine. Inspired by handheld 3D Printing stylii like the 3Doodler, we've stripped down the Shapeoko to it's barebones function. Mill through wood, plastics, and even aluminum with the new Shapeoko 3!