Grbl Controller 3.0 released

WillAdams
Posts: 8533
Joined: Mon Apr 09, 2012 6:11 pm
Location: Pennsylvania --- south of the Turnpike, East of US-15
Contact:

Re: Grbl Controller 3.0 released

Post by WillAdams » Wed Jan 30, 2013 12:48 pm

Managed to find 3:

http://www.caddedge.com/blog/bid/153164 ... ial-Part-1
http://www.cnccookbook.com/CCCNCGCodeCourse.htm
http://gnipsel.com/linuxcnc/g-code/gen01.html

Still kind of weirded out that Bézier curves aren't directly supported. Did find this page for gcodetools:

http://www.cnc-club.ru/forum/viewtopic.php?t=35

which notes, ``Gcodetools is a plug-in for Inkscape. It prepares and converts paths from Inkscape to Gcode, using biarc interpolation.'' and confuses me as to why segmenting paths is advocated whenever it's discussed.
Shapeoko 3XL #0006 w/Makita RT0701 Router w/0.125″ and ¼″ Elaire precision collets
Nomad 883 Pro #596 (bamboo)

WillAdams
Posts: 8533
Joined: Mon Apr 09, 2012 6:11 pm
Location: Pennsylvania --- south of the Turnpike, East of US-15
Contact:

Re: Grbl Controller 3.0 released

Post by WillAdams » Sat Feb 02, 2013 1:53 am

Starting to make progress.

Found a site w/ a circle:

https://github.com/grbl/grbl/wiki/G-Code-Examples

G17 G20 G90 G94 G54
G0 Z0.25
X-0.5 Y0.
Z0.1
G01 Z0. F5.
G02 X0. Y0.5 I0.5 J0. F2.5
X0.5 Y0. I0. J-0.5
X0. Y-0.5 I-0.5 J0.
X-0.5 Y0. I0. J0.5
G01 Z0.1 F5.
G00 X0. Y0. Z0.25

But the visualizer shows it w/ one quadrant empty / blank?

On the bright side, the movement when drawing arcs using G02 is _much_ smoother.
Shapeoko 3XL #0006 w/Makita RT0701 Router w/0.125″ and ¼″ Elaire precision collets
Nomad 883 Pro #596 (bamboo)

zapmaker
Posts: 28
Joined: Sat Oct 06, 2012 5:38 pm
Location: Seattle, WA, USA
Contact:

Re: Grbl Controller 3.0 released

Post by zapmaker » Sun Feb 03, 2013 6:32 am

One more bug found and squashed. Again, the problem you describe of the missing arc was due to the parser overwriting the clockwise/ccw boolean variable with every line - instead, it should leave that variable alone. I made the fix and checked it in (V3.3.3), but i have not created binaries yet. Again, thanks for finding this one. And again, only affects the visualizer.

This is a nice writeup of how arcs work in gcode:

http://www.cnccookbook.com/CCCNCGCodeArcsG02G03.htm

Notice that arcs must be circular (i.e. not elliptical arcs) to be gcode compliant. This is why we can't do Bezier curves easily with gcode.

