0% found this document useful (0 votes)
15 views40 pages

Report Project CNC

CNC Engraver Machine Using Microcontroller

Uploaded by

by775471864
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views40 pages

Report Project CNC

CNC Engraver Machine Using Microcontroller

Uploaded by

by775471864
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 40

‫ذ‬ REPUBLIC OF YEMEN

SANA'A UNIVERSITY
FACULTY OF ENGINEERING
MECHATRONICS ENGINEERING DEPARTMENT

Project name:
CNC Engraver Machine Using Microcontroller

Done by:
Ahmed Ameen Al zubaidi AC. No:202073064
Mohammed Saleh AL_Sormi AC.NO: 202073240
Abdulrahman Mohammed Al-Aghbary A.C .NO:202174018
Rian Adnan Al-Aghbary AC.NO: 202174102
Motaz Essam AL-Qershi A.C.NO:202174048
Osama AlMasry A.C.NO:202170235
Rabie sarhan mohammed alabri A.C.No. 202274313

Supervised by:
Dr. Abdulah Dhiban
Project overview:
The term “CNC” refers to the process in which a computer follows a
set of instructions to send pulses to a stepper motor, power a spindle, heat an
extruder, or pulse a laser. Whatever type of CNC machine it may be, will have
a computer driving it. This project is 3-axis Router CNC machine the purpose
of this machine is to engrave on the wood. A simple 3-axis router CNC
machine is employed in a small work area and low cost. CNC means
Computer Numerical Control of machines. This is exactly the mission of
mechatronics is to control the machines using computer, this is the reason that
makes us choosing this project. The structure of the machine composed of
acrylic plastic for the frame, MDF (Medium-density fiberboard) wood is used
for the base. The motion of the system depends on four stepper motors, the
screws and nuts will convert the rotational motion to a linear motion and in
addition to the use of stainless-steel shaft to support the system. Arduino Uno
is used to control the system instead of specialized computers for each type
of machine. Autodesk Inventor 2020 (which encompasses the whole process
of planning, testing and executing a 3D design) have been used to make the
design and convert it to G-code. Universal G-code sender to send the G-code
to the Arduino, and the Arduino used to control the motion of CNC machine.

2
Table of content
Project overview____________________________________________________ 1

Table of content ____________________________________________________ 3

Table of Figure _____________________________________________________ 5

Chapter one Introduction ____________________________________________ 7

1.1 Preview: - ______________________________________________________7

1.2 project Idea: -__________________________________________________ 7

Chapter two Introduction to CNC machine and Working Stages______________ 8

2.1Introduction_____________________________________8

2.1.1 Type of CNC machines: __________________________________________ 8


2.1.2 Applications of CNC machine: ____________________________________ 11
2.1.3 Advantages of CNC: ____________________________________________ 11

2.2 How is the CNC Machine Used for Machining? ______12

2.2.1 Computer Aided Design (CAD): ___________________________________ 12


2.2.2 Computer Aided Manufacturing (CAM): ____________________________ 13
2.2.3 G-code: ______________________________________________________ 13
2.2.4 Machining Stage: ______________________________________________ 14

Chapter Three Hardware and Software ________________________________ 15

3.1 Hardware ____________________________________ 15

3.1.1 Electronics Parts ______________________________________________ 15


3.1.2 Mechanical Parts _____________________________________________ 17
3.1.3 Electromechanical Parts _______________________________________ 21

3.2 Software____________________________________ 22

3.2.1 Autodesk Invertor with Invertor CAM Integrated Software. ___________ 22

3
3.2.2 GRBL ______________________________________________________ 23
3.2.3 Universal-G-Code-Sender______________________________________ 23

Chapter 4 Calculations and Results __________________________________ 24

4.1 Calculations ___________________________________ 24

4.1.1 Mechanical Design and Stress Analysis ___________________________ 24


4.1.2 Electrical Connection _________________________________________ 36

4.2Results_______________________________________________________ 39
4.2.1 The Final CNC-Machine ________________________________________ 39
4.2.2 Results of CNC-Machine Operation Tests __________________________ 41

Chapter 5 Conclusions, Future works and Problems ______ 43

