Inspiration
Given the lack of warning with flash floods, wildfires, and certain disasters, communities often suffer due to a lack of warning of disasters with no precedence. While meteorologists can often forecast large-scale weather changes ahead of time, our solution aims to predict the unpredictable using a device containing multiple types of sensors to detect environmental changes. Our goal is to have a local alert/detection system utilizing changes in the immediate environment to alert local communities of an imminent disaster.
General Functions
Our project consists of multiple sensors in a single device that actively receives and sends input to a mobile or web application. The device sends water level, humidity, and temperature data and detects changes which are then displayed in the web application. To achieve our end goal of an effective local alert system, it would require multiple sensors strategically placed in disaster-prone areas.
Building the device
There are three main components to this project. The first component is the monitoring device itself, which is an Arduino with a water level detection sensor and temperature/humidity sensor. This is connected to one of our laptops that has a javascript that will read the JSON data from the Arduino, timestamp it, and send it to a MongoDB database via an API and POST using Axios.
The second component is the MongoDB database, which can store multiple collections/tables corresponding to each device if we made more than one of them. Each document/object in the collections has a unique id, temperature value, humidity value, water level value, and timestamp. The MongoDB database is accessed using an API we created for ease of access, if which we are able to send POST and GET requests with Axios. The API is live on the Google Cloud Platform, hosted with App Engine and using a custom domain.
The last component is the web application itself, which is a NodeJS backend with an Express framework, hosted on Heroku. The web app sends GET requests to the MongoDB server, parses the JSON data, and updates information on the website accordingly. The main dashboard displays the latest readings from the device and tells you if there is a disaster occurring or not. The report tab gives you a visual graph and table of all past readings.
Challenges
The first challenge we ran into was getting the Arduino and sensors to work and output correct data. It took a couple of hours to set up and lots of rewiring, but we finally got it to output correctly.
Our first challenge was getting Arduino and its sensors to output the correct data. After some set up and rewiring, we were able to move on to redirecting the input. Through JavaScript, we were able to read the output and redirect it to MongoDB. However, we faced troubles in simply connecting Arduino via SerialPort. Then we also needed to convert and parse the data into JSON for file reading purposes. MongoDB was a pain enough, but not until using it that we find not enough documentation. Instead, we created our own API to handle the MongoDB requests, and then processed by our web app.
Due to covid constraints, our team was not fully in person, thus straining our working capacity.
Our Key Takeaways
Throughout the hackathon, we came across and learned many new technologies and their versatilities. The Arduino is a multifaceted device with many devices to achieve our goals. NodeJS is a great and essential tool to our success, as our use for it involved the web application and displaying our data. Most importantly, communication and preparedness are what we find to be the biggest contributor to our success. Through clear and effective communication, our project progressed relatively well as the ease that came in synthesizing the front and backend of our project. This was the first hackathon for some of the team members, our team members effectively communicating gave us a great experience.
Future Improvements
Our project was definitely not the best, though we are proud to say that this project has real potential. After solidifying our project, I believe that we can expand on where this device could be applied. One aspect could be the types of data we could gather. For this project, we were limited to water levels, humidity, and temperature; however, given more types of sensors, we could detect other disasters such as avalanches, earthquakes, and more. We could also adjust the project for live data input and feedback for data and research.

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