Internet of Things-Based Fire Alarm Navigation System: A Fire-Rescue Department Perspective

Department of Information Technology, University of Sialkot, Sialkot 51040, Pakistan Department of Information and Electrical Engineering and Applied Mathematics, University of Salerno, Fisciano, Italy Department of Computer Science, Capital University of Science and Technology, Islamabad, Pakistan School of Digital Science, Universiti Brunei Darussalam, Jalan Tungku Link, Gadong BE1410, Brunei Darussalam Department of Information and Communication Technology, University of Agder (UiA), N-4898 Grimstad, Norway Department of Information Technology, Khana-e-Noor University, Pol-e-Mahmood Khan, Shashdarak 1001, Kabul, Afghanistan


Introduction
ere are situations where people's lives and livelihoods are disrupted by natural factors, non-natural factors, or human factors that cause deaths, environmental damage, property losses, and psychological impacts [1]. Every re process always produces smoke and heat, and the temperature will rise when there is a re [2]. rough combustion, ammable materials chemically react with oxygen to cause res. A re will be more likely to ignite with a high oxygen concentration. Historically, re disasters have been most prevalent in densely populated areas [3]. From January to September tackle this problem. In the following system, the communication is established using the GSM module; Arduino UNO acts as a microcontroller where the coding needs to be uploaded [5]. A SIM card is needed to operate this GSM module [6]. e fire station will receive notifications about the fire.
Furthermore, flame sensors detect fire in a specific spectrum between 760 nm and 100 nm. Among fire's major characteristics is its exponential growth [7]. It is, therefore, critical to detect fires when they are still small to prevent major accidents. It is obvious, therefore, how important it is to have a sophisticated fire alarm and monitoring system. It is possible to detect fire early by monitoring the increase in temperature, smoke, and flame [8].
Consequently, appropriate sensors must be installed at vulnerable places to monitor the physical quantities. Comparison of these values with predefined thresholds generates alarm information sent to a central processor, such as a microcontroller. Additionally, the first part of this paper deals with developing and testing an IoT-based fire alarm navigation system and application. e second part evaluates the response time of a fire incident by fire head stations in Punjab, Pakistan, not using IOT [9,10]. A survey through a questionnaire was conducted at the factory named "Sheikh of Sialkot" (Sialkot Pakistan) and assessed the data as to what the factory workers and firefighters think about the installation and functioning of an "IOT-based fire alarm navigation system." Lastly, we demonstrate a real-time fire alarm navigation system using IOT technology in a multinational sports goods factory in Sialkot and compare the results with current fire rescue data from Punjab. In this paper, we developed and reviewed the real-time testing on the "IOT-based fire alarm navigation system" with the collaboration of "Rescue 1122 Sialkot, Pakistan" [11]. A survey is conducted through a questionnaire in "Sheikh of Sialkot." We installed the system in the same production unit and compared the results with manual fire alerts.

Problem Statement.
Knowing that fire detection and alarm systems warn about fire outbreaks and allow action to be taken before conditions become out of control, they serve a very important purpose [12]. All systems are designed to protect lives and property, so it is the designers' responsibility to understand all the possible aspects of fire risk and fire [13]. Every fire alarm system must be designed for each building according to its specifications [14]. Our goal will be to develop a system that facilitates and enables firefighters to perform faster than ever. is system is used to notify the fire station of where the fire is in the building. e system has never been used in Pakistan till now [7]. is system can also be used in emergencies to reduce the time taken, such as fire incidents, and may reduce injury or mortality rates among fire victims. e system has been named "IOT-based fire alarm navigation system." Figures 1-3 portray an overview of response time by the firefighting teams in Punjab, Pakistan, regarding fire incidents from 2011 to 2021 [4].

Our Contributions
(1) We developed and reviewed the Pakistan fire rescue department's internet of things-based fire alarm navigation system in Pakistan. e implemented Arduino code mobile application apk file and related files have been publicly available (https://github. com/ibtisam-111/IOT-based-Fire-alarm-Navigation-System-and-Application, accessed on 27 June 2022).
(2) Apart from the previous system, a full-fledged mobile application is developed for real-time monitoring of the system and fire alert. (3) A brief survey is conducted in multinational garment production company "Sheikh of Sialkot" regarding traditional and internet of things-based fire alarm navigation systems. (4) A comparison of response time between the traditional fire alarm system and the internet of thingsbased fire alarm navigation system is presented.