5.1 Conclusions ___________________________________________________ 43

5.2 Future works __________________________________________________ 44

5.2.1 Adding features _______________________________________________ 44

5.2.2 Parts replacement _____________________________________________ 44

5.2.3 Design adjustment _____________________________________________ 45

5.3 problems _____________________________________________________ 45


5.3.1 The cost of the components: - ___________________________________ 45
5.3.2 Availability of the components ___________________________________ 46

References _______________________________________________________ 48

4
Table of Figure
Figure 1: CNC-Machine Model _______________________________________________________________ 2
Figure 2: CNC router _______________________________________________________________________ 9
Figure 3: CNC plasma ______________________________________________________________________ 9
Figure 4: CNC laser _______________________________________________________________________ 10
Figure 5: 3D printers ______________________________________________________________________ 10
Figure 6: Pick and Place CNC________________________________________________________________ 11
Figure 7:CNC-machine using steps ___________________________________________________________ 12
Figure 8: Computer Aided Design (CAD) step ___________________________________________________ 12
Figure 9: Computer Aided Manufacturing (CAM) step ____________________________________________ 13
Figure 10: G-code step ____________________________________________________________________ 14
Figure 11: Machining Stage ________________________________________________________________ 14
Figure 12: Arduino IDE ____________________________________________________________________ 15
Figure 13:Arduino UNO ____________________________________________________________________ 15
Figure 15: CNC-shield-V3 __________________________________________________________________ 16
Figure 16: Stepper Motor Driver a4988 _______________________________________________________ 16
Figure 17: Stainless Steel Shaft ______________________________________________________________ 17
Figure 18: Lead Screw with trapezoidal nut ____________________________________________________ 18
Figure 19: Linear Bearing Block _____________________________________________________________ 18
Figure 20: Shaft Support ___________________________________________________________________ 18
Figure 21: Flexible Coupling ________________________________________________________________ 19
Figure 22: Spindle Holder __________________________________________________________________ 19
Figure 23: Acrylic Plate ____________________________________________________________________ 20
Figure 24: Stepper Motor NEMA 17 __________________________________________________________ 21
Figure 25: 400W Spindle ___________________________________________________________________ 21
Figure 26: Autodesk Invertor 2020 ___________________________________________________________ 22
Figure 27: Grbl __________________________________________________________________________ 23
Figure 28: Universal G-Code Sender __________________________________________________________ 23
Figure 29: X-axis motor side ________________________________________________________________ 25
Figure 30: X-axis ball bearing side ___________________________________________________________ 25
Figure 31: Y-axis ball bearing corner _________________________________________________________ 26
Figure 32: Y-axis motor corner ______________________________________________________________ 26
Figure 33: Z-axis carriage side ______________________________________________________________ 26
Figure 34: Z-axis motor side ________________________________________________________________ 27
Figure 35: Z-axis ball bearing side ___________________________________________________________ 27
Figure 36: Spindle carriage _________________________________________________________________ 28
Figure 37: CNC-machine design isometric view. _________________________________________________ 29

5
Figure 38: CNC-machine design side view. _____________________________________________________ 29
Figure 39: CNC-machine design top view. _____________________________________________________ 30
Figure 40: CNC-machine design front view. ____________________________________________________ 30
Figure 41: Displacement Analysis result of Y-axis ________________________________________________ 32
Figure 42: Displacement Analysis result of X-axis ________________________________________________ 33
Figure 43: Von Mises Stress Analysis result of Y-axis _____________________________________________ 34
Figure 44: Von Mises Stress Analysis result of X-axis _____________________________________________ 35
Figure 45: circuit connection ________________________________________________________________
36
Figure 46: Vref terminals __________________________________________________________________ 37
Figure 47: CNC-machine isometric view _______________________________________________________ 39
Figure 48: CNC-machine front view __________________________________________________________ 40
Figure 49: CNC-machine side view ___________________________________________________________ 40
Figure 50: Firsts results of machining tests _____________________________________________________
41
Figure 51: Finale accuracy level _____________________________________________________________ 41
Figure 52: engrave on MDF ________________________________________________________________ 42
Figure 53: wood milling ___________________________________________________________________ 42
Figure 54: to 4-axes CNC machine ___________________________________________________________ 44
Figure 55: design configuration to hidden Y-axis under the work table. ______________________________ 45
Figure 56: 3-D printed linear bearing block ____________________________________________________ 47
Figure 57: Connect the screw to structure using shaft support SK10 ________________________________ 47

