IoT Project
Introduction
The aim of the project was to use a Senirion CO2 sensor to measure C02 concentration in a room, transmit
the measurements over Bluetooth (BLE), store the data in the cloud (HiveMQ) and in databases (mariadB and influxdB), and it
was then
presented the measured C02 concentration in a Grafana dashboard.
The IoT project is broken down into 3 sections:
- 1. Low Level Interfacing (BBC Microbit and ZephyrOS)
- 2. Gateway Development using BLE and MQTT
- 3. Data representation (MariadB and InfluxdB)
Components
-
BBC micro:Bit v2 Board
-
SCD30 Sensirion Sensor
-
Raspberry pi
-
MQTT broker: HiveMQ
-
24MHz 8-channel logic analyser
-
Breadboard
-
Jump wires
Section 1: IoT Low Level Interfacing
Objective
Build a low-level interfacing system using the given components such as the Sensirion sensor, bbc microbit and the 24MHz 8channel logic analyser. Both the BLE interface and the serial port should be used to present data from the sensor. The LED matrix should light up if the CO2 level rises above a specified threshold (e.g., 600ppm).
Section 1: Video Demonstration
Section 2: Gateway Development using BLE and MQTT
Objective
Create a system that uses a gateway to communicate with a Bluetooth Low Energy end device (BLE). It is necessary to create a unique BLE central device application (running on the Raspberry Pi) that uses BLE services and characteristics specified on a BBC MicroBit BLE peripheral device to monitor and report environmental variables. The peripheral device in this assignment is the microBit which will have BLE service. It works closely with the SCD30 sensirion sensor which reads in the Co2 values. These data are sent to the central device gateway and will activate another BLE service such as LED. The gateway reads in the Co2 values from microBit and send them to a MQTT broker and then subscribe to the broker for messages to send back to the microBit.
Section 2: Video Demonstration
Section 3: Data representation
Objective
Create a nodejs file that creates two databases: mariadB database called Rmicrobit and an influxdB database called Imicrobit. The Co2 values will be then stored in the two databases and will display the data in real-time using Grafana panel. SQL and InfluxSQL queries will also be shown to extract values from the database.