Please remember to consider enabling "Aggressive Preload" in Grbl Controller options - Grbl will smooth and speed up motion through each segment or arc. It is possible to create circles purely from line segments and get (reasonably) smooth motion, but only if you let Grbl do its fancy interpolation (it won't accelerate/decelerate with each segment, it will instead determine the optimum stepper control so that the desired feedrate is maintained). It can only do this if it has some knowledge of future commands. Its buffer typically allows 6-10 lines to be preloaded, which is sufficient to get this behavior to occur properly.

Still, better to use arcs if you can.
Shapeoko #668
Dual-Y axis, belts outside, DW660 | Author of Grbl Controller 3.0 | http://zapmaker.org

WillAdams
Posts: 8533
Joined: Mon Apr 09, 2012 6:11 pm
Location: Pennsylvania --- south of the Turnpike, East of US-15
Contact:

Re: Grbl Controller 3.0 released

Post by WillAdams » Sun Feb 03, 2013 1:34 pm

Great! Will definitely look into enabling that.

In the meanwhile, I've been searching unsuccessfully for a gcode2pdf converter, but I did find:

https://code.google.com/p/gcode2eps/

which would be perfect if my NeXT Cube was still running.

Have you considered adding editing and saving functionality (or just a reload button)? If you could mouse over lines and see where they are it'd be very useful for modifying things.
Shapeoko 3XL #0006 w/Makita RT0701 Router w/0.125″ and ¼″ Elaire precision collets
Nomad 883 Pro #596 (bamboo)

zapmaker
Posts: 28
Joined: Sat Oct 06, 2012 5:38 pm
Location: Seattle, WA, USA
Contact:

Re: Grbl Controller 3.0 released

Post by zapmaker » Wed Feb 06, 2013 5:56 am

Although I haven't had a chance to fully evaluate it, I am impressed by NC Corrector v4.0 that xpix linked to on another topic:

http://www.shapeoko.com/forum/viewtopic.php?f=6&t=1136

You click on a segment and it jumps to the code, then you edit the code, click in the 3D view, which promptly gets updated by your hand-edit.

Since someone has already done this very well, I am going to punt and not implement it in Grbl Controller.

Glad you are making progress with G-code - it is truly worth doing a few examples by hand just to understand what is going on, but once you get into advanced work, you really need a good quality CAM package. For example, I am starting to play with CamBam's 3D feature - I've seen someone mill a streamlined pinewood derby car using such an approach - the idea is to create two files from the same master 3D object, one will use a "roughing" bit to take lots of material away, change bit and rehome, then follow with the second file that uses a finer bit to get detail. Lots of interesting possibilities worth exploring.

I should note that the best way to rehome is to get proper limit switches installed and use the new 0.8c Grbl homing capability - another feature I'm ready to try soon. The reason you need to rehome properly is because when you change bits, you can bump the spindle and accidentally cause the steppers to skip - throwing off your positioning. Another solution to homing is to use custom builds of Grbl that lock the steppers by powering them even when they are stopped, which greatly reduces the chance of bumping the steppers. See this topic (although it is for version 0.8a)

http://www.shapeoko.com/forum/viewtopic.php?f=3&t=533
Shapeoko #668
Dual-Y axis, belts outside, DW660 | Author of Grbl Controller 3.0 | http://zapmaker.org

WillAdams
Posts: 8533
Joined: Mon Apr 09, 2012 6:11 pm
Location: Pennsylvania --- south of the Turnpike, East of US-15
Contact:

Re: Grbl Controller 3.0 released

Post by WillAdams » Wed Feb 06, 2013 11:33 am

Thanks! NC Corrector looks like the ticket.

Will definitely look into homing / limit switches.

William
Shapeoko 3XL #0006 w/Makita RT0701 Router w/0.125″ and ¼″ Elaire precision collets
Nomad 883 Pro #596 (bamboo)

jsbannis
Posts: 80
Joined: Tue Apr 10, 2012 11:09 pm
Location: Chicago, IL

Re: Grbl Controller 3.0 released

Post by jsbannis » Wed Feb 06, 2013 7:16 pm

zapmaker wrote:Another solution to homing is to use custom builds of Grbl that lock the steppers by powering them even when they are stopped, which greatly reduces the chance of bumping the steppers. See this topic (although it is for version 0.8a)

http://www.shapeoko.com/forum/viewtopic.php?f=3&t=533
This is now built in to standard grbl, 0.8c has the setting "$7=25 (step idle delay, msec)" that can always lock the stepper motor. Setting for always lock is either 0 or 255 I think.

*edited for grammar
shapeoko #0057

cvoinescu
Posts: 4442
Joined: Thu Jul 19, 2012 6:50 pm
Location: Camberley, UK
Contact:

Re: Grbl Controller 3.0 released

Post by cvoinescu » Wed Feb 06, 2013 9:38 pm

jsbannis wrote:This is now built in to standard grbl, 0.8c has the setting "$7=25 (step idle delay, msec)" that can always lock the stepper motor. Setting for always lock is either 0 or 255 I think.
It's $7=255.

That said, what I would really love to have is what the "big boys" always had: a way to reduce the current after the machine has been idle for a while, instead of turning it off completely. It's not hard to do, but it needs an extra pin (or the re-purposing of an existing pin) on the Pololu driver carrier board. All you need to reduce current is to add a resistor from the "top" of the trimpot to GND; if the resistor can be switched on and off (e.g. with a MOSFET or open-drain output), you can control the current. Personally, I'd use the SLEEP pin, because it doesn't seem to be used by anyone and it's largely redundant (we already have the ENABLE pin, which does almost the same thing; the only differences being that a sleeping A4899 draws less current than a disabled one -- I don't care -- and that SLEEP, as opposed to ENABLE, also resets the indexer -- but I can use RESET for that).
Proud owner of ShapeOko #709, eShapeOko #0, and of store.amberspyglass.co.uk

WillAdams
Posts: 8533
Joined: Mon Apr 09, 2012 6:11 pm
Location: Pennsylvania --- south of the Turnpike, East of US-15
Contact:

Re: Grbl Controller 3.0 released

Post by WillAdams » Wed Mar 27, 2013 5:35 pm

Minor nit / feature request.

The interface says ``Runtime'', but it stops running once GRBL acknowledges OK to the last line --- but of course the machine keeps going.

Could we change that to ``Transmission time''? Or something similar?

And add a separate timer for machine running? There is some sort of signal from GRBL when it's done executing all instructions, right?

Thanks!

William
Shapeoko 3XL #0006 w/Makita RT0701 Router w/0.125″ and ¼″ Elaire precision collets
Nomad 883 Pro #596 (bamboo)

zapmaker
Posts: 28
Joined: Sat Oct 06, 2012 5:38 pm
Location: Seattle, WA, USA
Contact:

Re: Grbl Controller 3.0 released

Post by zapmaker » Thu Mar 28, 2013 3:54 am

Good point - I'll fix that in the 3.4. One other thing I'm going to do is default to "aggressive preload" on instead of off for new installations.

I've got a quite a few things I'd like to add, but it will probably only be a few items for 3.4 - if anyone has any suggestions on a feature voting system that could help me prioritize. I keep the TODO file up on github up-to-date with ideas, not in priority order, though.

I haven't had a chance to add features recently because I'm slowly upping the capabilities of my shapeoko - I just finished a new v-channel bed and moved the belts to the outside. Next is the debris shields and then on go the limit switches. Once I get to that point I will emphasize buttons/widgets that simplify homing and other overall ux improvements. Basically, I want to be able to do roughing on 3D objects with a 1/4" bit, then switch to a 1/8" for finishing. The UI will control Grbl to lock the steppers during the tool change, etc. That's my hope anyway.

So the plan is to fix some annoying issues and get them into 3.4, then continue work on getting my shapeoko running with limit switches, then 3.5 will have homing-related features.

Suggestions welcome. I've also noticed the thread on ideal controller software, may compare that to my to-do items.
Shapeoko #668
Dual-Y axis, belts outside, DW660 | Author of Grbl Controller 3.0 | http://zapmaker.org

Post Reply