6
Chapter one Introduction

1.1 Preview: -

An introduction and the aim of the project will be introduced in


chapter 1. In chapter 2, general information About CNC machine will be
seen. Chapter 3 will refer to the hardware and software, chapter four will
refer to calculations and results. And finally, the conclusions, problems
and future works will appear in chapter 4.

1.2 project Idea: -

CNC-machine is used in various machining operations such as


drilling, milling, engraving, drawing and cutting. In this project, the 3-axis
CNC-machine will be used for drilling, engraving, cutting wood. This
means it can be used to make some of the pieces used to build other projects
or machines, as well as the manufacture of medals and small decorative
pieces, can be made

7
Chapter two Introduction to CNC machine and
Working Stages

2.1 Introduction

Requirements of today’s industry are to produce large quantity and


quality products with low production and installation cost. These tasks can
be easily completed by the machines which are controlled by computers
to make work easier with ultra-precision and less human caused errors.
These are commonly known as

CNC (Computer Numerical Control) Machines. In Industry it is not


efficient or profitable to make everyday products by hand. On a CNC
machine it is possible to make hundreds or even thousands of the same
items in a day. The Computer Numerical Control (CNC) machining is a
process used in the manufacturing sector that involves the use of computers
to control machine tools. Under CNC machining, machine tools function
through numerical control. A computer program is customized for an object
and the machines are programmed with language called G-code that
essentially controls all features like feed rate, coordination, axis motions,
location and speed.

2.1.1 Type of CNC machines:

Different kinds of CNC machines cover an extremely large variety.


Their numbers are rapidly increasing, as the technology development
advances, some of CNC types will be listed below [1]: -

8
1. Router: - A CNC router can cut and engrave wood, metal, or plastic
and is a very common type of CNC machine. The user does not
manipulate the router, only enters information into the computer.
Such as milling machines, lathes machine and grinders.

Figure 2: CNC router

2. Plasma: - CNC plasma cutters are used to cut metal and wood (2
dimensional) and do not require as much power as a CNC router. These
machines use a plasma torch to penetrate wood or sheet metal.

9
Figure 3: CNC plasma

3. Laser: - CNC laser cutters operate quite like CNC plasma cutters,
but instead, a laser is used to cut the wood or metal. Lasers can also
be used to cut plastic.

Figure 4: CNC laser

10
4. 3D Printer: - 3D printers use CNC technology and operate using
similar technology as CNC lasers, but utilize an extruder to slowly
deposit plastic in a consistent motion until the desired product is
complete.

Figure 5: 3D printers

5. Pick and Place: - Pick and Place CNC Machines consist of several
nozzles that pick up electrical components for electronic equipment
and place them in the desired location. These are very commonly
used in the construction of cell phones, computers, tablets, etc.

11
2.1.2 Applications of CNC machine:

There are various industrial applications of CNC machines in many fields.


The machine being computer-controlled makes more effective accuracy, thus
being able to work on a specific space without destroying the other parts. As a
result of that feature, the machine in question becomes essential in various
firms. Plastic, metal, computer parts, and Wood manufacturers, electrical, and
metal fabrication industries are some of the crucial CNC machine users, among
other firms [2].

2.1.3 Advantages of CNC [3]:

1. CNC machines are programmed with a design which can then be


manufactured hundreds or even thousands of times. Each
manufactured product will be exactly the same.
2. Less skilled/trained people can operate CNCs unlike manual lathes
milling machines which need skilled engineers.
3. CNC machines can be updated by improving the software used to
drive the machines.
4. Modern design software allows the designer to simulate the
manufacture of his/her idea. There is no need to make a prototype or
a model. This saves time and money.
5. One person can supervise many CNC machines as once they are
programmed, they can usually be left to work by themselves.

2.2 How is the CNC Machine Used for Machining?

There are four steps to using the CNC machine for the machining process,
each step has several programs to do this. This section explains those steps and

