Skip to content

Contribute & Build

How do I contribute as a developer?

READ THIS GUIDE BEFORE CONTRIBUTING

Since our project is secured by two pre-commit hocks, it is important to set up the project correctly before contributing.

This is done as followed:

Clone the project

git clone https://github.com/deadmade/IsoPruefi.git

Make sure you have installed the following packages globally.

After you've cloned the repo make sure to install all needed packages for the hooks via:

npm i

and run:

npm run init

Now it should be configured 🚀

To get the development environment up and running, follow these steps:

  1. Open a terminal, navigate to the IsoPrüfi directory, and run:
docker compose up
  1. Once the containers are running, create an admin token for InfluxDB:
docker exec -it influxdb influxdb3 create token --admin
  1. Copy the generated token string.

  2. Create a config.json file at the following location:

IsoPruefi/isopruefi-docker/influx/explorer/config
  1. Add the following content to config.json, replacing "your-token-here" with the copied token:
{
  "DEFAULT_INFLUX_SERVER": "http://host.docker.internal:8181",
  "DEFAULT_INFLUX_DATABASE": "IsoPrüfi",
  "DEFAULT_API_TOKEN": "your-token-here",
  "DEFAULT_SERVER_NAME": "IsoPrüfi"
}
  1. Run dotnet user-secrets set "Influx:InfluxDBToken" "" --project isopruefi-backend\MQTT-Receiver-Worker\MQTT-Receiver-Worker.csproj

  2. Restart the Containers

Arduino Set Up

Hardware

Software

⚠️ Important: Always open the Arduino firmware folder (e.g., code/arduino/) as a PlatformIO Project (via Open Project or Pick a folder in the PlatformIO sidebar). Otherwise, dependencies from platformio.ini might not be detected and you may see false errors in the editor.

To work on the Arduino/PlatformIO part of the project:

  1. Install the PlatformIO Extension in Visual Studio Code

  2. Open the folder code/arduino/ (or wherever the firmware is located)

  3. Build and upload the firmware using the PlatformIO toolbar (✓ and →) or command palette

  4. Make sure your board is connected and properly selected in platformio.ini

[env:mkrwifi1010]
platform = atmelsam
board = mkrwifi1010
framework = arduino
lib_deps = 
    arduino-libraries/WiFiNINA
    adafruit/Adafruit ADT7410 Library
    adafruit/RTClib
    arduino-libraries/ArduinoMqttClient
    greiman/SdFat
    gyverlibs/UnixTime
    bblanchon/ArduinoJson@^7.4.2

Tips:

  • PlatformIO installs the required libraries automatically on first build. If something fails, run pio run manually in the PlatformIO terminal

  • The main firmware entry point is located at src/main.cpp

  • Use the Serial Monitor (🔌) to debug via USB


Happy Coding 😊