Keywords

1 Introduction

Internet of Things (IoT), a term coined by Ashton in 1998 [1], is a recent technology integrating communication technologies, software, and sensors. The IoT is considered one of the most critical technologies of the fourth industrial revolution in developing emerging technologies, impacting economic development, social transformation, and the industrial field globally [2]. For example, the McKinsey Global Institute published a report to determine the impact of the multiple technologies interconnected with the IoT and how they can create real economic value [3]. The McKinsey Global Institute’s report analyzed the application and impact of the IoT on 150 use cases, including devices (sensors and electronic systems) for monitoring people’s healthcare, the maintenance of industrial equipment, and workers’ occupational safety. The same report estimated that the IoT industry would have a total potential economic impact of $3.9 billion to $11.1 trillion annually by 2025. The IoT implementation can now be found in the factories (e.g., operations management and predictive maintenance), in public places (e.g., safety, health, traffic control, source management), in people (e.g., illnesses, welfare), in vehicles (e.g., maintenance based on the condition or use), in households (e.g., energy management, security), and in offices (e.g., time organization, job monitoring, training through augmented reality); that would be equivalent to around 11% of the world economy [3].

Therefore, the evolution of IoT has developed surprisingly in different fields, for example, the medical area in its various specialties and the medical technologies that support each one of the health services. The improvement in medical care and its management have been two significant challenges for decades. That is precisely where information technologies play an essential role in the challenges and opportunities associated with the supervision of the medical device’s function. In this way, the Internet of medical things (IoMT) is changing the current provision of healthcare services under the scheme of information exchange and unification of communication in a multidirectional way between clinical systems, network operations sensors or devices, and the analysis within a hospital network, which gives infinite possibilities for the emergence of new processes in an integral and intelligent way that allows smart decision-making [4].

The continuous search for new technological alternatives that allow efficient management of different medical technologies in a clinical setting [5] has raised many research problems to offer promising solutions in the hospital environment. As a result, this trend raises some concerns about the economic viability of traditional health systems and new proposals, which undoubtedly need to be redesigned, generating innovative solutions focused on providing quality healthcare and healthcare services.

There is no doubt that the Internet of Things is transforming the way health services are provided by redefining applications, devices, and the fact that the different health professionals connect and interact with each other, making it possible to deliver solutions to the problems of the health area [6]. Consequently, the evolution of IoT satisfies the existing services, generating new opportunities to make the services more efficient; however, it is vital to contemplate some aspects that need to be considered, such as security and privacy. Being a solution to the constant challenges that arise in the health area.

IoT applications are used for home healthcare services, mobile health, electronic health, or hospital management in terms of healthcare. Still, they are not used in medical devices or for detecting failures in these devices [7]. However, there are different examples in the industry where IoT applications are used for detecting failures in wind turbines [8] or for monitoring energy consumption in industrial equipment [9]. Applications of IoT devoted to variables related to performance and maintenance of medical equipment are still scarce [7].

The aim of this study is to present an IoT architecture that is focused on capturing and monitoring the environmental variables that influence the performance of a highly complex medical device (i.e., computerized tomography) located in a real-context, high-complexity hospital in Bogotá, Colombia.

This chapter is organized as follows: Section 2 provides an overview of the related works about IoT application in failure detection in the healthcare industry and other industries. Section 3 describes the proposed architecture of the system. In Sect. 4, the results are presented. Section 5 presents the discussion of the results obtained. Sections 6 and 7 show the conclusion and suggestions for future work, respectively.

2 Related Works

The incursion of IoT in the health sector has allowed acquiring a large amount of data to be analyzed in real time, making safe decisions about different cases and technology use situations. Interoperability in heterogeneous environments allows constant learning and generates a reference model that covers the diverse characteristics of both security and privacy and scalability and interoperability. It seeks to give an identity to “things” by interconnecting them and integrating them into the network, assigning them a central function in the so-called Internet of the future, and allowing them to exchange information without the need for human interaction [10, 11].