12
the program that we used for each step in this project. Figure [7] show steps
for using a CNC-machine.

Figure 7: CNC-machine using steps

2.2.1 Computer Aided Design (CAD):

A Software used to prepare 2-D drawings or 3D models used to design


products. Figure [8] show CAD step. Software used for CAD [4]:

1. Autodesk Inventor 2020, this is what we chose to create CAD


designs.

2. SolidWorks.

3. Fusion 360.

2.2.2 Computer Aided Manufacturing (CAM):

CAM software prepares a model for machining by working through


several actions, including [5]:

13
• Checking if the model has any geometry errors that will
impact the manufacturing process.
• Creating a toolpath for the model, which is a set of
coordinates the machine will follow during the machining
process.
• Setting any required machine parameters including cutting
speed, voltage, feed rate, etc.

We chose Autodesk Inventor 2020 With CAM integrated plug in.


Figure [9] show CAM step

Figure 9: Computer Aided Manufacturing (CAM) step

2.2.3 G-code:

G-Code or Geometric Code is the generic name for a control


language for CNC machines. It is a way to tell the machine to
move to various points at a desired speed, control the spindle
speed, turn on and off various coolants, and all sorts of other
things. It is fairly standard, and is a useful tool. The standard
version of G-code is known as RS274D. Since G-codes are

14
preparatory codes, in a CNC program they begin with the letter
G and direct the machine. Figure [10] show G-code step. [6]

Figure 10: G-code step

2.2.4 Machining Stage:

Orders are sent from the G-code to the machine, which responds to it by
performing machining process by stepping motor movement and spindle
movement. Figure [11] show Machining Stage.

We chose Universal G-Code Sender to send g-code to the Arduino and


control the CNC-machine

Figure 11: Machining Stage

15
Chapter Three Hardware and Software
3.1 Hardware

3.1.1 Electronics Parts

3.1.1.1 Microcontroller (Arduino Uno) (× 1).

The Arduino UNO shown in figure [12], is an open-source microcontroller


board based on the Microchip ATmega328P microcontroller and
developed by Arduino.cc. The board is equipped with sets of digital and
analog input/output (I/O) pins that may be interfaced to various expansion
boards (shields) and other circuits. The board has 14 Digital pins, 6 Analog
pins, and programmable with the Arduino IDE (Integrated Development
Environment) via a type B USB cable [7].

Figure 13: Arduino UNO Figure 12: Arduino IDE

16
3.1.1.2 CNC-Shield-V3 (× 1).

The CNC Shield was designed by Protoneer.co.nz to take advantage of


the demand for a low-cost controller solution for DIY CNC machines. It
was designed to be 100% compatible with Garble, the Opensource G-
Code interpreter, and fit onto the popular Arduino Uno. The CNC Shield
can be used to control a number of different types of CNC machines,
including CNC milling machines, laser
engraving/cutting machines, drawing
machines, 3D printers or any project that
needs precision control of stepper
motors. It uses compatible stepper
drivers, either the A4988 or the higher
current DRV8825 [8].

Features:

• 4-Axis support (X, Y, Z, A-Can duplicate X, Y, Z or do a full 4th axis)


• Uses GRBL as control software
• Power supply: DC 12-36V

3.1.1.3 Stepper Motor Driver a4988 (× 4).

The A4988 is a complete micro stepping motor driver with 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 35 V and ±2 A. The A4988 includes a fixed
off-time current regulator which has the ability to operate in Slow or
Mixed decay modes [9].

17
Features:

• 3.3 and 5 V compatible logic supply


• Output Current ±2 A
• Load Supply Voltage 35 V

Figure 15: Stepper Motor Driver a4988

3.1.2 Mechanical Parts

3.1.2.1 Stainless Steel Shaft (8mm Dia.).

The material properties of stainless steel shaft are shown in the table [1].
Also, the dimensions and quantiles shown in table [2].

18
3.1.2.2 Lead Screw with Trapezoidal Nut (8mm Dia.).

This part will convert the rotational motion into linear


motion and transmit it to next axis. The dimensions
and quantities

3.1.2.3 Linear Bearing Block SCS8UU (Closed – 8mm Dia.) (× 10).

