2D Plotter

 Status : Completed

Tags: arduino servo stepper cnc motor_driver gcode



AIM

To secure a portable two axis CNC plotter which can perform complex drawing according to the given


COMPONENTS AND TECHNOLOGIES USED

  • arduino

  • cnc

  • stepper

  • gcode

  • servo

  • motor_driver


OVERVIEW

XY plotter is capable of drawing computer processed binary images on a page. Arduino is used to control movements of the stepper motors along X-axis and Y-axis. Servo motor is used to control movement of plotting pen on the Z-axis. The coordinates are uploaded to the machine controller by a separate program. The image file is transformed into G-code via Inkscape. Then the code is transferred to the microcontroller by which the motor mechanism is instructed to draw the image.

Components

  1. Arduino Uno Microcontroller

           Arduino Uno is a microcontroller that provides easy way for student or professional to create own devices in cheaper way. Arduino is an open source microcontroller that runs under C and C++ language programme. The coding written to Arduino board can be overwritten any time when you wish to do another project. With help of CNC Shield V3, it will be able to control the stepper motor in the easiest way. 

2. CNC Shield V3

CNC Shield basically is a stepper motor driver board that receives signal from Arduino Uno microcontroller and requires external power source to deliver to the stepper motors.With this shield and Arduino Uno microcontroller, the CNC machine such as pick and place machine, CNC router, engraving machine and also 3D printer project can be done.

 

3. Stepper Motor

Nema17 Stepper motor is a type of dc synchronous motor.Whereas the rotation of an induction motor is largely uncontrollable, the rotation of a stepper motor can be  controlled with a remarkable degree of precision. Stepper motor can produce full, instantaneous torque- even from a standstill.

 

4. Servo motor

A servo motor is a type of motor that can rotate with great precision.This  motor consists of a control circuit that provides feedback on the current position of the motor shaft, this feedback allows the servo motors to rotate with great precision.Servo motor is controlled by PWM (Pulse with Modulation) which is provided by the control wires. There is a minimum pulse, a maximum pulse and a repetition rate. Servo motor can turn 90 degree from either direction form its neutral position.

5. Drv8825 Motor driver

The Drv8825 is a complete micro-stepping motor driver with a built-in translator for easy operation. It is designed to operate bipolar stepper motors in full-, half-, quarter-, eighth-, and sixteenth-step modes, with an output drive capacity of up to 45 V and ±2.2 A.

             


 

Software

 

1.Arduino IDE

The Arduino IDE is an open-source software, which is used to write and upload code to the Arduino boards. The IDE application is suitable for different operating systems such as Windows, Mac OS X, and Linux. It supports the programming languages C and C++. Here, IDE stands for Integrated Development Environment.