Several attempts at predicting failures or monitoring devices from different industries have been reported in the literature. Some authors have used machine learning techniques to detect non-biomedical devices’ failures [12], achieving positive results. However, the high consumption of hardware can be a drawback when these techniques are applied. Other smart algorithms have tried to predict medical device failures using predictive and corrective maintenance reports and the Monte Carlo estimation method [13], although this analysis was not performed in real time. On the other hand, conventional methods have been tried for predicting faults in medical devices using inductive techniques that allow the potential sources of failures to be determined and how these failures affect the performance of the equipment using the Failure Mode, Effects, and Criticality Analysis (FMECA) matrix [14]. In this way, it can be observed how industries are concerned about the state of their devices, as their non-supervision means damage and additional costs for their companies.

There are different examples of IoT applications for detecting failures. For example, Yamato et al. developed an IoT application based on lambda architecture to conduct predictive maintenance of industrial machines in Japanese factories [15]. Likewise, the IoT applications centered on monitoring relevant variables through sensor networks have been found in different industries. For example, IoT has been used in the performance monitoring of generators [16], turbines [17], power consumption in industrial equipment [9], transmission line in a smart grid system [18], and wind farms [8]. All the above-named applications have used machine learning techniques [19] to find failures or to make predictive maintenance in the industrial systems mentioned.

In healthcare, the literature shows that the main IoT applications are in-home healthcare services, mobile health, electronic health, and hospital management. Hospital management is based on preventing infections, educating patients, managing emergencies, and logistics systems [7]. However, to the best of our knowledge, there are no IoT applications for detecting medical devices’ failures.

Thus, the difference between this research and the related works is to develop an architecture that permits environmental variable acquisition in real time (vibrations, current, temperature, relative humidity) through sensors aimed to detect and predict failures in medical devices, specifically in a computerized axial tomography (CAT) equipment.

3 Proposed Work

This work was developed and implemented in a real-context, high-complexity hospital in Bogotá, Colombia. The variable determination and technical specifications of the sensor’s location were guided by the care personnel in charge of the service during the test development. Likewise, the hospital engineering team supervised the tests made up of biomedical engineers and diagnostic imaging technologists. In this way, it was possible to establish the location and variables to be measured according to the care personnel and hospital engineers’ criteria.

3.1 System Architecture and Variables Measured

In this study, the captured and monitored variables were temperature, humidity, vibration, sound, and current of the powered node the CAT was plugged into. According to the manufacturer’s recommendations in the manual and recommendations from the hospital’s biomedical engineering team, these variables were selected.

In this study, a three-layer architecture based on service-oriented architecture (SOA) was implemented. This architecture has been widely used in IoT applications in healthcare environments [19]. The architecture of the proposed system is shown in Fig. 1. In this figure, three layers can be identified:

Fig. 1
figure 1

The general architecture of the organized system in layers

3.1.1 Sensing Layer

The sensing layer is also known as the perception layer in the computerized axial tomography like the electronic boards, which are made up of sensors and communication boards that allow for processing measurements and sending environmental variables.

The sensing layer or perception layer is made up of a development and communication single-board called the SparkFun® ESP8266 Thing boardFootnote 1. This SparkFun® ESP8266 Thing has an integrated low power 32-bit CPU and could be used as an processor and Wi-Fi communication module. In our case, we had five sensors connected to a single-board measuring the environmental variables. To program this, this development board must use a USB programmer to serial or FTDI because it does not have one incorporated.

The references and more relevant characteristics are shown in Table 1. To measure temperature and humidity, a sensor DHT11 was used. This sensor allows temperatures between 0 and 50 °C and relative humidity (RH) between 20% and 90% to be measured. In the case of the current variable, a noninvasive current sensor SCT-013 was used; this sensor allows currents between 0 and 100 amperes to be measured. We was used the sensor KY-038 to measure noise level inside in the equipment; this sensor allows a minimal resolution to a noise of 58 Db to be measured. KY-038 has a frequency ranging between 100 and 10,000 Hz. To measure vibration variable, a sensor Minisense 100 was used; this sensor measures high sensitivity at low frequencies with a dynamic range in detecting vibrations or impacts. The sampling time of all sensors corresponds to the sending of the variables of the things to the intermediate device. This time is achieved with exactitude, thanks to the MQTT (MQ Telemetry Transport) protocol implemented in the machines.