A linear-motion bearing or linear slide is a bearing designed to provide


free motion in both directions [10].

3.1.2.5 Flexible Coupling Motor Shaft (5mm x 8mm) (× 4)

Flexible couplings are usually used to transmit torque from one shaft to
another when the two shafts are slightly misaligned. They can also be
used for vibration damping or noise reduction

19
3.1.2.7 Ball Bearing 608ZZ (8mm inner Dia.) (× 4).

The purpose of a ball bearing is to reduce rotational friction and support


radial and axial loads on the shafts.

3.1.2.8 Acrylic Plates.

Is are made from acrylic, and they carry the motors, spindle and other
parts. Acrylic boards are drawn and designed in Autodesk Inverter 2020
and the boards are cut with laser CNC-Machine. The material properties
for acrylic are shown in table [6].

20
3.1.3 Electrical Parts

3.1.3.1 20 Volt DC Power Supply

3.1.4 Electromechanical Part

3.1.4.1 Stepper Motor NEMA 17 (× 4).

A stepper motor is an electromechanical device it converts electrical


power into mechanical power. Also, it is a brushless, synchronous
electric motor that can divide a full rotation into an expansive number of
steps. The motor’s position can be controlled accurately without any
feedback mechanism, as long as the motor is carefully sized to the
application [11].
Features
• Rated current 1.2 Amp.
• Step angle 0.11° or 3200 steps-per-
revolution.
• four-phase.
• permanent-magnet.
• holding torque of 3.2 kg-cm

Figure 23: Stepper Motor NEMA 17

3.1.4.2 400W variable speed spindle.

Features
• Speed range 6000-32000 RPM with 6000 RPM step.
• Voltage 220V.
• The maximum diameter of the cartridge is 6 mm

21
Figure 24: 400W Spindle

3.2 Software

3.2.1 Autodesk Invertor with Invertor CAM Integrated


Software.

Autodesk Inventor is a computer-aided design application for 3D


mechanical design, simulation, visualization, and documentation developed
by Autodesk.

Inventor allows 2D and 3D data integration in a single environment,


creating a virtual representation of the final product. Autodesk Inventor
includes parametric, direct edit and freeform modeling tools as well as
multi-CAD translation capabilities and in their standard DWG drawings
[12].

Inventor CAM is software that use to create advanced tool paths to machine
models using 2.5D, 3D and 3+2 milling applications, as well as support for
Simultaneous 4- and 5-axis features for machining complex models
including multi-axis contouring [13].

22
Figure 25: Autodesk Invertor 2020

Chapter 4
Calculations and Results

4.1 Calculations

4.1.1 Mechanical Design and Stress Analysis

4.1.1.1 Mechanical Design

We saw many CNC designs on the Internet to get ideas before we


started designing our model, and there were many options, but we faced a
big problem, which is the availability of materials locally in the Mosul city.

Initially, we considered using 3D printed parts. This was our first choice
because the 3-D printer prints parts with high accuracy and with desired
design. However, 3D printing is very expensive and the resulting parts do
not have enough strength. We searched a lot to find a material with high

23
strength and can be cut with CNC machine, so we can get the design that
we desired.

We select acrylic as the material for the frame. We can get the desired
shape and size of acrylic with good price and very good precision by
cutting it with laser CNC-machine.

The machine structure consists of frame, base, supporting beam and motion
transition system.

• The frame is made from 10 plates 10mm thickness acrylic. The


frame holds the spindle and connects the machine parts together. We
designed acrylic plates in Autodesk 2020 inventor program. Figures
[28] through [35] show the designs and dimensions of the acrylic
plates
• The base is made from MDF (medium density fiberboard) cut by
CNC machine, we made eight rectangular cross-sectional areas so
that we could fix the acrylic parts inside it to have more stability.

• The rotational motion of the stepper motor must be converted to


linear motion and this can be done using several methods,
including: Either using belts, this is used for the CNC laser
machine because it does not require a lot of high torque to move
the axes, or we can use a lead screw with trapezoidal nut. We
choice to use an 8mm lead screw with a trapezoidal nut. We used
8mm Stainless steel beams, two in the z-axis, two in the xaxis and

