Skip to content

Latest commit

 

History

History
124 lines (87 loc) · 7.8 KB

Contributing.md

File metadata and controls

124 lines (87 loc) · 7.8 KB

Contributing Guidelines

IMPORTANT Information

All new development changes should be done as pull requests against the beta branch.

The default master branch is only used as a source reference for the currently active (enrolled) firmware version.

Reporting bugs

Before creating bug reports, please check this list as you might find out that you don't need to create one. When you are creating a bug report, please include as many details as possible in literal form (e.g. copy, don't interpret).

Note: If you find a Closed issue that seems like it is the same thing that you're experiencing, open a new issue and include a link to the original issue in the body of your new one.

Before Submitting A Bug Report

  • Check the FAQs on luftdaten.info for a list of common questions and problems.
  • Perform a cursory search to see if the problem has already been reported. If it has and the issue is still open, add a comment to the existing issue instead of opening a new one.

Build Instrutions

Recommended Build using PlatformIO

Current revisions of airRohr firmware are being tested and released by using PlatformIO Core. The included platformio.ini file is used to install and update all required dependencies into the correct and required version. While the dependencies are listed here in more detail, the authoritative versions and references are in the platformio.ini file.

PlatformIO provides many IDE integrations.

Build using Arduino IDE

As a fall back it should be possible to build the firmware via the Arduino IDE. This method is only a fallback over the PlatformIO. Any submission to the repository must pass building and work with a PlatformIO based build.

Settings needed:

Configuration Settings in Arduino IDE:

  • Board: NodeMCU 1.0 (ESP-12E Module)
  • CPU Frequency: 160MHz
  • Flash Size: 4M (3M SPIFFS)
  • Debug Port: Disabled
  • Debug Level: NoAssert-NDEBUG
  • lwIP Variant: v2.0 Lower memory
  • VTables. Flash
  • Erase Flash: Only Sketch

Libraries used from ESP8266 Arduino:

  • Wire (GNU Lesser General Public License v2.1)
  • FS (GNU Lesser Public License >=2.1)
  • ESP8266WiFi (GNU Lesser Public License >=2.1)
  • ESP8266WebServer (GNU Lesser Public License >=2.1)
  • ESP8266HTTPClient (GNU Lesser Public License >=2.1)
  • DNSServer (GNU Lesser Public License >=2.1)

Additional Libraries needed for building:

Source Layout

File Description
airrohr-firmware.ino Source code of the actual firmware
ext_def.h Basic configuration of the parameters (WLAN, sensors, APIs)
html-content.h General HTML sources and images for HTML and text output
intl_xx.h Files with translated texts for internationalization, 'xx' is the 2 letter ISO code of the 'language'
intl_template.h Template for translations
astyle.rc Formatting template for Astyle
ppd42ns-wificonfig-ppd-sds-dht.spiffs.bin Binary with an empty file system, to delete the configuration, see the instructions in the wiki

Translations

For new translations copy the file intl_template.h and rename it to intl_xx.h, where xx is the ISO-3166-2 two letter country code. This file contains all strings used for output seen by normal users. Only debug output is remaining EN by default.

Please take look at the existing translations and try to adhere and improve consistency accross and within the particular translation.

Reference list of all known I2C addresses used by the I2C device by instances that Airrohr Firmware is aware of

Device Class Address declaration Declaration location I2C address(es)
LCD 1602 LiquidCrystal_I2C - airrohr-firmware.ino row 4024 0x27 or 0x3F
LCD 2004 LiquidCrystal_I2C - airrohr-firmware.ino row 4033 0x27 or 0x3F
HTU21D Adafruit_HTU21DF HTU21DF_I2CADDR(0x40) Adafruit_HTU21DF.h 0x40
SHT31 Adafruit_SHT31 SHT31_DEFAULT_ADDR 0x44 Adafruit_STH31.h 0x44
DNMS - DNMS_I2C_ADDRESS 0x55 dnms_i2c.h 0x55
SCD30 SCD30 SCD30_ADDRESS 0x61 SparkFun_SCD30_Arduino_Library.h 0x61
SPS30 - SPS_I2C_ADDRESS0x69 sps30_i2c.h 0x69
BMP280 BMX280 const airrohr-firmware.ino 0x77 (default) or 0x76
BME280 BMX280 const airrohr-firmware.ino 0x77 (default) or 0x76
BM085: Adafruit_BMP085 BMP085_I2CADDR 0x77 Adafruit_BM085.h 0x77
BM180: Adafruit_BMP085 BMP085_I2CADDR 0x77 Adafruit_BM085.h 0x77

Do not forget to update the table above when you are implementing a new I2C device.

TODOs