Inspiration
When it comes to emergencies in buildings such as fires, earthquakes or active intruders, every second counts. In the US, the number of domestic fires have gone down per year, but deaths per fire due to egress difficulties have been steadily increasing. Traditional red EXIT signs, which are the primary escape infrastructure, are stateless and do not account for pathways such as stairs becoming unusable. For people to exit premises efficiently, a real time solution needs to be implemented to account for the unexpected dangerous or blocked paths.
What It Does
DirExit is not just an upgraded form of the EXIT sign, but also an entirely comprehensive safety system designed to navigate human traffic out of buildings, help emergency responders assess situations, and assist in prioritizing exit routes. The physical DirExit sign can perform multiple tasks. It first has an LED indicator to signal which path to take if a person needs to escape. It will also be continuously collecting environment information through a breadth of sensors that will help indicate if a pathway is deemed unusable by fire or debris. At the same time, multiple DirExit signs which are placed in important pathways will be uploading this data to a localized server. The server then calculates the fastest route for egress within the building floor plans for each of the sign's location in real time and pushes this newly updated information back to the corresponding DirExit. The sign will then update its LED indicator if need be towards a new direction if the current path becomes blocked. In addition, all DirExit sensor data is sent to Google Cloud for further analysis which includes graphing, plotting, and visualizing fire or damage circulation. Finally, there is a real time GUI displaying the current calculated routes for a given location which will help responders assess their priorities in rescue.
How We Built It
The DirExit sign consists of three connected peripherals (temperature, light, and distance sensors) from the Grove suite on a Grove multiplexing board attached to a RaspberryPi. With these three sensors retrieving data together, it becomes possible to set a weighted criteria in determining if the path is obstructed. The temperature sensor will check for rising temperatures due to fire, the light sensor for increasing light intensity, and finally the distance sensor for physical obstructions. The data collected by the prototype is sent to a remote server where it is processed, utilizing a matrix of 1's and 0's representing the floor plan for the algorithm to find an escape route. A separate Python script was written to convert floor plan images to matrices.
The server is written in Python with UDP Sockets and TKInter to communicate with any number of DirExit signs, while the routing algorithm is inspired by Dijkstra's Algorithm. Upon successful routing, the server then signals back the appropriate lighting sequences for the LED indicators for direction, which is part of a simple circuit built into the DirExit sign. The GUI will also update its visualized path if needed for emergency responders.
In addition to pushing data to the localized server, the RaspberryPi also keeps track of its sensor data with a timestamp and sends the information to Google Cloud to exploit cloud services such as real time graphing and damage spread control. Finally, it is recognized that a simple sensor suite may not be enough in determining a dangerous path especially in earthquakes where debris are of major concern. As a result, a machine learning program built with tensor flow which takes video from a webcam was also built for proof of concept. The program is designed such that the DirExit will be connected to a camera and is be able to determine if a path is rendered dangerous due to rubble, adding in a powerful layer of obstruction detection.
Challenges We Ran Into
Although a python script was written to convert a floor plan of any size to a matrix of 1's and 0's, the file size and hence the matrix, would often become too large to efficiently traverse. A compression algorithm was needed to reduce the potential search space, otherwise there may exist redundant searches for trivial paths. Despite repeated attempts to develop such algorithm, it was not possible to account for all edge cases within the hackathon event. The team had to resort to using block floor plans which could easily be designed and changed.
Difficulties were also encountered when attempting to run a UDP server on the local machine along with TKInter as each port can only be used once for each server. Installing the required Python packages to use the Grove Base Hat for the RaspberryPi to multiplex different sensors were especially difficult due to slow internet, poor documentation on the Grove Base Hat, and slow processing speeds.
Accomplishments That We're Proud Of
The team is proud to have integrated all the core components of our project, having combined disparate elements including machine learning, hardware, routing algorithms, and visualizations together. It was an immense amount of work to hash out every aspect of our comprehensive safety solution, then physically creating it with technology.
What's Next for DirExit
Numerous improvements are necessary for DirExit to fully encompass our comprehensive solution. On the DirExit sign, future steps will include upgrading to more accurate sensors, building a prototype PCB for the hardware circuitry, and scoping out a micro controller with a smaller form factor. Future software work will involve introducing over the air updates for each sign, incorporating numerous DirExit signs for routing, advancing image-on-receipt compression, and researching more efficient path finding algorithms.
Built With
- circuitry
- dijkstrasalgorithm
- google-cloud
- grovebasehat
- grovelightsensor
- grovetemperaturesensor
- groveultrasonicsensor
- led
- machine-learning
- pillow
- python
- raspberrypi
- sockets
- tensorflow
- tkinter
- udp





Log in or sign up for Devpost to join the conversation.