Upload
dobao
View
216
Download
2
Embed Size (px)
Citation preview
http://www.iaeme.com/IJMET/index.asp 09 [email protected]
International Journal of Mechanical Engineering and Technology (IJMET) Volume 7, Issue 6, November–December 2016, pp.09–21, Article ID: IJMET_07_06_002
Available online at
http://www.iaeme.com/ijmet/issues.asp?JType=IJMET&VType=7&IType=6
Journal Impact Factor (2016): 9.2286 (Calculated by GISI) www.jifactor.com
ISSN Print: 0976-6340 and ISSN Online: 0976-6359
© IAEME Publication
WIRELESS AUTOMATION AND MACHINE
LEARNING OF A ROLLING-MILL USING ARDUINO
AND ANDROID
Karna Patel, Mrudang Patel, Nirav Oza
Mechanical Department, Institute of Technology, Nirma University, Ahmedabad, India
ABSTRACT
Generally, in all workshops, rolling mills are used for manufacturing, sheets of required
thickness. These mills are generally operated manually in low cost establishments. Since the labor
charges are increasing rapidly, a need for economic and efficient automated systems is inevitable
for optimum and uninterrupted manufacturing. The motive behind development of this system is to
avoid continuous human monitoring and errors thereof. This can also enhance human safety with
added benefit of time saving and reduction in resource requirement. As a value addition, it
provides a live and continuous quality check and quality assurance which in turn saves a lot of
time, labor and cost along with eliminating human errors. This standalone system can be installed
on any operational rolling mill of low cost establishment.
Key words: Automation, Arduino, A Tmega328p, Tachometer, ACS712, Android, HC06,
Bluetooth, Machine learning, Control, Stepper motor
Cite this Article: Karna Patel, Mrudang Patel and Nirav Oza, Wireless automation and Machine
Learning of a Rolling-Mill Using Arduino and Android. International Journal of Mechanical
Engineering and Technology, 7(6), 2016, pp. 09–21.
http://www.iaeme.com/ijmet/issues.asp?JType=IJMET&VType=7&IType=6
1. INTRODUCTION
The discussion in this paper is regarding the automatic control of a rolling mill used for manufacturing of
sheet metal in workshops. This is done with the help of an Arduino UNO in which the ATmega328p
microcontroller is used. With the help of Arduino analog inputs are taken from a few sensors and are
consecutively used to drive a stepper motor and send data to an android phone using the HC06 bluetooth
module. The Bluetooth enabled android phone will receive the data regarding torque produced by the
motor, power consumed by the motor, overloading alerts and thickness of the sheet after rolling at a
particular instant of time. Moreover the sheet thickness can be also controlled by the Bluetooth enabled
android phone with the use of a stepper motor. The input data and calculated data are further used for
overloading or failure prediction and process optimization. This data is also saved inform of csv file which
can be opened in Microsoft excel for data analysis and plotting graphs.
Karna Patel, Mrudang Patel and Nirav Oza
http://www.iaeme.com/IJMET/index.asp 10 [email protected]
2. DEVELOPMENT
2.1. Working of the Automated System
The system is developed in such a way that it can be installed on any rolling mill using a motor running at
230V AC or 440V AC 3-phase. The system consists of a tachometer that gives the rpm at which the motor
is running at that instant. The tachometer is installed on the shaft of any of the two rollers. The actual rpm
of the motor is calculated by considering the gear ratio. Another sensor used in the system is the Hall
Effect sensor (ACS712). This sensor is used to measure the current that is drawn by the motor at that
instant. These sensor values are given to the Arduino in form of analog inputs. Now having the power
consumed by the motor and the rpm of the motor, the torque produced by the motor can be calculated.
Further tangential force acting on the rollers can be calculated from the previous derived data. This data
now can be sent to a Bluetooth enabled android phone by using a Bluetooth module. Once these values are
received by the phone they can be displayed on the screen by using a simple application built in the MIT
App Inventor 2. This app accommodates the serial data connection between the phone and the Bluetooth
module (HC06).Another feature in the android app enables the user to send the information regarding
required thickness. This information is processed by the Arduino UNO and the system automatically
operated the stepper motor that controls the distance between the two rolls into action to achieve the
required thickness of the metal sheet. Further a potentiometer is used to sense the thickness of the rolled
sheet. The potentiometer is attached to a link which has a small ball at the other end. As the thickness of
the of the rolled sheet changes the angle of the link changes in turn rotating the potentiometer. Thus an
analog input is passed onto the Arduino UNO which compares this value to the required value and
consecutively operates the motor. Thus we obtain a continuous quality check and quality assurance by this
automated system. This system also predicts the torque required for obtaining a particular thickness of the
sheet. Thus it knows at what point the system will be overloaded is likely to fail in advance and can notify
the user. Also an important feature about the system is that it remembers the data from past experience and
uses it for predictions and optimizations. Moreover it creates a data log of the input data and calculated
data into a file and writes it to micro SD card. This file can be opened in Microsoft Excel for data analysis
and plotting graphs. It also helps in keeping a record for activity.
2.2. Miniaturization of the Circuit
The circuit used in the system can be reduced to a smaller size. For example, the Arduino UNO
prototyping board can be eliminated by using just the microcontroller (ATmega328p) and 16MHz
oscillator and adding few components. This helps in cutting down the project cost and occupies less space.
Figure 1 AT mega – Arduino UNO equivalence table
Wireless automation and Machine Learning of a Rolling-Mill Using Arduino and Android
http://www.iaeme.com/IJMET/index.asp 11 [email protected]
3. SYSTEM COMPONENTS
A number of sensors and other components are used in the system. These are selected according to a
particular application. Given below is the information regarding the components and their operating
condition. These conditions are used to cut the circuit and notifying the user in case of overloading of any
component.
4. ARDUINO UNO
The Arduino Uno is a microcontroller board based on the ATmega328 (datasheet). It has 14 digital
input/output pins (of which 6 can be used as PWM outputs), 6 analog inputs, a 16 MHz ceramic resonator,
a USB connection, a power jack, an ICSP header, and a reset button. Given below are more technical
details regarding the Arduino UNO;
Figure 2 Arduino UNO
Microcontroller: ATmega328
Operating Voltage: 5V
Input Voltage: 7-12V
Input Voltage (limits): 6-20V
Digital I/O Pins: 14
Analog Input Pins: 6
DC Current per I/O Pin: 40 mA
DC Current for 3.3V Pin: 50 mA
Flash Memory: 32 KB (ATmega328)
SRAM: 2 KB (ATmega328)
EEPROM: 1 KB (ATmega328)
Clock Speed: 16 MHz
Length: 68.6 mm
Width: 53.4 mm
Weight: 25 g
Karna Patel, Mrudang Patel and Nirav Oza
http://www.iaeme.com/IJMET/index.asp 12 [email protected]
4.1. Bluetooth Module HC-06
This module permits any microcontroller with a standard RS232 serial port to communicate with a PC or a
Smartphone equipped with a Bluetooth Master module. It has been used to communicate between the
Arduino UNO and Bluetooth enabled smartphone. Its major specifications are;
Bluetooth number: JY-MCU-HC-06
Default baud rate: 9600 bps.
Default pin: 1234.
Class: 2, with up to 10 meter coverage.
Chipset: CSR
Bluetooth: V2.0
Working voltage: 3.3V
Current: pairing 20~30mA, connected 8mA
Dimensions: 2.7 cm x 1.3 cm x 0.1 cm
Weight: 0.18 oz (5 g)
4.2. AC to DC Conversion Circuit
A potential transformer will step-down the power supply voltage from (0-230V) to (0-24) level. Now the
secondary of potential transformer will be connected to a precision rectifier, which is constructed with the
help of op-amp. The advantage of using this rectifier is that it will give peak voltage output as DC. Now
this 24V DC is given to the 7812 regulator to get the 12V DC output. Not this is given to the 7805
regulator to get the required 5V DC. The 24V DC that is obtained from rectifier is used to run the stepper
motor.
4.3. Hall Effect Sensor (ACS712)
The device consists of a precise, low-offset, linear Hall sensor circuit with a copper conduction path
located near the surface of the die. Applied current flowing through this copper conduction path generates
a magnetic field which is sensed by the integrated Hall IC and converted into a proportional voltage.
Device accuracy is optimized through the close proximity of the magnetic signal to the Hall transducer. A
precise, proportional voltage is provided by the low-offset, chopper-stabilized BiCMOS Hall IC, which is
programmed for accuracy after packaging.
Figure 3 ACS712 general application schematic
Wireless automation and Machine Learning of a Rolling-Mill Using Arduino and Android
http://www.iaeme.com/IJMET/index.asp 13 [email protected]
Above is shown a typical application of the ACS712 sensor. As seen the pin 7 gives out a voltage
which acts as an analog input for the Arduino which is then converted to read current value at that instant.
This value helps in calculating power consumption and ultimately torque produced by the motor.
4.4. Potentiometer
A potentiometer is a sensor for measuring the potential (voltage) in a circuit. In this arrangement, a fraction
of a known voltage from a resistive slide wire is compared with an unknown voltage. The sliding contact
or wiper of the potentiometer is adjusted and the galvanometer briefly connected between the sliding
contact and the unknown voltage. Here a 10K ohm potentiometer is used. It is used as a sensor for
measuring the thickness of the rolled sheet. An analog input is provided to Arduino UNO by
potentiometer.
4.5. Stepper Motor
A geared motor is required for controlling the distance between the roller axes. A stepper motor is used for
the operation because it exhibits highest torque at a step position. Thus it can provide enough torque to
oppose the force on rollers even if it is not rotating. Practically it helps in locking the position once
obtained. NEMA 34 has been used in this case.
Step Angle: 1.8 Degree
Configuration: 4 wire bipolar stepper motor
Holding Torque: 85kgcm bipolar mode
Phase current: 5Amp
Resistance/phase: 0.76ohm
Inductance/Phase: 8.5mH
Rotor inertia: 2700 gcm2
Length (L): 118mm
Shaft Dia: 12.70mm
Shaft Length: 32mm
Weight: 3800 grams
This particular stepper motor is selected for light or medium loads. For greater loads, higher holding
torque is needed. The stepper motor helps to obtain very fine displacement considering the gear ratio
which results if more accurate outputs. It runs on 24V DC which can be obtained directly from the output
of precision rectifier used in the AC to DC conversion circuit.
4.6. Tachometer
Tachometers are used for measuring the RPM of the motor at any instant. This device can be replaced by
encoders. Two pin encoders are available at very low cost. But these are not reliable at higher RPM.
Another replacement for tachometers can be tiny motors. Motor that would produce a maximum of 5V DC
on rotating can be used to directly get the analog data. Any motor for which RPM vs. Voltage curve is well
known can be attached to the rotating rollers. Due to rotations, a voltage value will be obtained across the
motor. For this value, on comparing with the RPM vs. Voltage curve, we get the value of RPM.
4.7. Stepper Motor Driver
RMCS-1102 is used in this case. The description of the motor driver is as follows. It is a Rhino Motion
Controls DSP based micro-stepping drive for 1.8deg Bipolar Stepper Motors. It has short-circuit protection
for the motor outputs, over-voltage and under-voltage protection. The RMCS-1102 achieves micro-
stepping using a synchronous PWM output drive and high precision current feedback and this is absolutely
silent when the motor is stopped or turning slowly. It virtually eliminates stopped-motor heating regardless
Karna Patel, Mrudang Patel and Nirav Oza
http://www.iaeme.com/IJMET/index.asp 14 [email protected]
of power supply voltage using a DSP based PID current control loop. Its closed-loop control gains are
calibrated on start-up based on motor characteristics and also adjusted dynamically while the motor is in
motion. The PULSE/STEP, DIRECTION inputs are optically isolated. Both inputs work with 2.5V, 3.3V
or 5V logic drive signals. The input drive current is 5mA at 2.5V so almost all logic family (74LS, 74HC,
etc.) can be used to drive these inputs. Each input provides individual anode and cathode connections to
the opto-isolator allowing for multiple input drive interfaces.
4.8. SD Data Logger
Once the required thickness is obtained, the input data and calculated data is saved in micro SD card. Thus
a database giving information about required torque for different materials and thickness is obtained. The
file is saved to the micro SD card with the help of SD card module with which writing data in a file
becomes very easy. The data is saved in a file named datalog.csv. CSV format is used so that it can be
opened in Microsoft Excel and data analysis or graph generation can be carried out. This function of data
logging is carried out by the Arduino UNO.
Figure 4 SD data logger connection
5. SOFTWARES USED
Software is needed for writing a code to the microcontroller or in this case an Arduino UNO. Also
software is used for designing and developing an Android application.
5.1. Arduino IDE
Arduino IDE is used for writing a code, compiling it and uploading it to a microcontroller which in this
case is ATmega328p. The code is written in Arduino language and is uploaded to the microcontroller via
serial communication USB data cable.
Wireless automation and Machine Learning of a Rolling-Mill Using Arduino and Android
http://www.iaeme.com/IJMET/index.asp 15 [email protected]
Figure 5 Arduino IDE
5.2. MIT App Inventor 2
MIT App Inventor 2 is online software for developing basic Android applications easily. It is used to create
the layout, design and establish interconnectivity and communication ports. It helps to display the data
received and provides a platform for sending and receiving information wirelessly.
Figure 6 MIT App Inventor 2
6. INTERFACE
6.1. Android App
An android app helps in connecting the Bluetooth enabled android phone to the Bluetooth module (HC-
06). This app initializes serial data communication with the selected Bluetooth module. Thus the
information can be exchanged to the Arduino UNO. Here values of the torque, power consumption and
other alerts are sent to the android phone by the Arduino UNO. While required thickness of the rolled sheet
is given to the Arduino UNO by the android phone i.e. by the user. Such a simple app is designed in the
MIT App Inventor 2 where the received data can be displayed and data can be sent to the Arduino UNO.
Karna Patel, Mrudang Patel and Nirav Oza
http://www.iaeme.com/IJMET/index.asp 16 [email protected]
The Figure 7 below displays the same where the values received from the rolling mill can be seen in real
time.
Figure 7 Android application interface
7. ALGORITHMS
7.1. Microcontroller
• Take inputs from the Hall Effect Sensor (ACS712), tachometer and the potentiometer every 1000ms.
• Calculate the torque delivered by the motor.
• Store the last 10 torque values in different variables (x1, x2, x3…x10).
• Use mathematical functions to generate a linear function from the 10 different values of torque obtained
against 10 different values of the potentiometer.
• Check if a serial communication is established via Bluetooth module (HC-06).
• Send the values of torque and power via Bluetooth serial communication.
• Get the initial thickness of the sheet prior to rolling and the material name.
• Get the required value of thickness via Bluetooth serial communication.
• Now use the generated linear function to predict the torque required for the operation.
• Check if no overloading occurs and control the stepper motor to obtain required thickness of the rolled sheet.
• Now make a data log in the SD card for the different values of torque required for different thickness of the
sheets of different materials in a file named datalog.csv.
7.2. Android Application
• Ask the user to select a Bluetooth module for connection from a given list.
• Connect to the selected Bluetooth module and start a serial data communication.
• Ask the user to enter the value of the required thickness of the rolled sheet, initial thickness of the sheet and
material name.
• If user selects “GET DATA”, receive the data from the Bluetooth module and print it on the display screen
of the Android phone.
The logic has also been developed in the Matlab Stateflow logic chart. This can be helpful for
developing logic graphically and can be directly deployed to the Arduino by using the Arduino library
provided by the Matlab itself. This logic chart can be seen in the Figure below.
Wireless automation and Machine Learning of a Rolling-Mill Using Arduino and Android
http://www.iaeme.com/IJMET/index.asp 17 [email protected]
Figure 8 Android application interface
8. MATHEMATICS USED
An integral function is used for obtaining a linear function from the 10 data sets of torque corresponding to
each potentiometer value or thickness. This helps in predicting the amount of toque required for obtaining
a particular thickness and can be used to add a safety feature which can avoid overloading.
Consider a linear function that we need to determine;
Y(x) = m*x
Here, Y = value of torque
x = value of potentiometer or sheet thickness
Now to find out the value of m generalized for all 10 data set, consider another function;
J(m) = � (�(��) − ��)�
�� = � ( ∗ ��) − ��)
�
��
Now on minimizing the value of above given function, the value of m is obtained. Thus the line
function is complete and predictions can be made for other values.
Basic curve fitting was done in the matlab as shown in Figure 9 and Figure 10. Figure 9 displays the
curve fitting done using the second order equation. Figure 10 displays the curve fitting done using simple
linear equation.
Table 1 Sample Data
Initial Final Diff Current
1.68 1.62 0.06 5.1
1.62 1.4 0.22 9.1
1.4 1.32 0.08 7.5
1.32 1.12 0.2 6.6
1.12 1.1 0.02 5.7
1.1 1.02 0.08 5.3
1.02 1 0.02 5.1
1 0.88 0.12 6.7
Karna Patel, Mrudang Patel and Nirav Oza
http://www.iaeme.com/IJMET/index.asp 18 [email protected]
0.88 0.7 0.18 10.4
0.7 0.62 0.08 7.7
0.62 0.6 0.02 5.4
0.6 0.56 0.04 5.3
0.56 0.52 0.04 5.3
0.52 0.4 0.12 9.8
0.4 0.32 0.08 12.2
Figure 9 Second Order Curve Fitting Figure 10 Linear Curve Fitting
8.1. EQUATIONS USED
Basic and general electrical and physics equations have been used to do the calculations and derive the
required quantities.
P = V * I
Here P is power consumed by motor
V is running voltage of motor
I is current drawn by motor
T = P / ω
Here P is power consumed by motor
T is torque produced by motor
ω is angular velocity of motor
T = F * r
Here T is torque produced by motor
F is tangential force on motor
r is radius of roller
These equations are used to calculate desired quantities and creating a data set that helps machine in
predictions.
Wireless automation and Machine Learning of a Rolling-Mill Using Arduino and Android
http://www.iaeme.com/IJMET/index.asp 19 [email protected]
9. MATLAB SIMULATION
Simulation for the control of the rolling mill has been performed in Matlab. Considering a closed loop
control system, the bode plots have been plotted after the simulation. Simulink model has been used for
this purpose. These plots help in understanding the characteristics of the system. Figure shows the plot for
the same.
Figure 11 Bode Plot for closed loop system
10. CIRCUIT DIAGRAM
Figure 12 Circuit diagram
11. BLOCK DIAGRAM
The Block diagram in Figure 11 shows the inter-relationship and the correlation between the various
componenets of the system. It also gives an overall idea about the connectivity and working of the system.
It includes physical as well as wireless connections.
Karna Patel, Mrudang Patel and Nirav Oza
http://www.iaeme.com/IJMET/index.asp 20 [email protected]
Figure 13 Block diagram of component structure
12. ADVANTAGES
• Low setup cost.
• No need of continuous human supervision.
• Notification for overloading is obtained beforehand.
• The system can warn overloading and stop further functioning to reduce chances of damage.
• Continuous monitoring and quality assurance is provided by the microcontroller itself.
• No human quality check is required once calibration of the potentiometer is done.
• No trial error methods needed to achieve desired thickness of sheet.
• Saving of analysis time as previous data is available for reference.
13. DISADVANTAGES
• The wireless control range is maximum 20 meters which restricts control to local.
• There is no inbuilt high level wireless data security for data security.
• Least Count for controlling thickness is 0.1 mm
14. CONCLUSION
Optimization of the process, Reduction in system failure and smarter machines can be developed using
microcontroller, data analysis and user interfaces. A smarter, efficient and precise rolling mill can be
developed using microcontroller and android communication.
REFERENCE
[1] Getting started with Arduino, Massimo Banzi, second edition.
[2] CNC Robotics, Geoff Williams, first edition.
[3] All new Electronics self teaching guide, Harry Kybett and Earl Boysen, third edition.
Wireless automation and Machine Learning of a Rolling-Mill Using Arduino and Android
http://www.iaeme.com/IJMET/index.asp 21 [email protected]
[4] An Accurate Detection for Dynamic Liquid Level, Based on MIMO Ultrasonic Transducer Array, Peng
Li, YuleiCai, Xiaolong Shen, Sharon Nabuzaale, Jie Yin, and Jiaqiang Li.
[5] The Power electronics handbook, Edited by Timothy L. Skvarenina, Purdue University,West Lafayette,
Indiana.
[6] Embedded Virtual Machines for Wiress Industrial Automation, Rahul Manghram, MiroslavPajic,
ShivkumarShastry.
[7] Industrial Wireless Sensor Networks: Applications, Protocols, and Standardsedited by V. Çağrı Güngör,
Gerhard P. Hancke.
[8] Michelе Brеncich and Stеnfano Rando “Rolling mill Automation Control systеm (RACS)”,
Automazioni Industriali Capitanio(AIC), 2008, pp 149-152.
[9] Maha M. Lashin , Design and Execution of a 3D Printer Using a PLA Filament as a New Application of
Arduino, International Journal of Mechanical Engineering and Technology (IJMET), 5(7), 2014, pp.
171–183.
[10] A text book of “Machine Design” by Khurmi and Gupta.
[11] Arduino Microcontroller Guide W. Durfee, University of Minnesota.
[12] Maha M. Lashin , A Different Applications Of Arduino. International Journal of Mechanical
Engineering and Technology (IJMET), 5(6), 2014, pp. 36–46.