Development of a System for Monitoring and Control a Resin Drying Oven using IoT

— This article presents the construction of a prototype of internet of things application to monitoring and remote control of a resin drying oven to electric restored engines, using the internet as the main means of data transfer and a free server, the complete system consists of a special board to get the temperature data from the drying oven, a liquid crystal display, a data viewing environment to provides the data access and the control from any device inside of local network and the central microcontroller ESP8266 with native Wireless Fidelity (Wi-Fi), firmware upgrades can be downloaded through Internet Protocol (IP) address without the need of traditional communication cables, the system was developed do get in the industry 4.0, applying a lightweight protocol, the internet to data transmission, and a low cost microcontroller


I. INTRODUCTION
Radio Frequency Identification (RFID) was the first technology created using the concepts of Internet of Things (IoT), it appeared in 1940 and was soon applied to the transponders of second World War (WWII) aircrafts [8]. The idea of connecting objects to a network and making them smart has triggered the development of various techniques and protocols for using smart sensors attached to microcontrolled systems. IoT brings the ability to remotely control and read data using lightweight communication protocols and low bandwidth demand.
Some of home appliances and electronics are controlled by embedded systems where has a main controller with a work routine described in a program, and recorded within their memory, however, to be able to connect to internet using the Wi-Fi network, the microchips should be adapted.
The programming difficulties of microcontrollers are directly linked to their manufacturing architecture and the types of peripherals available [1]. Technology developments have enhanced the functionality of programmable microchips, making them adaptable, opening a range of connectivity options including wireless networking.
Real-time monitoring and remote activation of a resin drying oven of induction motors is a simple example of IoT application with embedded circuits, as it is low cost and highly flexible, allow the deployment of two main features, intelligent communication, and data monitoring from anywhere in the world using common platforms such as mobile phones, tablets and computers.

II. THEORETICAL REFERENCE
The industrial evolution started in England around 1780 and was called as the first industrial revolution characterized as the beginning of the insertion of machines on industrial productions. It did not take much technology to start this process of revolution, and the inventions of that time were very modest [5]. Moreover, inventors were limited in both knowledge and resources. This beginning has triggered many changes in the working class and economy, starting the new professions where factories began to produce repeated patterns.
All other areas link to the transportation process of goods had to evolve to supply the demands of production mechanization, the need for raw materials for large manufacturing companies led to the growth of worker exploitation. This evolution extended until it reached several countries in Europe and others countries. The second industrial revolution presented several driving factors, such as electricity, media, and the means of transportation, and the need of specializations in various areas of knowledge. Between 1820 and 1850, for example, the British movement created some institutions for social education for the class working to meet the needs of the industry [5].
The third industrial revolution was characterized by the advance of electronics and computer systems, due to the development of knowledge in the areas of mechanics, computing and electrical. One of these areas was linked to industrial networks, which then emerged to standardize the forms of data traffic between devices from different manufacturers that formed an integrated and automated system.
Automation has developed with new technologies that have emerged and continue to emerge to assist industrial solutions, the industrial automation is not only to replace human labor, but also to brings production improvements, cost reduction and space optimization [9].
Since the emergence of programmable logic controllers (PLCs) in the 1960s, it has been used for the most diverse process controls, both in large industries and in small businesses. Thus, the graphic interfaces began to provide man a great control of machines and production processes through computers, nowadays the Human Machine Interfaces (HMIs) are almost indispensable in the industrial environment, in order to assist the system [9].
1.1 Embedded circuits Embedded circuits are microprocessed electronic systems which work from a routine described by a program burned inside its memory, have a specific function that most of the time cannot be changed [1]. These are present in people's daily lives, characterized as a small dedicated computer and can have a high level of complexity.
As there are several microcontroller manufacturers, their hardware differences differ significantly in applications and may influence the time to develop a project, and to reduce these impacts, several standardized platforms have emerged with greater ease of programming and broad adaptability [13].
Several microcontrollers today are classified as lowconsumption devices, which makes their application very cheap and affordable in various products, examples are toasters, ovens, electronic locks and alarm systems [8].
1.2 Industry 4.0 The Industry 4.0 is a new period in the process of industrial revolution, gathering the latest and most accessible technologies and applying in manufacturing systems, the result is an intelligent factory that is able to predict failures, and control their processes, via sensors or actuators inside of a data sharing network. Industry 4.0 is a concept that become possible through constantly developing technologies for computing and engineering, such as: IoT, Big Data and Cyber Security [12].
One result from all of this industrial evolution was the rapid development of related areas, such as electrical engineering, IT and industrial automation. The automation will directly reduce corporate staff in order to robotization process, but prepared professionals for new trends will be the key of the deployment of smart industries.
1.3 Internet of things The internet of things has become popular due to electronic systems evolution, the current internet will also become the means of connecting machines, which will assure the remote control and reading of devices. Since the popularization of the internet, around of twenty years ago, it was already thought to control things over the internet, so the concept of internet of things is not something new [8].
Wi-Fi networks are a differential for the use of this technology, without the large amount of wires, allowing the interconnection of devices in the same network. There are a few different ways to connect a device to the internet, and this is directly linked to the amount of data you want to transmit, the size of network coverage, and where the devices to be monitored are positioned [6].
Although human interaction in IoT systems is important, there are systems that can work autonomously using Machine to Machine (M2M) interactions, where machines exchange data with each other and make their own decisions [11].
The M2M aims to integrate physically and virtually objects of different types and manufacturers that are geographically distributed in a particular environment, they must communicate in harmony without requiring human intervention [3].

