Skip to content

Hardware

Pascal Roobrouck edited this page Jun 26, 2017 · 13 revisions

CNC machines are powerful machines : motors running at high voltages / high currents (24V and more, 2A and more). Spindles of 700W or more, running on 230Vac.
On the other hand, the uController is a fragile device : running at 3.3V - 120 MHz.

Mooov thinks it is not a good practice to put all that on a single board. As there are plenty of good stepper-motor drivers, power supplies, solid-state relays, the CNC controller should just properly interface to those standard components. Mooov drives opto-coupled stepper drivers and solid-state relays. It reads it's buttons and limit-switches from opto-coupled inputs.

Stepper Motor Drivers

Dedicated motor drivers, based on Toshiba TB6600A are available at very low cost. They can be powered with 12, 24 or 36V and deliver up to 4A per motor winding. Microstepping ensures a very smooth movement. Maximum current and microstepping-mode can be selected with a set of DIP-switches.
The interface towards the uController is opto-coupled and standardized (enable, step, dir), so at any time you can upgrade this part to something better (eg Servo Motors) without any changes to the overall architecture.
Stepper Motor Driver - TB6600A - Front Stepper Motor Driver - TB6600A - Back

Limit Switches

Limit Switches indicate to the controller that the machine is trying to move beyond its limits. Reliable Limit Switches are not an easy thing : with its many powerfull motors moving all at the same time, a CNC is an electromagnetically noisy environment. The result is that the sensitive digital input of the controller may detect a false positive, ie. think that a limit switch is closed, while actually it is only an electromagnetic spike on one of the wires. The below scheme is one of the better ways to defend yourself against this. Use shielded wires if possible for maximum EMI resistance.

After experimenting with lots of limit-switch setups, I can recommend the following:

  • Keep the cables from the switches as short as possible: this implicates to have the triggering 'finger' moving, and the switch itself stationary:
    • For the Z-axis : have two 'fingers' moving up/down with the Z-axis, and have the switch(es) itself fixed on the XY gantry.
    • For the X/Y-axis : have the finger on the gantry, and the switch on the base of the machine.
  • Optical switches such as OMRON's EE-SX-670 family have interesting advantages :
    • They can be used with 5 to 24 Vdc
    • They can provide Normal Closed (NC) or Normal Open (NO) signal, so no need to invert the signal further down the processing.
    • They provide an optical indication of their state
    • They have very accurate opening/closing position, so they will provide accurate homing. One disadvantage is that they may give a false trigger due to dust or chips, so they may need regular cleaning.

Limit Switches

The Microcontroller

Currently we are targeting the Teensy 3.5 controller, for the following reasons:

  • ARM Cortex M4F processor, 32-bit running at 120 MHz
  • The M4F supports floating point calculations in hardware. These calculations are used extensively in the controller software
    In case of the Teensy 3.5, this processor comes in the NXP K64 which offers
  • High resolution timers for accurate timing of all events
  • Interfaces such as Serial and USB
  • SD-card, which can be used to store settings and/or G-Code (sub)programs
  • Digital to Analog convertors - DAC, which can control Spindle speeds (or laser power) with high accuracy
  • Programmable interrupt priorities, so the real-time tasks can get priority on all the other stuff.
  • There is still an upgrade path with Teensy 3.6, pin compatible, with more throughput.

Teensy 3.5

Solid State Relays

On top of controlling the axis motors, the CNC Controller controls several other devices:

  • the Spindle (can be a simple ON/OFF spindle, or more advanced one with Speed and Direction controls)
  • Coolant
  • Dust collection
  • Vacuum table

All the ON/OFF devices are typically switched with relays. Traditional electromechanical relays produce a burst of EMI when switching. EMI can be drastically reduced by using Solid State Relays. The switch on and off in the zero-crossing of the AC voltage, and as such produce no EMI. There is a small voltage drop over the device, and when switching high currents they need to mounted on a heat sink.

Solid State Relais

Semi Assembled Controller