24
one in the Y-axis. They are used to connect the parts of the
machine together, support and to guide the linear bearing. We
used 8 bearings to ensure stability and smooth motion, 4 in Y-
axis, 2 in X-axis and 2 in Z-axis. Figures [36] through [39] show
our 3-axes CNC-Machin

Figure 36: CNC-machine design isometric view.

25
Figure 37: CNC-machine design side view.

26
4.1.2 Stress Analysis
4.1.1.2.1 Preview

Stress analysis was done using the Auto Disk Inverter 2020 program and
obtaining the results for both the Deflection in the Beam and the Von Mises
Stress, and then the safety coefficient was calculated to ensure the safety
of the design.

We assumed that the center of gravity was located at the farthest point of
the spindle from the X-axis and this gives worse conditions on the beams,
so the supposed center of gravity is 12cm from the X-axis.

The spindle mass was measured with the Z axis components, which is the
mass loaded on the X-axis. And by measuring the mass of the components
of the X-axis and adding them to the mass of the components of Z-axis, we
have the mass loaded on the Y-axis

27
The mass loaded on the X-axis = 2.45 kg

The mass loaded on the Y-axis = 3.14 kg

By multiplying the masses by gravity accelerating, we get the forces


loaded on the axes.

Stress analysis was performed on the case when the Z-axis is in the
middle of the X-axis, as well as the X-axis in the middle of the Y-axis.
This gives the highest stress and deflection in the axis.

4.1.1.2.2 Displacement Analysis


Check design For Bending Deflection: - Deflection of a Beam Due to
Bending in General machine part: 0.000 5 to 0.003 in/in of beam length
[16].
Displacement Analysis of Y-axis

28
Y-axis (length 500 mm) :
Min. limit = 0.0005 * 500 = 0.25 mm
Max. limit = 0.003 * 500 = 1.5 mm
Deflection in Y-axis = 0.5625 mm
0.25 < 0.5625 < 1 is safe.

Displacement Analysis of X-axis

Figure 41: Displacement Analysis result of X-axis


X-axis (length 360 mm):
Min limit = 0.0005 * 360 = 0.18 mm
Max limit = 0.003 * 360 = 1.08 mm
Deflection in X-axis = 0.5608 mm
0.18 < 0.5605 < 1.08 is safe.

29
4.1.1.2.3 Von Mises Stress Analysis
Yield Strength of Stainless Steel = 250 MPa

Von Mises Stress Analysis Y-axis

Von Mises Stress = 48.24 MPa


Ny = Sy/σ = 250 / 48.24 = 5.1 is safe

30
Von Mises Stress Analysis X-axis

Figure 43: Von Mises Stress Analysis result of X-axis

Von Mises Stress = 71.66 MPa


Nx = Sy/σ = 250 / 71.66 = 3.4 is safe.

31
4.1.2 Electrical Connection

4.1.2.1 Circuit Connection

Installing the CNC Shield on the Arduino and installing the stepper
motor drivers a4988 on the CNC-Shield. We enabled the micro steps by
connecting their own pins to 5V, as well as connecting the pins
responsible for copying the Y axis of CNC-shield to the A axis to get
two stepper motor that have the same movement on the Y axis. The
stepper motors are connected to the CNC-Shield. 20V power source is
connected to the CNC Shield. The circuit scheme is shown in figure [44].

4.1.2.2 Current Limit for Stepper Motors

Stepper-motor current limiting serves a few functions. Stepper-motor


overcurrent can cause overheating. At its most extreme, overcurrent can

32
cause rotor demagnetization. So, any design that uses micro stepping
needs current limiting, as different windings require different current
levels [17]. The stepper motor driver A4988 allows to set a target current
anywhere between some mA up to a bit less than 2A, this is
accomplished by adjusting what is called the Vref (reference voltage)
when turning the potentiometer resistance of a4988 on a clockwise
direction the Vref voltage will increase and decrease when rotating it
counterclockwise [18].

The actual value of Vref can be calculated using the formula:

Vref = Imax * 8 * Rs

Rs: is sensing resistance (it is 0.1 ohm in our a4988).

Imax: is current limits