MQTT Protocol
The MQTT protocol is a data transmission standard designed exclusively to be lightweight and to work on networks with unstable connections. It uses the Machine to Machine (M2M) concept to connect smart devices to a network [4].
Despite the popularity of the MQTT protocol for IoT applications, it is also being used for other applications because it has security and guarantee of data transmission and is able to manage it correctly [4].

III. MATERIALS AND METHODS
The study adopted the descriptive research method based on theories contained in books and articles, with the purpose of applied research where knowledge and techniques can be effectively used in real life. It does not use statistical methods or techniques, but uses the researcher as the main instrument for data collection, maintaining direct contact with the environment and the object of study [10].
Automation in the production processes of Brazilian industries has grown rapidly, with new technologies the industrial processes tend to be faster and with less cost with human labor and the employment processes, the connectivity and ease of supervision of production lines offers greater control, however many industrial equipment is old and requires high investment for high technology adaptations.
It is of great importance the development of embedded systems able to interact with industrial environments without much physical changes, and transmitting for production control purposes, data, that does not expose industry secrets and that can self-diagnose against errors, that may directly affect the operation of equipment, this type of predictive fault detection in addition to extending machine life provides planned actions for replacements and repairs.

Study area
The IoT embedded circuit installation location was in a company of technical assistance and maintenance of motors and generators of low and medium voltage, small motors like submerged pumps and manufacture of electric cabinets, located in the city of Manaus in the Amazonas, the firm has team for emergency to solve problems in other cities, with major partners such as mining and hydroelectric.
This company has a drying oven which it uses to dry the WEG manufacturer's lackterm resin, used in motors for insulation and coating of coils. Electro insulating resins have great chemical resistance being applied in various electrical powers and temperatures, having thermal class H-180 ºC, used in motors, high and low voltage generator sets and all hermetic motor powers [14].
The resin drying oven must reach a temperature between 130 and 150 ºC for a time ranging from 6 to 8 hours, and the constant monitoring of temperature and the time is necessary to ensure quality in the services provided, but to see the temperature variable and the activation and deactivation of the heating resistors someone must be in the workplace to act.
Aiming comfort and quality in the resin drying process, a high level computational but low cost embedded circuit has been developed to remotely monitor and control via Wi-Fi. It can be displayed in real time on a user interface stored on a local server, drying oven temperature and can also be turned on and off at any time as long as it has connectivity to the Internet and on the same local network.
3.2 Chosen electronic components The NodeMCU Fig.1 manufactured by the Chinese company Espressif Systems was chosen to be the central microcontroller of the system, is versatile and low cost, having the advantage of Wi-Fi connectivity.
This chip can operate at processing speeds of 80 or 160 MHz, having 16 input or output pins, the wireless network is compatible with the 80.11 / b / g / n standard [2].
The NodeMCU module adds in one module the ESP8266 chip, with direct Universal Serial bus (USB) connection via converter, voltage regulator, resistors and capacitors, which will facilitate the prototyping of the control board. Some ESP8266 Pins can function as SPI, UART, I²C, I²S communication interfaces or ADC [2].