Table 1 Description of ranges and sampling of sensors

In Fig. 2, the algorithm implemented in the ESP8266 can be detailed. It is presented in a flow diagram for a better understanding and can be replicated regardless of the programming language and programming environment with which the board is programmed.

Fig. 2
figure 2

Implemented algorithm flow diagram

In the case of the “GetSensor()” function, it does the reading of all the sensor variables, and later it is assigned the JSON (JavaScript Object Notation) format , which is currently a standard for the exchange and transfer of data over a network. The intermediate device analyzes this data block. After this, it is sent to the data display and storage services; therefore, a decoding process of the JSON format is carried out in these two services. An example of the JSON format sent from things to services is presented below.

{MAC: "5C:CF:7F:0B:98:D8", Temperature: 23, Humidity: 90, Sound: 100, Vibration: 5, Current:12}

With the MAC address, the origin and security of the data in the intermediate device and the services are validated, making it one more step to validate the safety of the system in its entirety.

3.1.2 Network Layer

In this layer are the communication protocols that things use to send information. For this case, the MQTT communication protocol was implemented in the sensing layer. Likewise, the protocols for communication and request of services hosted on the server were implemented. A standard protocol was used, HTTP (Hypertext Transfer Protocol) with an SSL (Secure Sockets Layer) security certificate for this purpose. Similarly, this layer supports wireless communications between the sensors and the broker and communications broker to the web service. The network characteristics of this study were as follows: Wi-Fi network, 2.4 GHz, with upload and download speeds of 20Mbps and 40 Mbps, respectively.

Figure 3 shows communication between things, the server and the dashboard. The things were composed of SparkFun ESP8266 and all the sensors, i.e., the DHT11, the current sensors SCT-013, the sound sensor KY-038, and the Minisense 100 sensor. In the things was programmed the data capturing and sending data to sub-routines to be handled by the server. 

Fig. 3
figure 3

Communication between things, server and dashboard

The node is composed of Eclipse Mosquitto™, installed as a broker on the Raspberry Pi3 board. Mosquitto was used as a server. It was selected because it is one of the most-used MQTT servers in the IoT industry, and it is Open Source [20]. The Raspberry Pi3 board is a reduced plate with the characteristics of a computer; it is also at a low cost for the excellent hardware and connectivity potential that it represents [21].

The MQTT protocol was used to coordinate the communication between the sensor and network layers [22]. MQTT is a standardized push protocol of publishing/subscribing. IBM launched that in 1999. In MQTT, the editor publishes messages about topics that could be considered the subject of the message. The subscribers, therefore, subscribe to the topics to get specific messages. Subject subscriptions can be expressed to restrict the data collected on a particular topic [23].

3.1.3 The Service Layer

This layer has two services hosted on the server: the first service is where the application dashboard is located and with which the user interacts with the system. It shows the visualization and graphical user interface and the data warehousing service delivered by the intermediate device using traditional data warehousing technologies such as relational databases.

The layer is composed of two elements. The first is the database, which stores the data received from the broker. In this application, a MySQL database was created and used in a web server hosted in Amazon Web Services to store the measured environmental variables. The web service designed for database management was developed using the PHP programming language and the protocol HTTPS.

An example of the code developed as a service for storing data in the relational database is presented below.