Our stepper motors have 1.2A rated current, we will operate it at 70%
of it’s rated current for safety, so:

Imax = 1.2A * 0.7 = 840MA

By substituting in Vref eq. we get:

Vref = 840mA * 0.1 * 8 = 0.672V

Now we must adjust potentiometer of a4988


until we measure 0.672 v on Vref terminals as
shown in figure [45].

4.1.2.3 Moving Distance for Each Step (mm/step).

In this section will calculate how many distance the spindle will move
when stepper motor move one step.

33
We had set stepper motor driver a4988 one 1/16 step mode. NEMA 17
stepper motor step angle is 1.8 𝑜 and number of steps per revolution is
200 steps.

Because we set a4988 on 1/16 step mode now the step angle will give
by: new step angle = 1.8/16 = 0.112𝟓 °

So, the new number of steps per revolution will become = 3,200 steps

The lead screw we used contains 2mm pitch and the fourth thread.
Therefore, the distance for each revolution will be given by:

Distance per revolution = 2mm *4 = 8 mm / rev

Then:

𝑫𝒊𝒔𝒕𝒂𝒏𝒄𝒆 𝒑𝒆𝒓 𝒔𝒕𝒆𝒑 = 𝑫𝒊𝒔𝒕𝒂𝒏𝒄𝒆 𝑷𝒆𝒓 𝑹𝒆𝒗𝒐𝒍𝒖𝒕𝒊𝒐𝒏 / 𝑵𝒖𝒎𝒃𝒆𝒓 𝑶𝒇


𝑺𝒕𝒆𝒑𝒔 𝑷𝒆𝒓 𝑹𝒆𝒗𝒐𝒍𝒖𝒕𝒊𝒐𝒏 = 8 / 3200
= 0.0025 mm/step
= 2.5 μm/step

4.2 Results

4.2.1 The Final CNC-Machine

The final result of this project is the completion of the manufacture of


the CNC machine with a medium workspace (40 cm in Y-axis, 24 cm in
X-axis and 3 cm in Z-axis) as shown in the figures [46] through [48].
With a transmission distance 2.5μm/step. The machine was successfully
run and tested in several operation tests.

4.2.2 Results of CNC-Machine Operation

34
Tests The machine has been tested in several milling and engraving
operations on wood, and work has been done to improve accuracy until
it reaches an excellent level. The results of these tests appear in figures
[49] and [51] and it shows improvement in work.

Figure 49: Firsts results of machining tests

5.1 Conclusions

The purpose of this machine is engraving and cutting wood.

• From this project, we learned the principles of CNC machine.


• We gained better understanding in the modes of operation of CNC
machine.
• We learned how to use CAD programs to make 2-D sketches and
3-D models using Autodesk Inventor 2020.
• We learned how to use CAM programs to convert the 3-D models
into G-code and set the required setting of the machine.
• The machine was fabricated successfully and during testing it
worked well.

35
• We had chosen this project because it combines mechanics and
electronics, controlling the machines using computer and this is
exactly the mission of mechatronics. We made a complete
mechanical design with stress analysis using Inventor program
from Autodesk.
• So that we could choose the appropriate parts for our machine.
Our project is to make a simple 3-axis router CNC machine of
small work area and low cost.
• We used acrylic (PMMA) for the frame, we designed it with an
Inverter program and cut it with a CNC laser.
• We used MDF wood for the base.
• We use drill for engraving.
• The motion system depends on four stepper motors one for x-axis,
one for z-axis and we used two for Y-axis to get higher stability.
• We used screws-nuts system to convert the rotational motion from
motors into linear motion.
• We used Arduino Uno as a controller
• Inventor CAM program to create 3D model and convert into G-
code. The motion of CNC will be controlled by GRBL program.

5.2 Future works

Future work includes three sections: adding features, some parts


Replacement, and design adjustments.

5.2.1 Adding features

• Converting the CNC machine from 3-axes to 4-axes, this is by


adding a fourth rotating axis on the base of work that will enable
the work of the 4- axis milling as well as turning.
36
• Adding limit switches to control the movement limits of the axes,
which will add better control capabilities to the machine as well
as increase its safety.
• Adding a relay switch to control on/off spindle through the
control program.