Literature Review
ere have been several researchers who have presented their solutions. Here are some highlights. Many studies have been conducted on systems for delivering fire information, including those that use microcontrollers and mobile phones to deliver the information. As part of this system, MQ-2 smoke sensors are used, UVTRON fire sensors are used, a mobile phone represents a sender of information, and an ATmega32 microcontroller represents a controller. SMS is used to notify users of fires using the SIM900, MQ-2 smoke sensors, and the LM35 temperature sensor. e system can warn the homeowner if a fire occurs outside of the house. Arduino UNO is used to control all the components [15]. Temperature and smoke sensors used in this detector help detect fires early. System components consist of temperature sensors, smoke sensors, 0809 digital-to-analog converters, system controllers with AT89S52 microcontrollers, and an alarm system as an indicator of fire. Upon detecting fires using temperature and smoke sensor information, this prototype fire detection system activated an alarm as soon as the indicator sounded [16].
In reference [17], researchers developed a system for accident notification. In addition to the temperature e-sensor (LM35), the microcontroller and GSM components were used. Sensors record an accident, and afterward, through GSM, it sends SMS to the police about the event's location.
Several hardware components (sensors (shock sensors), microcontroller, GSM, LCD, buzzer, and microprocessor) are used in the following system. If a signal is received from the sensor, the receiver will send an SMS message to the family member of the driver. is SMS message will also display on an LCD [18]. e paper [18] aims to design a home monitoring and security system. In addition to the sensors, there is a microcontroller, relay, LM35, a magnetic sensor, a passive infrared sensor (PIR), and a cell phone. An SMS alarm message will be sent to the homeowner whenever any sensor is triggered.
Gas leakage detection is described in [19] for home use. e microcontroller, GSM, and liquid petroleum gas (LPG) sensors display gas values on an LCD. is microcontroller  Mobile Information Systems sends an alert whenever a gas leak is detected. A warning message is displayed on the LCD, and a modifying SMS is sent to the user for information. e authors of [20] proposed an easy way to monitor changes in weather anywhere. e hardware equipment includes sensors and a Bluetooth microcontroller unit. To read the data sensors and send it via Bluetooth to the Arduino, an Android phone is connected to a DHT 11 and wind speed sensors. Nonetheless, all these systems send messages reading "fire alert" and the sound of an alarm only in the form of a short message service (SMS), along with information about the location of the fire.
Fire departments often arrive late at fire locations, which is a problem so far [6]. Two reasons can account for this. One is a lack of preparedness among staff. Second, information was delayed in arriving from residents (1122 in Pakistan) [4], who experienced or were near the disaster, and heavy traffic was experienced at the location of the fire. It is expected that fires can be detected as early as possible by the smoke, temperature, and fire detection system; and the local fire department can be automatically notified. In the event of an unwanted fire, this step is the first step toward human safety. Table 1 portrays a quick display of existing systems.

IoT Technology in Fire Alarm Systems
An internet of things network is a system that gathers, transfers, and stores data using programmable software, sensors, electronics, and communication facilities. e system is designed to notify and alert a remote fire station and user/owner when a fire accident occurs [23]. In recent years, the internet of things (IoT) has been applied in various fields, including smart agriculture, smart healthcare, and smart homes [3,6]. Several advantages of IoT can be found in home automation, including remote operation and maintenance, and autonomous interconnection of appliances [31]. By communicating between devices and being aware of information exchange, the IoT system reduces engineering costs for simultaneously handling all devices. As a result of people's preference to save money instead of investing in effective fire alarm systems, fires spread quickly nowadays [32]. In addition to affordability, effectiveness, and response, some issues still need to be addressed. Due to the difficulties outlined above, this research aims to develop a system that can detect heat and smoke using a fire alarm system by utilizing IoT technology that makes it more reliable and effective [33]. With the IoT, the system reads the data of heat and flame and analyzes it, and then immediately sends a call to the fire station through GSM and informs about its location. us, this research focuses on developing an affordable, responsive, and effective, low-cost fire detection system [11]. Studies have addressed fire detection, but the accuracy of these systems is not adequate because the algorithms are trained by photographs, which means more photographs are needed to train them. Slow response times and low accuracy are drawbacks of other approaches [34]. is article introduces a new IoT method instead of relying primarily on Node-RED, reducing false alarms and providing faster response times. In addition to improving device efficiency, the internet of things can also produce financial benefits [10]. Due to its low cost and ease of development, it has recently been used in various applications. Hence, a fire detection system with the internet of things capabilities is essential to protecting homeowners' production units, stores, and other property, as it identifies early fires [24].

