If you’re building a CNC machine from scratch, the number of decisions you have to make is nearly boundless. Metal or wood construction? Welded or bolted? Timing belts or lead screws? And even once the mechanical bits are sorted, you still face a universe of choices in terms of control electronics. That’s where something like this modular CNC controller could really prove to be a game-changer.
The idea behind [Barton Dring]’s latest creation started with his port of GRBL to the ESP32. In fact, the current controller bears a strong family resemblance to his version 1.0 dev board, with a few conspicuous and intriguing additions. First, everything is modular — the main PCB is basically a motherboard with little more than a 5-volt power supply and some housekeeping electronics, plus a lot of headers. There’s support for up to six channels of steppers, either directly on the board with Pololu-style modules or as external drivers using pluggable screw terminal blocks. There’s also room for five IO modules; the current collection of modules includes a four-channel switch input, a relay output, an RS-485 module and a 0-10-V interface for talking to a variable frequency drive (VFD) spindle controllers, and buffered 5-V output module. The best part is that the IO module spec is completely open, so designing custom modules should be a snap.
The video below gives a quick tour of the controller. We’re really impressed with the thought that went into this, and we’ll venture a guess that having something like this available is going to kickstart a lot of stalled CNC machine projects. We can think of one shop that finally lost its last excuse for making the move.
I think most efforts are now focused to the grblHAL fork right now:
https://github.com/terjeio/grblHAL
Meh. If you need/want WiFi and a built-in control panel, ESP32 GRBL is pretty darn cool. Try it before you knock it.
grblHAL looks like it has a future, though, for sure.
The REAL mother of all grbl cnc controller boards is this one: https://blog.protoneer.co.nz/arduino-cnc-shield/
Works perfectly :-)
heliosoph
Uahuahauhauha… it’s the same thing I thought..
Everyone has one of these https://www.mischianti.org/2019/04/16/cnc-cyclone-pcb-factory-cnc-shield-stepper-driver-part-2/
I am automatically sceptical if i see a website trying to sell me something and they have typos in the title… “Compatable”
And no: NZ is 96% english speaking and it is their official language… Cmon… Pay a bit of attention at least in the title. I automatically assume you showed the same sloppiness with the product… Sorry, I pass…
I am not the guy who developed the Arduino CNC Shield but I bought one from him. So no hidden advertising here. He had the whole thing open source and then the Chinese built clones from his layout files. So he stopped publishing the layout. This is sad to see. I bought mine directly from his shop. His price is higher than the clone price but it is really worth the money and still very cheap compared to other solutions of the same problem. He even has his own raspbian build with all the cnc sender stuff integrated. I think he really does a great job.
heliosoph
I’ll have to check if the Protoneer shield can be used with a STM Nucleo F411 board without too many modifications for 3V3 signalling… https://www.st.com/en/evaluation-tools/nucleo-f411re.html
Hey can you link to the original creators site? Id love to see but the key words ‘Arduino CNC Shield’ are too too saturated to find who you are talking about.
GRBL on 8bit controller? That is a ‘mother’ all right as it’s a mother to get to fit into the limited memory of 8bit AVRs and a mother to get much resolution( 256 steps? ) from 8bits.
Grbl_ESP32 seems a good next step – https://github.com/bdring/Grbl_Esp32
We all know how advantageous it has been to have Pololu driver style sockets on our controller boards. I have slipped the screwdriver while adjusting drive current and blown up drivers myself. But being able to upgrade even old Marlin/RAMPS to better drivers has been very nice.
What it looks like is being done with this board is taking that modularity to the digital I/O side of the controller space and even tweaking the Pololu driver socket some for even better drivers.
Pretty bada55 updates.
Very nice, eventually people tend to adapt their own solution to solve platform specific needs. =)
FreeRTOS on ESP32 is also pretty interesting, and may offer some design options.
Does GRBL still have issues handling arcs? I seem to recall various derivatives of their code base constantly accelerating through the arc and loosing track of the feed rate
You’ll want to check the Grbl_ESP32 port to see if anything has been done with arcs yet. The good thing is, there is now enough program and memory space to do something about these things. 8bit GRBL is like putting a chicken egg in concrete and hoping the chicken makes it out. No room to grow.
still no closed loop BLDC? :(
With BLDC motors the problem is less torque compared to stepper motors. Therefore, you need gears or a belt. Stepper motors together with Trinamics drivers (Silent Step Sticks that fit on the Arduino CNC Shield!) give you much more torque which makes the mechanical side simpler and you also have much less noise compared to standard stepper motor drivers. Also, the risk of step losses decreases a lot with these drivers. When you use the serial interface of the Trinamics drivers I think you can get information about step losses. I use these drivers without the serial interface and never had any problems with step losses.
This combination is much simpler and cheaper than BLDC motors but is almost as good as BLDC.
heliosoph
Agreed, the newer interpolated 1/256 microstepping from TMCs better drivers are such a game changer for high speed torque and volume levels, that I’ve taken a step away from considering O-drive for my next CNC build.
I did it in an FPGA, complete with transcendental profile generator.. all in hardware. I asked the company that paid for my time if I could release it. Got a resounding “hell no” — to be expected I guess.
Impressive! Hopefully you have inspired someone here to make a FPGA / 32 bit controller.
Does that company sell an FPGA CNC controller? If so, mind dropping a link? In the market for one.
For the last five years I’ve been driving a Mesa FPGA card to generate Step and Dir signals with microstepping from linuxcnc via ethernet. Works great and much smoother than generating steps from a PC out of a parallel port. I believe the Mesa FPGA cards can drive signals up to 10MHz. Though your motor driver then needs to be able to handle that as input.
For what, spindle control or axis?
Those stepper drivers are laughable and typical of Barton Dring slipshod design. He should leave the bottom of the barrel to the Chinese.
If you don’t like a particular flavor of driver you can use a different one. The design supports every kind of Pololu module from the low-end ones up to TMC5160s. If you don’t like stepper driver modules at all, it supports external drivers with in-spec driving of optocouplers. Your implication that the design is slipshod is stated without proof. The design files are public and you are welcome to do a design review and point out any deficiencies. I did so – as an electrical engineer with 40 years of industry experience – and the design was revised to incorporate my input.
Mother of all… Uh sure. I agree that grblHAL is right fork to be using. Runs on 12 different platforms. Active developemnt and great support. Not only supports arcs, does polylines too. Lots of features taken from LinuxCNC without the headaches of that. Several BoBs out there. Here’s one that’s available: https://github.com/phil-barrett/grblHAL-teensy-4.x/blob/master/README.md
grblHAL is firmware and the post is about a flexible board design which holds and ESP32. Doesn’t grblHAL run on the ESP32 also? Maybe you should have spoken up when Grbl_ESP32 was posted and discussed here at hack-a-day – https://hackaday.com/2018/07/26/grbl-ported-to-the-esp32/
Had I seen it, I would have “spoken up”. Didn’t realize the statute of limitation has expired on alternate ports suggestions.
I will stick with my Centroid Acorn thanks. Hasn’t let me down yet.
This seems to be different league, skateboard/bicycle vs F350 pickup kind of thing
The board in this post is intended for an intermediate price point, between the low-end represented by the GRBL shields that are typically limited to 3 axes (4 motors) and higher-priced solutions like Acorn. Yes, it competes with grblHAL, and is also actively developed and well-supported. Pick your poison.
I was thinking of a ESP32 master to directly use the signals which need to be fast (like step, dir, possible encoder inputs) and instead of the the I2S shift registers, just use a arduino module (or pretty much any MCU) as a slow I/O extender slave (driver enable, limit switches etc) with SPI or I2C in between. Marlin doesn’t really seem to support that though.
Klipper does afaik.
I help test Bart’s first ESP32 board. He’s totally legitimate. A super nice guy and really takes his time to get everything right. I wish I had known about this board. I would have definitely asked to test it.
The plug-in IO modules support the use of an MCU or I/O expander, connected via I2C or SPI or UART, for additional low-speed I/O. Grbl_Esp32 has a PR for an I2C expander that will be integrated in the near future. Even with the low-speed I/O offloaded, a multi-motor system can still run short of output pins due to the restrictions on some pins. The I2S approach hit a lot of sweet spots. At very low incremental cost, it blew through the I/O pin limitation, providing jitter-free fast stepping. It was very easy to route the multi-motor PCB since the shift registers are located next to the driver sockets with only a couple of daisy-chained wires going back to the ESP32. Each socket has a separate enable. The layout itself is modular, in the sense that each pair of sockets plus a shift register has essentially the same layout, stepped and repeated. The shift register chips can directly drive 5V optocouplers so they eliminate the need for buffer chips for that purpose. This board could drive 14 motors with suitable plug-in adapters!
I guess this was a reply to me.
It does seem like a nice solution and more easily extendable for more motors than with a slave MCU perhaps. My thinking in that was more in the line of a 3D printer with max 5 or 6 motors and that you might be able to keep using the Mega board and Ramps or things like that. I was just just thinking about this few days before this article. I know about the ESP32 Ramps design, which i guess is abandoned, and i was just running things in my head how and what it would need.
I do think the whole concept is nice and simple and quite clever.
Is this board’s primary function to work with GCODE on the memory card or will it be able to interface steppers to LinuxCNC directly?
The board is just hardware. How it communicates depends on the software installed on the ESP32.
Anyway, my understanding is that this board is related to a branch of grbl and therefore is supposed to work with G-code. But with other software it could do completely other things.
Great design! I am really deeply impressed.
This is exactly what I was dreaming of for my 5-Axis project.
I am currently prototyping with an Arduino Mega to run 5 independent axis with proper speed and invested a lot of time to optimize the software for it, had some success, but the Arduino has its limitations. So I started to investigate the esp32 as a faster solution.
This led me to this project and I could not have imagined any better solution. I like the modularity.
Not sure if the screw terminals for motors and power supply are detachable, but it would be a great feature.
Also the pololu dummies are a great addition.
Looking forward to see it ready for orders!
The terminals are detachable. The motor terminals slide onto a row of pins and can be oriented with the wires exiting either horizontally or vertically, while the power connector is a pluggable terminal block.
Thank you for the clarification.
Every detail is just amazing!