$enlace = mysqli_connect("Server", "user", "pass", "namedatabase"); if (!$enlace) { echo "Error: Could not connect to MySQL. " . PHP_EOL; echo " debugging error: " . mysqli_connect_errno() . PHP_EOL; echo " debugging error: " . mysqli_connect_error() . PHP_EOL; exit; } echo " Success: A proper connection to MySQL was made! The my_bd database is great. " . PHP_EOL; echo "Host info:" . mysqli_get_host_info($enlace) . PHP_EOL; $chipid = $_POST ['chipid']; $potencia = $_POST ['Potencia']; $irms= $_POST ['Irms']; mysqli_query($enlace,"INSERT INTO SensorCorriente(ID, chipid, dateHour, power, imrs) VALUES (NULL, '$chipid', CURRENT_TIMESTAMP , '$potencia', '$irms');"); mysqli_close($enlace);

Two storage layers were established: one is housed in the intermediate device, which, through an algorithm for detecting communication failures with the cloud, is activated by saving the records locally while the intermediate device is re-counted to the Internet. Once communication is established, it sends the records to the cloud, thus guaranteeing the traceability of the information registered on the platform.

For cloud storage, the MariaDB6 database manager was used together with an Apache server. This database manager was selected because it is one of the most popular and widely used database development environments for free software applications.

A relational database like MySQL was designed and developed to guarantee the safe storage of the implemented application information. Since it provides the basic methods and tools to ensure the data, it also controls and manages access permissions (users). It should be noted that the database is hosted on a server at the Universidad del Rosario, managed by the working group of the Internet of Things (IoT) subject.

Regarding the data, they were acquired with a sampling frequency of around 5 s and stored under the labels of temperature, humidity, sound, vibration, and current. Therefore, the structure of the message chain was determined with an identification number.

The second component is the dashboard or control panel. These objects are designed to show the measured environmental variables. The RESTful architecture-style services were used to develop web applications, which allows the use of standard methods of the Hypertext Transfer Protocol (HTTP) (e.g., GET, POST, DELETE, and UPDATE). The RESTful architecture provides data security and allows the representation of information in different formats. In this system, JavaScript Object Notation (JSON) was used with the Google chart API and Ajax to visualize the environmental variables measured in real time. Below is the code with which it is possible to graph the temperature and humidity in a chart-type graph using the Google API in real time.

<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1. 0"> <title>Document</title> </head> <body> <div id="monitor-chart"></div> <script src="https://www. gstatic. com/charts/loader. js"></script> <script> google. charts. load('current', { callback: function () { var chart = new google. visualization. LineChart(document. getElementById('monitor-chart')); var options = {'title' : 'Temperature and Humidity', animation: { duration: 1000, easing: 'out', startup: true }, hAxis: { title: 'Time' }, vAxis: { title: 'Temperature and Humidity' }, height: 400 }; var data = new google. visualization. DataTable(); data. addColumn('datetime', 'Time'); data. addColumn('number', 'Temperature'); data. addColumn('number', 'Humidity'); var formatDate = new google. visualization. DateFormat({pattern: 'hh:mm:ss'}); var formatNumber = new google. visualization. NumberFormat({pattern: '#,##0. 0'}); getTemp(); setInterval(getTemp, 5000); function getTemp() { var temperature = (Math. random() * (35 - 30) + 30); var humidity = (Math. random() * (40 - 15) + 15); var timestamp = new Date(); drawChart(timestamp, temperature, humidity); } function drawChart(timestamp, temperature, humidity) { data. addRow([timestamp, temperature, humidity]); formatDate. format(data, 0); formatNumber. format(data, 1); formatNumber. format(data, 2); chart. draw(data, options); } }, packages:['corechart'] }); </script> </body> </html>

To execute the code above, the code must be copied and pasted into a notepad and save with the .html extension, for example, “realtime.html” The result should be like the one presented in Fig. 4. with the code in the “getTemp()” function; random values are used for the code to work. However, in the case presented in this chapter, these functions are replaced by the values acquired through a service developed using the HTTPS protocol.

Fig. 4
figure 4

Communication between things server, and dashboard

