{"id":14977972,"url":"https://github.com/modo-github/enviroplusweb","last_synced_at":"2026-02-22T07:30:57.542Z","repository":{"id":252520893,"uuid":"836632810","full_name":"modo-github/enviroplusweb","owner":"modo-github","description":"!!!!! Currently broken!!!! This is a work in Progress. Web interface for Enviro and Enviro+ sensor board plugged into a Raspberry Pi.  Measure air quality (pollutant gases and particulates), temperature, humidity, pressure, light and noise.","archived":false,"fork":false,"pushed_at":"2024-08-18T13:13:46.000Z","size":2094,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"modo-master","last_synced_at":"2025-10-23T20:58:09.367Z","etag":null,"topics":["enviroment","enviroplus","python","raspberry-pi","raspberrypi"],"latest_commit_sha":null,"homepage":"https://shop.pimoroni.com/products/enviro?variant=31155658457171","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/modo-github.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-01T08:43:28.000Z","updated_at":"2024-08-18T13:13:49.000Z","dependencies_parsed_at":"2024-09-23T23:30:34.316Z","dependency_job_id":"c996ac5d-2a55-42dd-a422-c5987d8c6961","html_url":"https://github.com/modo-github/enviroplusweb","commit_stats":{"total_commits":76,"total_committers":3,"mean_commits":"25.333333333333332","dds":0.3157894736842105,"last_synced_commit":"2973848980208e17244feac7731fd8f655ec8c78"},"previous_names":["modo-github/enviroplusweb"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/modo-github/enviroplusweb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modo-github%2Fenviroplusweb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modo-github%2Fenviroplusweb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modo-github%2Fenviroplusweb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modo-github%2Fenviroplusweb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/modo-github","download_url":"https://codeload.github.com/modo-github/enviroplusweb/tar.gz/refs/heads/modo-master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modo-github%2Fenviroplusweb/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29706569,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-22T05:59:28.568Z","status":"ssl_error","status_checked_at":"2026-02-22T05:58:46.208Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["enviroment","enviroplus","python","raspberry-pi","raspberrypi"],"created_at":"2024-09-24T13:56:37.456Z","updated_at":"2026-02-22T07:30:57.524Z","avatar_url":"https://github.com/modo-github.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🌿 Enviro Plus Web\n\nWeb interface for [Enviro](https://shop.pimoroni.com/products/enviro?variant=31155658489939) and [Enviro+](https://shop.pimoroni.com/products/enviro?variant=31155658457171) sensor board plugged into a Raspberry Pi.  \nThis simple webapp serves a page with the current sensor readings in a graph over a specified time period.  \nRuns thanks to [Flask](https://flask.palletsprojects.com) and [Chart.js](https://www.chartjs.org/)\n\n![Screenshot](screenshot-lightTheme.jpg)\n\n![Screenshot](screenshot-darkTheme.jpg)\n\nOG Fork from \u003chttps://github.com/nophead/EnviroPlusWeb\u003e\nForked from \u003chttps://gitlab.com/idotj/enviroplusweb\u003e\n\n⚠️ Enviro readings must not be relied upon for critical applications.\n\n## 📖 User guide\n\n### Install (tested on Raspberry Pi OS Bookworm)\n\nTo start with, open your terminal and install the necessary dependencies in your Raspberry Pi:\n\n```terminal\nsudo apt install python3-pip python3-cffi libportaudio2 python3-numpy python3-smbus python3-pil python3-setuptools python3-flask\n```\n\nAfter installation, enable i2c and SPI:\n\n```terminal\nsudo raspi-config nonint do_i2c 0\n```\n\n```terminal\nsudo raspi-config nonint do_spi 0\n```\n\nAdditionally if you are using a particule sensor [PMS5003](https://shop.pimoroni.com/products/pms5003-particulate-matter-sensor-with-cable?variant=29075640352851) you will need to perform the requiered configuration depending on your OS version:\n\n- **Bookworm**:\n\n  ```terminal\n  sudo raspi-config nonint do_serial_cons 1\n  ```\n\n  ```terminal\n  sudo raspi-config nonint do_serial_hw 0\n  ```\n\n  Also edit your config.txt file by typing:\n\n  ```terminal\n  sudo nano /boot/firmware/config.txt\n  ```\n\n  and add the following lines at the end of the file:\n\n  ```terminal\n  dtoverlay=pi3-miniuart-bt\n  dtoverlay=adau7002-simple\n  ```\n\nReboot your Raspberry Pi to apply these changes.\n\n```\nsudo reboot -h now\n```\n\nNow it's time to install the Python libraries in the \"enviroplusweb\" virtual environment. For that, create a new one:\n\n```terminal\npython3 -m venv --system-site-packages $HOME/.virtualenvs/enviroplusweb\n```\n\nAfter creation, it has to be activated:\n\n```terminal\nsource ~/.virtualenvs/enviroplusweb/bin/activate\n```\n\nAnd now the Enviro libraries can be installed:\n\n```terminal\npython3 -m pip install enviroplus\n```\n\nThe system is ready to clone the project in your Raspberry Pi. To achieve this, type:\n\n```terminal\ngit clone https://github.com/modo-github/enviroplusweb.git\n```\n\nAll set, you can now run the app:\n\n```terminal\ncd enviroplusweb\n```\n\n```terminal\npython enviroplusweb.py\n```\n\nOpen your browser and type the IP address of your Raspberry Pi followed by port :8080, example: `http://192.168.1.142:8080`\n\n### Setup\n\nCheck at the beginning of the file `enviroplusweb.py` the following lines and choose `True` or `False` depending on your config:\n\n- If you prefer to keep the Enviro LCD screen off, edit this line:\n\n  ```python\n  lcd_screen = False\n  ```\n\n- If you don't have a fan plugged into your Raspberry Pi, edit this line:\n\n  ```python\n  fan_gpio = False\n  ```\n\n- If you need temperature scale based on Fahrenheit, edit this line:\n\n  ```python\n  temp_celsius = False\n  ```\n\n- If you don't need temperature and humidity compensation, edit this line:\n\n  ```python\n  temp_humi_compensation = False\n  ```\n\n- If you have an Enviro board without gas sensor, edit this line:\n\n  ```python\n  gas_sensor = False\n  ```\n\n- If you don't have a particulate sensor [PMS5003](https://shop.pimoroni.com/products/pms5003-particulate-matter-sensor-with-cable?variant=29075640352851) plugged, edit this line:\n\n  ```python\n  particulate_sensor = False\n  ```\n\n### Extra setup\n\nMaybe you want to run Enviro Plus Web at boot, then just type in the terminal:\n\n```terminal\ncrontab -e\n```\n\nAdd a new entry at the bottom with `@reboot` to specify that you want to run the command every time you restart your Raspberry Pi. Remember to replace in the path your HOSTNAME (if your default hostname is not 'raspberrypi').\n\n```terminal\n@reboot /bin/bash -c 'source ~/.virtualenvs/enviroplusweb/bin/activate \u0026\u0026 sudo ~/.virtualenvs/enviroplusweb/bin/python /home/raspberrypi/enviroplusweb/enviroplusweb.py \u003e\u003e /home/raspberrypi/enviroplusweb/enviroplusweb.log 2\u003e\u00261'\n```\n\n## 🚀 Improve me\n\nFeel free to add your features and improvements.\n\n## ⚖️ License\n\nGNU Affero General Public License v3.0\n\n## 💬 FAQ\n\n- ### Where are my data readings saved?\n\n  Depends on where you run `enviroplusweb.py`. By default your data will be stored in the same place where you have the application, in JSON format inside a folder called `/enviroplusweb-data`.  \n  But if you run the app at bootup (for example, using the _crontab_) then your folder `/enviroplusweb-data` will be at `/home/raspberrypi` (if your default hostname is 'raspberrypi').\n\n- ### How can I get my Raspberry Pi IP?\n\n  Enter `hostname -I` in a Terminal window on your Raspberry Pi, then you will see the IPv4 and the IPv6.\n\n- ### Graphs are empty, they don't draw any lines, but the live readings on the header are displayed\n\n  You need to wait to have some data recorded in your Raspberry Pi. If you just run the app for first time, give it some time to save readings (~25min).\n\n- ### The Enviro screen doesn't show any data\n\n  If you just run the app for first time, it's normal. You must wait (~25min) until a file with the most recent readings is generated.\n\n- ### I got an error related with 'adau7002' while running Enviroplusweb\n\n  When I connect a display via HDMI to the Raspberry Pi Zero W, this error shows in the terminal:  \n  `ValueError: No input device matching 'adau7002'`  \n  Simply disconnecting the HDMI cable solves the problem.\n\n  Another case where this error occurs, is after a reboot at application launch (no display connected).  \n  It seems that the library that manages the audio is not very reliable. There is a [thread](https://github.com/pimoroni/enviroplus-python/issues/11) about this issue that is still open.  \n  At the moment the quickest solution is to reboot your Raspberry Pi again.\n\n- ### Raspberry Pi is running other services at localhost\n\n  You can change the port to avoid any conflict with other applications. In that case edit the file `enviroplusweb.py` and find at the end this line:\n\n  ```python\n  app.run(debug=False, host='0.0.0.0', port=8080, use_reloader=False)\n  ```\n\n  Just change the `port=8080` for another number (for example `4567`) and run again the app. Now you can access to your EnviroPlusWeb typing the ip address followed by `:4567`\n\n- ### Enviro Plus Web is running but I can't connect to the web server through my browser\n\n  If running your app, you can see in the terminal the following message:\n\n  ```terminal\n  * Serving Flask app 'enviroplusweb'\n  * Debug mode: off\n  Permission denied\n  ```\n\n  This problem may be due to `port=80` not being available to be used by the application and you have to use another port.\n\n- ### I want to run my EnviroPlusWeb under HTTPS\n\n  By default you use HTTP to connect to your Raspberry Pi through your browser, but some browsers will redirect automatically to HTTPS. If you prefer to have your project running under HTTPS here you have a tutorial explaning how to setup Flask with HTTPS:  \n  \u003chttps://blog.miguelgrinberg.com/post/running-your-flask-application-over-https\u003e\n\n- ### Sometimes my Raspberry Pi disconnects from the wifi and I can't connect again\n\n  There is an option that manages the power of the wifi and allows to put it in saving mode. Disabling this option may help you to avoid this problem. First check if the wifi power save feature is enabled or not:\n\n  ```terminal\n  iw wlan0 get power_save\n  ```\n\n  If it is enabled, then edit the following file (replace HOSTNAME with the name you set for your Raspberry Pi):\n\n  ```terminal\n  sudo nano /home/HOSTNAME/.bashrc\n  ```\n\n  And add the following line at the end:\n\n  ```terminal\n  sudo iwconfig wlan0 power off\n  ```\n\n  Reboot and check again typing the first command to see if the feature is enabled or not.\n\n### Other answered questions\n\nCheck the [closed issues](https://gitlab.com/idotj/enviroplusweb/-/issues/?sort=created_date\u0026state=closed\u0026first_page_size=20), you might find your question there.  \nIf nothing matches with your problem, check the [open issues](https://gitlab.com/idotj/enviroplusweb/-/issues/?sort=created_date\u0026state=opened\u0026first_page_size=20) this is where the orginal was forked from. If you still have issues with my version please add an issue via github. \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmodo-github%2Fenviroplusweb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmodo-github%2Fenviroplusweb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmodo-github%2Fenviroplusweb/lists"}