{"id":20153757,"url":"https://github.com/zachstence/zero-weather","last_synced_at":"2026-05-01T22:35:28.323Z","repository":{"id":39216234,"uuid":"476463927","full_name":"zachstence/zero-weather","owner":"zachstence","description":"DIY a simple weather station using a Raspberry Pi Zero W and a DHT22 temperature/humidity sensor.","archived":false,"fork":false,"pushed_at":"2023-02-12T02:44:41.000Z","size":217,"stargazers_count":2,"open_issues_count":4,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-03T01:28:27.676Z","etag":null,"topics":["dht11","dht22","grafana","influxdb","raspberry-pi","typescript"],"latest_commit_sha":null,"homepage":"https://hub.docker.com/r/zachstence/zero-weather","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zachstence.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":"2022-03-31T20:16:11.000Z","updated_at":"2024-09-16T15:57:04.000Z","dependencies_parsed_at":"2024-11-13T23:31:45.745Z","dependency_job_id":null,"html_url":"https://github.com/zachstence/zero-weather","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/zachstence/zero-weather","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachstence%2Fzero-weather","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachstence%2Fzero-weather/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachstence%2Fzero-weather/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachstence%2Fzero-weather/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zachstence","download_url":"https://codeload.github.com/zachstence/zero-weather/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachstence%2Fzero-weather/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32515838,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["dht11","dht22","grafana","influxdb","raspberry-pi","typescript"],"created_at":"2024-11-13T23:21:21.222Z","updated_at":"2026-05-01T22:35:28.304Z","avatar_url":"https://github.com/zachstence.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# zero-weather\nDIY a simple weather station using a Raspberry Pi Zero W and a DHT22 temperature/humidity sensor.\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/zachstence/zero-weather/blob/main/LICENSE\"\u003e\n        \u003cimg alt=\"license mit\" src=\"https://img.shields.io/github/license/zachstence/zero-weather?style=for-the-badge\" /\u003e\n    \u003c/a\u003e\n    \u003cbr /\u003e\n    \u003ca href=\"https://hub.docker.com/r/zachstence/zero-weather\"\u003e\n        \u003cimg alt=\"docker pulls\" src=\"https://img.shields.io/docker/pulls/zachstence/zero-weather?style=for-the-badge\" /\u003e\n        \u003cimg alt=\"docker size\" src=\"https://img.shields.io/docker/image-size/zachstence/zero-weather?style=for-the-badge\" /\u003e\n    \u003c/a\u003e\n    \u003cbr /\u003e\n    \u003ca href=\"#\"\u003e\n        \u003cimg alt=\"wakatime\" src=\"https://wakatime.com/badge/user/2a0a4013-ea89-43b7-99d9-1a215b4c34d0/project/b06aa0fa-f2b5-40fa-9639-0382daedde63.svg?style=for-the-badge\" /\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n## Table of Contents\n- [Usage](#usage)\n  - [Run using `npm`](#run-using-npm)\n  - [Run using Docker](#run-using-docker)\n  - [Run using `docker-compose`](#run-using-docker-compose)\n- [Config](#config)\n- [Grafana Dashboard](#grafana-dashboard)\n- [Future Features](#future-features)\n\n## Usage\nAll methods require a [configuration file](#config).\n### Run using `npm`\n```sh\n# Clone the repository\ngit clone https://github.com/zachstence/zero-weather.git \u0026\u0026 cd zero-weather\n\n# Add your config\nnano config/production.json\n\n# Start the app\nnpm start\n```\n\n### Run using Docker\n```sh\ndocker run \\\n    --device /dev/gpiomem:/dev/gpiomem \\\n    -v /path/to/config.json:/app/config/production.json:ro \\\n    zachstence/zero-weather\n```\n\n### Run using `docker-compose`\n```yaml\nversion: \"3.8\"\n\nservices:\nzero-weather:\n    image: zachstence/zero-weather\n    devices:\n    - /dev/gpiomem:/dev/gpiomem\n    volumes:\n    - /path/to/config.json:/app/config/production.json:ro\n    restart: unless-stopped\n```\n\n## Config\nCreate a config file following the format in [`config/default.json`](config/default.json)\n\n```json\n{\n    \"sensor\": {\n        \"type\": 22,\n        \"pin\": 14,\n        \"interval\": 30\n    },\n    \"influxdb\": {\n        \"url\": \"\",\n        \"org\": \"\",\n        \"bucket\": \"\",\n        \"token\": \"\"\n    }\n}\n```\n\n| Config                  | Description                                                                                                                                          | Example                                                                                    |\n| ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------ |\n| `sensor.type`           | Whether your connected sensor is a DHT11 or DHT22 sensor                                                                                             | `11` or `22`                                                                               |\n| `sensor.pin`            | The [GPIO pin](https://pinout.xyz/) that your DHT sensor is connected to                                                                             | `14`                                                                                       |\n| `sensor.interval`       | The interval in seconds that the sensor should be polled.\u003csup\u003e1\u003c/sup\u003e                                                                                | `30`                                                                                       |\n| `influxdb.url`          | The base URL of your InfluxDB instance                                                                                                               | `http://localhost`                                                                         |\n| `influxdb.org`          | The name of your [InfluxDB organization](https://docs.influxdata.com/influxdb/v2.1/organizations/create-org/)                                        | `org-name`                                                                                 |\n| `influxdb.bucket`       | The name of the [InfluxDB bucket](https://docs.influxdata.com/influxdb/v2.1/organizations/buckets/create-bucket/) to store the data in               | `zero-weather`                                                                             |\n| `influxdb.token`        | An [InfluxDB token](https://docs.influxdata.com/influxdb/v2.1/security/tokens/create-token) with write permissions to the specified bucket           | `9jPxAm8tEZSnRlw8nAsEDWZbvHCYeUetIAUrT_vj6RdHfG43RF5UKfazyZ1Z9dYu1o7prU7-kC4X8oUP-PSxTg==` |\n\n\u003csup\u003e1\u003c/sup\u003e The DHT11 can be polled at most once every second (1Hz, `sensor.interval=1`). The DHT22 can be polled at most once every half-second (0.5Hz, `sensor.interval=0.5`).\n\n## Grafana Dashboard\nhttps://grafana.com/grafana/dashboards/16035\n\n## Future Features\n- Accept file for Influx token to enable better security (Docker secrets)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzachstence%2Fzero-weather","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzachstence%2Fzero-weather","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzachstence%2Fzero-weather/lists"}