The interface layer is a dynamic web user interface designed for and adapted to all mobile devices to show the captured data. This layer uses Markup languages such as HyperText Markup Language (HTML) and style languages such as Cascading Style Sheets (CSS). To manage these languages, the Google Materialize framework was used to allow clients to interact with the interface layer, as shown in Fig. 7.

4 Results

4.1 System Architecture and Variables Measured

Figures 5 and 6 show a general view of the imaging service where the CAT is located and the installation of the different sensors in the device gantry. The sensors were installed in these locations following the original equipment manufacturer and biomedical engineers’ recommendations from the hospital’s maintenance department.

Fig. 5
figure 5

Computerized axial tomography (CAT)

Fig. 6
figure 6

Installation of the sensors; (a) sound sensor, (b) temperature and humidity sensor, (c) vibration sensor

Figure 7 shows the electrical system of the hospital service, composed of three main power lines or phases, where energy is supplied to the isolation transformer, the intermediate system between the power supply of the equipment that serves as protection for the CAT. The current sensor was installed in one of the power lines, shown in Fig. 7.

Fig. 7
figure 7

Installing the current sensor

Finally, the developed graphical interface or visualization layer is shown in Fig. 8. In this case, the temperature and humidity variables are shown. In the web service, the monitoring of the other variables with which the user can interact due to the dynamic controls offered by Google chart can be found.

Fig. 8
figure 8

The interface between the humidity and temperature variables

Figure 8 shows an example of the interface components since all the measured have their chart-type graphics. The history of the last 20 data stored in the database is reported and continuously updated. This update is achieved with a method known as polling, which oversees always requesting an Internet service with which constant updates can be made in the graphics and data storage.

5 Discussion

The aim of this study was to design and implement a system with SOA and RESTful, which allows the continuous monitoring of environmental variables in medical equipment. The results show that it was possible to measure temperature, humidity, vibrations, sound, and current due to architecture. We could send information to the web service and see the variables on different platforms in real time. The SOA architecture has some disadvantages) for developing IoT applications, security being the main problem. Some authors claim that this architecture has some deficiencies in data security and access control [24]. This document presents an alternative by using the architecture style of the RESTful web application development. This architecture style has overgrown in popularity in recent years, especially regarding IoT applications [25]. Its principal features are facilitating the calling of application services through a URL, using the HTTP using standard verbs for safe navigation through the web, and being compatible with standard web data transmission formats such as JSON and XML.

To ensure privacy, in addition to using the Hypertext Transfer Protocol, the application also has an SSL (Secure Sockets Layer) certificate, which is a security protocol that transmits the IoT applications’ data to the service layer integrally and securely. Thus, data transmission between the brokers and web clients in a bidirectional manner is fully encrypted, which guarantees security and privacy in data transmission [26].

This system is interoperable, as it can adapt to any sensor device or control board with Internet connectivity, either via a Wi-Fi connection or Ethernet. In the same way, one of the advantages of the implemented architecture is that different types of communication can be implemented, such as Bluetooth, RFID, NFC, and technologies widely used in IoT [27] from the sensors’ control boards to the brokers. With the SOA architecture implementation, the platform allows this application to be implemented in different hospital services, thus allowing an easy and safe way of increasing the numbers of devices, sensors, and control boards, as well as creating several display boards for each area and complying with one of the main axes of IoT architecture, scalability [28].

Based on the above, IoT allows a new way of operating a “smart hospital” to improve health services; therefore, this new initiative is directly related to the growth in smart medical devices, their use, and accessibility health market. Essentially, the latest technologies are projected to be interconnected, allowing, on the one hand, the care personnel to monitor patients remotely, guaranteeing their health status, and the engineering staff to supervise the operation of different equipment with classic sensors under the wide range of IoT [29].

This study has the following limitations. Firstly, the system proposed does not perform online data analysis in real time since it is currently used to perform an exploratory data analysis. It is necessary to download and analyze them in a data analysis software such as R or Python. Secondly, the system was implemented using a WI-FI network, having limitations due to its coverage area. Although the system is easy to implement, having portable devices, and easy to move, this becomes a limitation to implement it in other hospital areas where the WI-FI network is not available.