5.2.2 Parts replacement

The goal of switching some parts is to use higher quality parts and better
capabilities, to increase accuracy and eliminate misalignment and
vibration. Noting that the required parts for the improvements are either
not available in Iraq or that are very expensive.

• Replacing the Liner bearing Block Guide to a linear Profile Rail


Guide that has a much higher accuracy.
• Replacing the flexible coupling with the rigid coupling.
• Replacing the hand screw with ball screw and use anti backlash
trapezoidal nut instead of normal trapezoidal nut.
• Replacing the stepper Motor Driver A4988 with the DRV8825,
which gives an additional step mode that is 1/32 step mode

5.2.3 Design adjustment

• The Y-axis design is designed so that the Y-axis is hidden under


or beside the work table, which prevents the material chips from
entering the lead screw teeth, which impedes movement, as
shown in figure [54]

37
• Adding another ball bearing support for lead screw on the side of
the stepper motor, which will increase the stability of the lead
screw

5.3 problems

During our work in the project we faced many problems, the reasons of
these problems are

5.3.1 The cost of the components: -

• The cost of the components of the machine was a big problem for
us. At first, we made a complete design to make the structure of
the machine by using 3-D printed parts. But the 3-D costs a lot, so
we made a new design and we chose acrylic plates to be our
structure. The acrylic has high strength and we can get the desired
parts by cutting it with CNC machine and it costs half of the 3-D
printed parts.
• The drills that are used in CNC machines must be of light weight
and small size, and this type of drills have very high price (+70$),
we could not buy it because of its high price. We searched in the
local markets for alternatives, then we found one that suits our
work with much lower price.
• The stepper motors that used in CNC are of bipolar type and they
must have high accuracy. This type of motors has high price
(+20$). We passed this problem by buying second hand motors
which costs us much lower price. These motors were of Unipolar

38
type and we need bipolar type. Then we could find a solution and
passed this problem by using only four wires of the unipolar motor
so it becomes bipolar.

5.3.2 Availability of the components

• Machine parts are not available in Mosul, we could find these


components and items only at one store in Baghdad, or we can
buy them from internet and this may take long time.
• The components that are available in the local markets were from
the bad quality which made a big problem for us. The linear
bearings and the nuts have a high clearance, and this make a big
problem in term of stability and deflection. But we passed this
problem by design new linear bearing block and print it by 3-D
printer and added to the machine so we have double bearing in
the Y-axis as shown in the figure [55]. This step increased the
stability of the machine and eliminate the deflection.
• The motion system depends on lead screw with nut, we faced a
problem of how we can connect the screw to structure. We used
shaft support SK10 which can be fixed in the axes and connected
with the lead screw nut as shown in the figure [56]

References:
[1] https://www.tramarindustries.com/2019/05/20/5-common-types-
of-cncmachines/

[2] https://www.coadengineering.com/industrial-applications-of-
cncmachines/#:~:text=Unquestionably%2C%20there%20are%20
various%20ind
ustrial,CNC%20machines%20in%20many%20fields.&text=Plasti

39
c%2C%20
metal%2C%20computer%20parts%2C,machine%20users%2C%2
0among% 20other%20firms.

[3] http://www.technologystudent.com/cam/cncman4.htm

[4] https://en.wikipedia.org/wiki/Computer-aided_design

[5] https://www.autodesk.com/products/fusion-360/blog/computer-
aidedmanufacturing-beginners/

[6] https://en.wikipedia.org/wiki/G-code

[7] https://en.wikipedia.org/wiki/Arduino_Uno

[8] http://makerhardware.net/wiki/doku.php?id=electronics:cnc_shiel
d

[9] Allegro MicroSystems A4988-Datashee

[10] https://en.wikipedia.org/wiki/Linear-motion_bearing

[11] https://www.elprocus.com/stepper-motor-types-
advantagesapplications/

[12] https://en.wikipedia.org/wiki/Autodesk_Inventor

[13] https://www.graitecusa.com/cad-
software/manufacturing/inventor-hsmcam

[14] https://github.com/grbl/grbl

[15] https://github.com/winder/Universal-G-Code-Sender

40

You might also like