(Download Link: https://www.arduino.cc/en )

2.Inkscape

Inkscape is a Free and open source vector graphics editor for GNU/Linux, Windows and macOS. It uses vector graphics to allow for sharp printouts and renderings at unlimited resolution and is not bound to a fixed number of pixels like raster graphics. The same line is shown on the left and right. On the left it is displayed as a bitmap image, while on the right it is displayed as a vector. In both cases, the line has been scaled up by a factor of four from its nominal size.

(Download Link: https://inkscape.org)

 

3.Universal G-Code Sender:

It is used to generate G-Code from vector image.

(Download Link: https://winder.github.io/ugs_website)

4.MI GRBL: 

GRBL is the open source firmware freely available for every one, GRBL is used as firmware for CNC machine. GRBL CNC Shield is used as controller for CNC machine, GRBL shield and GRBL firmware is very best for 3 axis stepper CNC machine.It  provides G-Code to the Arduino board attached with a CNC shield.

(Download Link: https://github.com/grbl/grbl

Working of the machine-

  1. Connect the cnc shield to the arduino.
  2. Join the motor driver to the cnc shield and connect the pin as per the reference given in the circuit diagram.
  3. Upload the grbl file in the arduino uno to the arduino.
  4. Open the universal code sender and go to the firmware setting and import a file given in the drive .(for the first time)
  5. Open the Inkscape app and first, add an extension to it.
  6. Go to the document properties and set the page size.
  7. Upload an image and go to trace bitmap, adjust the threshold and upload the image. Delete the previous image.
  8. Generate the g-code of an image .
  9. Open the grbl controller and adjust the speed ,position and acceleration using various commands .
  10. Upload the g-code of an image which  was generated earlier.
  11. Enter the begin and it will start plotting the image.

Methodology -

 XY Plotter is a simple, modern, accurate, and adaptable pen plotter, capable of writing or drawing on almost any flat surface. It can write with any favorite fountain pens, permanent markers, and other writing implements to handle an endless variety of applications. Its unique design features a writing head that extends beyond the machine, making it possible to draw on objects bigger than the machine itself.

The G-Code file is created by the help of Inkscape software then the processing software is used to send the G-Code file to the Arduino controller unit (via USB) then the CNC shield drive sends the controlling signals to the stepper motors and servo motor. Now the XY axis which operates as follows by the instructions given to the controller unit.The rods to align the X and Y structure to give the output in the provided sheet. The rod for the X and Y axis are not fixed. Their movement is supported by the bearings which provide soft and accurate movement for structuring the output image to text. Initially, the rods are in central alignment. They are inputted by transmitting the procedural comments and executing the required function. The input power is 12V. Commercially it is very low power and energy saving. The pen holder is fitted over the axis with the servo motor unit that helps for the up and down movement of the pen according to the signal received. The ON and OFF of the pen is according to the signal input. 

 

 

 

 

Circuit diagram - 

Video link - 

https://www.youtube.com/watch?v=dLojHmgkan

 

Resources -

https://drive.google.com/drive/folders/1B-DGbZmiHun9QShiPCW2L0EzerrI5Soa?usp=sharing

 

CNC Pen Plotter Part 2 | Drawing & Writing Machine | Software Tutorial Hindi | ElectroCSE

 

Stepper Motors and Arduino - The Ultimate Guide

 

 https://www.instructables.com/How-to-Control-a-Servo-Using-GRBL/

 

CNC Shield, Arduino UNO, DRV8825 - Tips for success!

 

DIY Arduino Writing/ Drawing Machine - 2D Pen Plotter

 

GRBL with Arduino CNC Shield – Complete Guide

Real-life applications -

CNC (Computer Numerical Control) machines are versatile and widely used in various industries for precision machining and manufacturing. Some common applications of CNC machines include:

  1. Aerospace: CNC machines are used to manufacture complex components for aircraft, such as engine parts, landing gear, and structural components. They enable high-precision machining of materials like aluminum, titanium, and composites, which are commonly used in aerospace applications.
  2. Automotive: CNC machines are used in the automotive industry for manufacturing engine components, transmission parts, chassis components, and other precision parts. CNC machines allow for high-speed production, tight tolerances, and consistent quality, which are crucial in automotive manufacturing.
  3. Medical: CNC machines are used in the production of medical devices, implants, and prosthetics. They enable precise machining of materials like stainless steel, titanium, and plastics to create complex shapes and geometries required for medical applications.
  4. Electronics: CNC machines are used in the production of printed circuit boards (PCBs), which are used in electronic devices such as smartphones, computers, and appliances. CNC machines are used for PCB drilling, routing, and engraving, ensuring precise alignment of components on the board.

Problem faced -

  1. One of the primary challenges in making a CNC XY plotter is designing a suitable mechanical structure that is both stable and precise. The design should be able to handle the weight of the components and provide accurate movements along the X and Y axes.
  2. Motors: The motors used in a CNC XY plotter should be powerful enough to move the components smoothly and accurately. They should also be compatible with the control system and the software being used.
  3. We faced while tightening the nut in 4 Start T Type Copper Nut in a threaded screw.Set a proper angle to tighten the nut.Make sure proper space in the flank of threaded screw to tight that nut.
  4.  Stepper motor making sound and vibrating. To reduce this we do microstepping.
  5. Motor drivers get heated faster. To reduce this we set the current limit.Adjust the potentiometer to set the desired reference voltage. The reference voltage is proportional to the current limit, and the relationship between the two is given by the formula: Current Limit = Vref x 2 / 1.5. For example, if you want to set the current limit to 1A, you need to set the reference voltage to 0.67V (1A x 1.5 / 2).
  6. In the pen holder ,there is no thread to tighten the nut due to which the pen is vibrating.So, we put the nut inside the model with help of soldering for the same size of bolt.
  7. The net torque on the X and Y axes arms should be zero.

CONTRIBUTORS -

Name

Branch

Reg. no.

          ADITYA NARAYAN GOND

ELECTRICAL ENGINEERING

20212100

GAURAV KUMAR

ELECTRICAL ENGINEERING

20212008

PUSHPAK KUMAR

ELECTRICAL ENGINEERING

20212023

RAJ VARDHAN

MECHANICAL ENGINEERING

20213033

AMAN DEVA

MECHANICAL ENGINEERING

20213093

PRAGATI SINGH

MECHANICAL ENGINEERING

20213015

MENTORS 

MEHUL SINGHAL (FINAL YEAR)

PURUSHOTAM KUMAR AGRAWAL (FINAL YEAR)

ABHISHEK HANOTIYA (THIRD YEAR)