CNC Electronic Control
My CNC uses an Arduino running GRBL along with UGS sending commands to the Arduino. The Arduino then uses step and direction pulses to control the NEMA 23 steppers. The Arduino also controls the spindle, along with the air blast (to clear grindings) through a solenoid actuator.
When I first wired my CNC up I just taped two bread boards to a wall and hoped none of the wires would get bumped! After a few months I decided I should make a proper box for it before it falls apart. So over a 2 week period I redesigned all the wiring. I also added drag chains and sleeves on the wires to protect them. I added support for the spindle to be controlled by g-code, and spent a while trouble shooting electrical noise problems. I narrowed down electrical noise problem to the solenoids and relays. The problem was fixed with some capacitors and iron rings around the wires (to increase inductance.)
Through this project, I have learned a lot about circuit design, wiring and dealing with electrical noise. Arduinos are more sensitive to noise than PLCs or more traditional and expensive controllers. I have spent a lot of time troubleshooting electronics and almost every problem was caused by electric noise, only once did I have a problem due to a loose cable. In all my subsequent projects I’ve focused a lot of effort on designing circuits to be isolated with optocouplers and isolated DC-DC power supplies. Particularly for my more critical systems and sensitive microcontrollers.