The evidence in recognizing and exploring the imaging area was the fundamental reason for implementing the system to take environmental variables. The first one was that there is only one computerized axial tomography equipment in the institution, which has a reasonably high patient flow, so it is considered a critical service and needs technological alternatives to guarantee satisfactory operation times. The process was aligned with the protocols and requirements established by current regulations and according to the institution’s policies.

The infrastructure characteristics made it possible to determine the assembly and installation conditions of the CAT. When we analized the different record data, It was possible to determined the proper functioning of the equipment. It was identified that of the five variables, temperature and current fluctuation, better known as current peaks, significantly affect the stability of the equipment. Initially, the equipment’s temperature regulation is controlled with an air-conditioning system that regulates the room temperature where the equipment is located. However, it is not entirely reliable since, on several occasions, the wrong has been reported operation or lack of optimal refrigeration according to the work rate of the CAT, which sometimes works 24 hours in a row.

On the other hand, the current consumption of the CAT is relatively high, sometimes reaching 40–50 amps (adding its three phases), with peaks in the ranges of 30–62 amps. The above is due to the power system implemented in the institution for decades. Due to a lack of future planning, it is deficient in power and energy supply for imaging services.

In this sense, the developed system allows to know the behavior of each of the variables in real time and quickly make decisions that avoid damage or stoppage of equipment due to lack of supervision over it, since the technology that was built does not have a monitoring system. Thus, in this way, IoT technology would allow the optimization of resources and the promotion of predictive maintenance strategies that would lead to the saving of economic resources for the institution (corrective maintenance) and, on the other hand, to improve the provision of the services of health.

6 Conclusions

To conclude, the SOA architecture and RESTful architecture styles’ implementation allows the environmental variables of medical equipment to be monitored in real time. In this case, it was possible to implement a network of sensors for the continuous monitoring of a computerized axial tomography through a web platform using visualization and data storage services.

The implemented system showed satisfactory results concerning the information acquisition time window since it was possible to obtain a reliable and secure record of the variables under study. Although there was no equipment failure during the information capture period with the implemented system, it was possible to guarantee the traceability of the variables for later analysis and control purposes by the institution’s engineering group. The above will allow knowing the resonant behavior of the equipment and will provide solid tools to prevent possible equipment failure.

Therefore, different types of impacts could be covered according to the results obtained in this project. In the first place, the technological implications, derived from the interaction of the personnel of the biomedical engineering department and their concept about the functionality and benefits of implementing this type of technology in little-explored services, were recognized. A different kind of impact is reflected in the economic factor, given that the developed system can infer possible failures that would allow avoiding more significant damage to a medical team, in such a way that it is evidenced that different fully functional and practical technological alternatives could be generated that guarantee the operation of biomedical equipment or devices at a low cost, considering their development and functionality within the given hospital environment. Finally, there is the social sphere since it could increase safety and, incidentally, the quality in providing health services in front of users or patients who are intervened in a clinic or hospital services.

7 Future Work

The information acquired will be the basis for examining and advising health institutions in the near future about the importance of the precautionary measures needed to be taken by medical devices and how to predict abnormal functioning at any given time. Likewise, it is part of a new proposal by smart hospitals. Their interoperability allows new work and research scenarios that are the main objectives that this work contemplates in its initial stages by applying IoT architecture [30].

With current works, it was possible to have indications; then, different visualizations were made to analyze the potential relationships between the variables of temperature and current consumption as the main critical variables in the continuous operation of the CAT according to the behavior of the acquired data.

It was possible to identify the behavior of the data and the identification of the integrity and reliability of each of the tests, thus determining the average values of operation and anticipating whether the solution has a real value or not. In this way, it was identified if the captured values could be good deterioration indicators or malfunctioning of the equipment, allowing foreseeing failures.