RAK11300 or RAK4630 WisBlock Core
- RAK11300 or RAK4630 WisBlock Core
RAK1906
BME680
Temperature, humidity, pressure, air quality
PMSA003
PMS5003/7003
Particulate matter detection (PM1.0, PM2.5, PM10)
RAK12033
IIM-42652
6-axis accelerometer/gyroscope (vibration, movement)
RAK12027
Omron D7S
Earthquake/intense vibration detection
Others:WisBlock expansion board with I2C slots
- WisBlock expansion board with I2C slots
LoRa antenna
- LoRa antenna
LoRaWAN Gateway (e.g., Edge Lite 2)
- LoRaWAN Gateway (e.g., Edge Lite 2)
IoT Platform: The Things Stack (TTS) + Ubidots / Grafana / ThingsBoard
IoT Platform: The Things Stack (TTS) + Ubidots / Grafana / ThingsBoard
🖥️ 2. Development EnvironmentIDE: PlatformIO (Visual Studio Code)
- IDE: PlatformIO (Visual Studio Code)
Libraries:
SparkFun_IIM42652
SparkFun_IIM42652
Adafruit_BME680
Adafruit_BME680
RAKwireless
drivers for PMSA003 and Omron D7S
RAKwireless
drivers for PMSA003 and Omron D7S- Libraries:
SparkFun_IIM42652
drivers for PMSA003 and Omron D7S
Adafruit_BME680
RAKwireless
Framework: Arduino for RAK11300/RAK4630
- Framework: Arduino for RAK11300/RAK4630
Sensor
WisBlock Port
Interface
RAK12033
I2C (Sensor Slot)
I2C
RAK12027
I2C (another slot)
I2C
RAK1906
Sensor Slot
I2C
PMSA003
UART
UART
All I²C sensors can share the bus using different addresses, ensuring compatibility.
4. Node Programminga. Reading RAK12033 (IIM-42652)Read acceleration data on X, Y, Z axes every 5 seconds. Calculate a general vibration magnitude:
float mag = sqrt(x*x + y*y + z*z);
You can apply a moving average filter to smooth out the noise.
b. Reading RAK12027 (Omron D7S)This sensor activates only when it detects a seismic event. It can be polled or use an interrupt to check for an event:
if (d7s.isEarthquakeDetected()) {
// Action: alert, log, power shutdown
}
c. LoRaWAN Payload EncodingEfficient binary payload formatting is used. For example:
Byte Pos.
Content
0–1
Temperature (RAK1906)
2
Humidity
3
Air Quality Index
4–6
Vibration magnitude (RAK12033)
7
Seismic event flag (RAK12027)
5. IoT Platforma. The Things StackConfigure a Payload Formatter to decode the binary payload and display:
Temperature
- Temperature
Humidity
- Humidity
PM2.5
- PM2.5
Vibration (RAK12033)
- Vibration (RAK12033)
Seismic event (RAK12027)
- Seismic event (RAK12027)
- Configure a Payload Formatter to decode the binary payload and display:TemperatureHumidityPM2.5Vibration (RAK12033)Seismic event (RAK12027)
Custom dashboards with:
Gauges for temperature, humidity, IAQ
- Gauges for temperature, humidity, IAQ
Line charts for PM2.5 and vibration
- Line charts for PM2.5 and vibration
Earthquake event indicator
- Earthquake event indicator
- Custom dashboards with:Gauges for temperature, humidity, IAQLine charts for PM2.5 and vibrationEarthquake event indicator
Alerts for:
Vibration exceeding a threshold (e.g., 1.5 g)
- Vibration exceeding a threshold (e.g., 1.5 g)
Earthquake sensor triggered
- Earthquake sensor triggered
Poor air quality or extreme temperatures
- Poor air quality or extreme temperatures
- Alerts for:Vibration exceeding a threshold (e.g., 1.5 g)Earthquake sensor triggeredPoor air quality or extreme temperatures
Vibration test: lightly tap the table where the RAK12033 is mounted and verify the magnitude increases.
- Vibration test: lightly tap the table where the RAK12033 is mounted and verify the magnitude increases.
Earthquake simulation: shake the RAK12027 and check if an event is generated.
- Earthquake simulation: shake the RAK12027 and check if an event is generated.
Alert test: trigger alert conditions and verify notifications are sent (SMS, Telegram, email).
- Alert test: trigger alert conditions and verify notifications are sent (SMS, Telegram, email).
The RAK12033 is very sensitive; it's recommended to:
Apply software filtering
- Apply software filtering
Define a minimum detection threshold
- Define a minimum detection threshold
- The RAK12033 is very sensitive; it's recommended to:Apply software filteringDefine a minimum detection threshold
The RAK12027 only triggers on strong vibrations and can be used to initiate emergency protocols.
- The RAK12027 only triggers on strong vibrations and can be used to initiate emergency protocols.
Comments