Use the example Node-RED flows and dashboards to build an Earthquake Early Warning (EEW) system. After completing this tutorial, you will be ready to modify these example flows and dashboards to create your own EEW and data visualization solution.
The Node-RED flows in this tutorial observe the real-time OpenEEW accelerometer sensor data and calculate if the sensor might be experiencing seismic activity using an algorithm for vibration data.
The following animated gif shows the dashboard created from Example 3:
In this tutorial, you will:
- Install Node-RED and the prerequisites required to build the dashboards
- Learn how to program an algorithm to detect seismic shaking
- Build a dashboard that displays live Earthquake Early Warning Sensor Alerts on a map and sends a SMS warning if a possible earthquake is detected.
- Build a dashboard that plots real-time seismic activity sensor graphs in a chart by subscribing to a MQTT broker.
- Build a dashboard that plots the historical seismic activity from an OpenEEW dataset.
Add the following nodes to your Node-RED palette.
Completing this tutorial should take about 30 minutes.
Example 1: Build a flow that displays sensor alerts on a map
This flow plots the OpenEEW sensors on a map of Mexico and displays their seismic activity status.
Example 2: Build a flow that plots near real-time seismic activity sensor graphs in a chart
This flow subscribes to the live data feed (which is available via MQTT) of a selected sensor, and then plots the seismic activity in a set of graphs.
Example 3: Plot the historic seismic activity from an OpenEEW dataset
This flow displays a Node-RED dashboard that allows an investigator to select an interesting sensor and time period to study and then queries the OpenEEW dataset. The flow then plots the historical sensor data in a set of graphs.
This flow has six sections:
- Select a historical date
- Build and display an OpenEEQ dataset
- Select a sensor
- Cycle through a time series of adjacent datasets
- Plot seismic graphs
- Download historical sensor data
Summary and next steps
The openeew-nodered project is just one of the many OpenEEW projects that you can contribute to. Engage with the open source community and build solutions to address issues we all are facing today. Join the Call for Code challenge and contribute to these open source projects that are supported by the Linux Foundation.