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.
- Python: Needed for MkDocs
- Node Package Manager: Used to install needed dependencies for pre-commit hooks
- .NET 9.0 SDK: Used for our Rest-API
- Docker
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:
- Open a terminal, navigate to the
IsoPrüfi
directory, and run:
- Once the containers are running, create an admin token for InfluxDB:
-
Copy the generated token string.
-
Create a
config.json
file at the following location:
- 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"
}
-
Run dotnet user-secrets set "Influx:InfluxDBToken" "
" --project isopruefi-backend\MQTT-Receiver-Worker\MQTT-Receiver-Worker.csproj -
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:
-
Install the PlatformIO Extension in Visual Studio Code
-
Open the folder code/arduino/ (or wherever the firmware is located)
-
Build and upload the firmware using the PlatformIO toolbar (✓ and →) or command palette
-
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 😊