Arduino Microcontroller
ere are several standard Arduino boards, including the Arduino UNO. Label Arduino software's first release was named UNO [35]. Additionally, it was the first Arduino board to include a USB connector and to be programmable. Several projects utilize this powerful board. Arduino developed a board called Arduino UNO.cc. ATmega328P is the microcontroller that is used in Arduino UNO. Like the Arduino mega board, it is simple to use. Circuits and shields, and analog and digital input/output pins (I/O) are assembled on the board. In addition to six analog pins and 14 digital pins, the Arduino UNO has a USB connector, an ICSP head (in-circuit serial programming) header, and an ICSP connector. IDE is an acronym for the integrated development environment, the programming language used to develop the application. Various platforms can be used to run it, including online and offline [31,35].
All Arduino boards come with the same IDE. Arduino UNO consists of the following components: ATmega328 microcontroller: the Atmel family of microcontrollers consists of single chips. Embedded in it is an 8-bit processor. Some of its features are an analog-to-digital converter on the external side, SPI serial ports, I/O lines, registers, timers, interrupts, and oscillators on the inner side [9]. Analog pins: analog pins' numbers A0 to A5 are located on the main board. e analog pins in the connector are used to read analog sensors. In addition to being an input and output pin, it can also be considered a GPIO device. ICSP pin: programming the Arduino board using the firmware can be performed through the in-circuit serial programming pin [36]. Vin: it refers to the voltage at the input. GND: zero voltage is applied to the ground pin. Power LED indicator: power is activated when the LED indicates ON. LEDs do not light up when the power is off.  [37]. AREF: an external power supply powers Arduino UNO through the analog reference (AREF) pin. TX and RX LED's: light from these LEDs represents a successful data flow.

Methodology
We collected data through observation, field research, and literature review. Hardware and software components are needed to develop fire alarm navigation systems [23]. e main components are Arduino UNO, temperature sensor, smoke sensor, and other hardware parts such as GPS module, GSM module, and buzzer. C# programming language is used to program algorithms [38]. Tests are conducted on the design results, and then, data retrieval and research variables are sent via SMS, such as testing smoke sensors and the fire point longitude and latitude. Figure 4 displays the research methodology to develop this system.

Working Mechanism
An Arduino UNO microcontroller controls the IoT-based fire alarm navigation [39]. Fire detection is based on microcontroller program application detection of temperatures fluctuating under fire characteristics [40]. Detection of temperature increases caused by fire is possible by using an Arduino UNO microcontroller. Moreover, the system can also detect smoke produced by fires [41]. If the temperature exceeds 35 degrees Celsius, the system will activate the temperature DHT 11 sensor and the smoke MQ2 sensor, which detect smoke over 50 ppm due to a fire, as input. Upon hearing a buzzer, the Global Positioning System (GPS) will send a text message to the GSM module of the fire head station informing it of its location. Figure 5 displays a flow diagram of the system [29]. Table 2 portrays the system's hardware requirements, and Figure 6 displays the hardware components used for this system.

Microcontroller Comparison
A short comparison of various microcontrollers is presented in Table 3.
e block diagram in Figure 7 displays the connection of the overall components with Arduino.

Arduino IDE.
During the transmitting process, Arduino IDE C# programming is used to connect the board with a PC using a serial port such as COM1 or COM2 [35]. Regardless of your model, you can upload new code to the ATmega328 chip on the Arduino UNO without a hardware programmer. e chip uses the STK500 protocol for communication [46].

C# Language.
e system's interface is designed using the C# programming language in the central part of the program [28]. A SQL database stores information regarding the message content, the geographic location of the fire station, coordinates, and phone number.

System Circuit.
In the event of a fire, high temperature, or smoke being detected by the sensor, it requests the GPS module by first receiving coordinates of the location where it is located, and then routing it through the Arduino. Afterward, the fire alert message and the corresponding coordinates are sent to the fire station [3]. A real-time simulation of the whole circuit on Proteus software is presented in Figure 8.
Initially, all the sensors are tested, and the pins are connected to the pins of the Arduino as portrayed in Table 4. Figure 9 portrays the hardware assembly of the system.

Testing
e screen shorts shown in Figure 10 illustrate the results obtained when the navigation system was tested on a matchbox fire. e GPS data are generated with latitude 74.5141°E and longitude 32.4658°with fire detection. Fire detectors produce a buzzer and send SMS alerts informing of the location of the detected fire in the form of a "fire alert" message and GPS coordinates. Figures 10 and 11 show message received, fetched by mobile application for realtime monitoring, and alert purpose. Figure 12 shows the exact location of the fire incident with location coordinates. Table 5 portrays a brief comparative analysis of our work with the existing systems in terms of effectiveness, features, and modules.
is section discusses and explains the post-test and pretest results of this system.
is IoT-based fire alarm provides the fire station with the fire incident's location. is section will conclude with production workers (in which the system is installed and tested) and firefighters for the evaluation by providing a suitable questionnaire to help complete the testing.

