2025-04-15 02:00:18 +02:00
2025-11-23 16:34:34 +01:00
2025-04-15 02:00:18 +02:00
2025-11-23 16:35:45 +01:00
2025-04-15 02:00:18 +02:00
2025-04-15 02:00:18 +02:00
2025-04-15 02:00:18 +02:00
2025-04-15 02:00:18 +02:00
2025-04-15 02:00:18 +02:00
2025-04-15 02:00:18 +02:00

Muraqib

CO2 sensor that collects and sends its data via MQTT to a server. The board of the sensor is the Wemos D1 mini and the sensor is a SCD41.

Pinout of the board

./pinout.png

Configuration

In the data directory, there is a JSON file that allows the configuration of multiple values:

  • ssid: WiFi network name
  • psk: WiFi password
  • mqtt_host: IP address of the MQTT broker
  • mqtt_user: username that has write access on the MQTT broker
  • mqtt_password: password for the user that has write access on the MQTT broker
  • mqtt_port: port used by the MQTT broker
  • mqtt_topic: channel name
  • device_id: unique identifier of the sensor
  • sleep_time: time interval between each data transmission
  • connection_attempts: maximum connection attemps to the network

The file needs to be renamed to config.json

Deployment

The software uses the Arduino framework and the development environment of PlatformIO, which offers better tooling than the official Arduino IDE.

Generate compilation database

pio run -t compiledb

Upload the configuration file to the board

pio run -t uploadfs

Compile the project

pio run -t compile

Upload firmware

pio run -t upload
Description
No description provided
Readme 4 MiB
Languages
C++ 71.7%
C 22.1%
Nix 6.2%