Fig.1: NodeMcu
To measure the temperature using a type K thermocouple, the module chosen was the MAX6675 Fig.2, which has the ability to convert an electrical reading ranging from 0 to 1024 °C, in a digital output with 12-bit resolution and is able to transmit the data through a Serial Peripheral Interface (SPI) communication [7].  /dx.doi.org/10.22161/ijaers.69.30  ISSN: 2349-6495(P) | 2456-1908(O) the ESP8266 has the Inter-Integrated Circuit (I²C) communication, using only 2 pins of the chip and can send data to LCD using PCF8574 integrated circuit as adapter.

Fig.3: LCD 2004 I2C
To control much larger digital outputs and switching elements, 12 Volts relays with the ULN2803 chip will be used as a driver to reduce the number of components and turn easier the routing of printed circuit board paths. The relays can be driven at low current, around 1.35mA using ULN2803 being able to drive loads greater than direct microcontroller actuation.
To develop the printed circuit board was used the Proteus Design Suite program developed by the company Labcenter Eletronics Ltda, and on this platform it was also possible to simulate parts of the electronic circuit and from there create the prototype of the board that holds all the components mentioned above Fig.4.  Fig.5, where you can identify the devices and the free MQTT server called broker. The device that sends data to broker is called publisher MQTT, while the device that receives data from server is called Subscriber MQTT [8].
For MQTT communication in which both clients must be connected to broker server, messages are filtered and oriented to their proper destination through a specific topic [11]. To get data published by a sensor on a "Drying/Temp" topic, the subscriber must to request the data using the same topic, each device connected to server must have its own identifying name to avoid conflicts.
The block diagram shows in a simplified way how the whole drying oven monitoring system is configured, where the arrows symbolize the communication and commands between the devices.

Test of sending and receiving data
CloudMQTT was the free broker chosen for the system because it has secure access to data and can be accessed via bidirectional communication (WebSockets), after creating a username and password on the cloudmqtt.com site, was created the system topics. Table 1 below summarizes the topics created for the system and their role in the process. In order to visualize and send the data in real time, a user interface Fig.7 was developed with direct connection to the broker server through WebSockets, thus, any device connected to the local network can access using a web browser requesting the page by the server static IP address 192.168.0.9, so there are two devices, where one of them store the monitoring page and the other device is attached to the printed circuit board, that is in the field with the monitored process.  Fig.7: User interface The temperature value is published by the motherboard through the local network and the Internet and is updated every second, the motherboard stays connected to the broker since power up and is able to reconnect if there is any access failure.
Another way to access broker data is to use the MQTT Dash App Fig.8 available on the play store for android phones. CONCLUSION The development of an embedded system to monitoring a drying oven with low cost, was a way to integrate old systems through the internet of things, according to the tests performed, the ESP8266 was efficient in data transmission over Wi-Fi network. This system was installed inside of an electrical cabinet aside of a real drying oven and the results were good and the main board is working with high robustness.
This kind of prototype can be used in several application, whether industrial environment or not, to monitoring or control any process, the ability of the ESP8266 to connect to the internet over the Wi-Fi network is a big advantage over other microcontrollers, in addition the firmware can be updated using the way over the air (OTA), that is a remotely way to transfer the firmware without traditional cables, and the prototype can be expanded according to the need of the process.