Survey Questionnaire
Question 1: What is your gender? e histogram in Figure 13 shows a total of 25 individuals participating in this survey; 20 of them are men, and 5 are women.
Question 2: What is your age? Figure 14 shows that among 25 individuals, five are between 20 and 25 years old, 5 are between 26 and 30 years old, and the rest are between 31 and 35 years old. Question 4: Do you ever heard about a fire alarm system? Figure 16 shows that all survey participants heard about the fire alarm system.       Mobile Information Systems Question 5: Do you ever heard about a fire alarm navigation system? e histogram in Figure 17 shows that 15 of the survey participants have previously heard about the fire alarm system, and the rest are unaware of this system. Q6: Do you prefer to install this system in your house for safety purposes? Figure 18 portrays that all the survey participants agreed with the statement.

Mobile Information Systems
Question 8: Do you think nearby residents are slow to react when a fire happens? Figure 19 shows that 17 survey participants agreed to answer a yes against this statement, and the other 8 denied this statement.
Question 9: Do you face any problems when calling the fire station? Figure 20 displays that 17 survey participants agreed and answered a yes against this statement, and the other 8 denied this statement.
Question 10: Do you agree that firefighters arrived late at the fire incident location and hence caused casualties?     Question 12: Do you think it is a better system for your factory than a traditional fire alarm system? Figure 22 displays that 21 survey participants agreed and answered a yes against this statement, and the other 4 denied this statement.

Findings and Discussion of the Survey
Based on the questionnaire, people agreed that this device would help the communities. Some of them believe that this device might be able to reduce causalities and fatalities due to the fire incident. Next, this device will ease firefighters to locate the fire incident because they will arrive faster and be able to put out the fire before it spreads.

Real-Time Testing and Results of the System
We installed the system at the same sports production unit named "Sheikh of Sialkot" Sialkot, Pakistan, for testing purposes.

System in Normal Condition
(i) Total numbers of sensors � 3 (ii) Smoke sensor initial value: 98 ppm (iii) Flame sensor: 60 nm (iv) Temperature: 20 degrees Celsius e fire produced with the matchbox triggered the "IOTbased fire alarm navigation system."

Response Time by Rescue Fire Team
(i) Incident time � 12 : 45 pm (ii) Arrival of fire rescue team � 12 : 52 pm (iii) e average speed of a fire vehicle in traffic � is 35 kmph (iv) e average speed of a fire vehicle without traffic � is 50 km (v) Distance of fire spot to fire rescue station � is 3.5 km Total response time � 6 minutes, 10 seconds. According to fire rescue station data, another incident was recorded two weeks ago with the same distance [4].
(i) ey receive a manual call when fire covers almost half of the building (ii) Due to being congested and populated, they could not find a feasible route to the incident spot

Response Time by Rescue Fire Team (Manually Call Without Location Coordinates)
(i) Call received by fire station � 7 : 02 am (ii) Arrival of fire rescue team � 7 : 45 am (iii) e average speed of fire vehicles in traffic: 35 kmph (iv) e average speed of fire vehicles without traffic: 50 kmph (v) Distance of fire spot to fire rescue station � 3.5 km Total response time � 43 minutes. Figure 23 shows that line AB shows the response of firefighters with a manual call of almost 43 minutes, and line AC shows the response time of firefighters with a call generated by an "IoT-based fire alarm navigation system." Results clearly show that the fire alarm navigation system efficiently and effectively works, reducing the loss of human lives and properties. [48][49][50][51][52].

Conclusions
Our primary goal with this system is to reduce the numerous losses in human life and economic losses. With the help of sensors integrated into the microcontroller, GSM, and GPS modules, it can identify fires. A message is sent via SMS if a problem is detected. A message sent to the fire head station for quick response at the incident location can be viewed on Google Maps along with the longitude and latitude. We review the system with real-time implementation and testing with the help of "Rescue 1122 Sialkot, Pakistan." A survey is conducted to evaluate the reactions of firefighters and workers of the production unit. We compare the system results with fire head station data of response time, indicating a remarkable difference between manual and systemgenerated call response time. In the future, it can be developed further to include hardware such as a camera in the transmitted part to send a video to the emergency monitoring part and describe the situation online. In the future, it can be developed further to include hardware such as a camera in the transmitted part to send a video to the emergency monitoring part and describe the situation online.
Data Availability e data used in this research can be obtained from the corresponding author.

Conflicts of Interest
e authors declare that they have no conflicts of interest.