{"id":46612991,"url":"https://github.com/modrisb/chirp","last_synced_at":"2026-03-07T19:00:55.697Z","repository":{"id":225391450,"uuid":"765796319","full_name":"modrisb/chirp","owner":"modrisb","description":"ha mqtt to chirpstack integration","archived":false,"fork":false,"pushed_at":"2025-08-09T17:27:44.000Z","size":120,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-09T19:20:33.410Z","etag":null,"topics":["chirpstack","custom-component","home-assistant","lorawan"],"latest_commit_sha":null,"homepage":"https://github.com/modrisb/chirp","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/modrisb.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":"CODE_OF_CONDUCT.md","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,"zenodo":null}},"created_at":"2024-03-01T16:24:54.000Z","updated_at":"2025-08-09T17:26:23.000Z","dependencies_parsed_at":"2024-03-22T16:26:43.717Z","dependency_job_id":"91e2826a-a54b-4144-93d2-caffabd48727","html_url":"https://github.com/modrisb/chirp","commit_stats":null,"previous_names":["modrisb/chirp"],"tags_count":12,"template":false,"template_full_name":null,"purl":"pkg:github/modrisb/chirp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modrisb%2Fchirp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modrisb%2Fchirp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modrisb%2Fchirp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modrisb%2Fchirp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/modrisb","download_url":"https://codeload.github.com/modrisb/chirp/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/modrisb%2Fchirp/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30226744,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T18:12:09.766Z","status":"ssl_error","status_checked_at":"2026-03-07T18:11:58.786Z","response_time":53,"last_error":"SSL_read: 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":["chirpstack","custom-component","home-assistant","lorawan"],"created_at":"2026-03-07T19:00:42.504Z","updated_at":"2026-03-07T19:00:55.685Z","avatar_url":"https://github.com/modrisb.png","language":"Python","readme":"# Chirp - ChirpStack to HomeAssistant MQTT Integration\n\n[![hacs_badge](https://img.shields.io/badge/HACS-Default-orange.svg)](https://github.com/custom-components/hacs)\n\nChirp as [Home Assistant](https://home-assistant.io) integration component glues together HA MQTT and ChirpStack LoRaWAN server. LoRaWAN devices information is retrieved from ChirpStack gRPC api server and exposed to HA MQTT integration discovery service. Data transferred by/to LoRaWAN devices are retained on MQTT server to support HA/integration restart. Detailed configuration information needed for HA is stored as ChirpStack codec extension.\n\n## Sensors supported\n* Chirp does not limit devices by type/features, but is limited by codec extension that need to be prepared for each device type separately.\n\n## Prerequisits\nThe Home Assistant MQTT integration with MQTT server needs to be installed. Chirpstack and Chirpstack gateways need to be configured to use the **same MQTT server** as the HA MQTT integration.\n\n## Manual installation \n1. Inside the `custom_components` directory, create a new folder called `chirp`.\n2. Download all files from the `custom_components/chirp/` repository to this directory `custom_components/chirp`.\n3. Install integration from Home Assistant Settings/Devices \u0026 Services/Add Integration and continue with UI configuration. ChirpStack server credentials required, including API key used for connection authentication. On HA side MQTT server credentials and MQTT discovery details needed.\n\nHACS might be used for installation too - check repository 'Chirp'.\n\n## Devices Configuration\nChirp uses the Codec function block of ChirpStack device profiles to generate the HA integration details. Information about device type details and device specifics (device enabled, device battery details) is encoded in a Javascript function called `getHaDeviceInfo`. Therefore, the Codec functions block must be extended with a function similar to:\n\n```\nfunction getHaDeviceInfo() {\n  return {\n    device: {\n      manufacturer: \"Milesight IoT Co., Ltd\",\n      model: \"WS52x\"\n    },\n    entities: {\n        current:{\n        entity_conf: {\n          value_template: \"{{ (value_json.object.current | float) / 1000 }}\",\n          entity_category: \"diagnostic\",\n          state_class: \"measurement\",\n          device_class: \"current\",\n          unit_of_measurement: \"A\"\n        }\n      },\n        factor:{\n        entity_conf: {\n          value_template: \"{{ (value_json.object.factor | float) / 100 }}\",\n          entity_category: \"diagnostic\",\n          state_class: \"measurement\",\n          device_class: \"power_factor\",\n        }\n      },\n      power:{\n        entity_conf: {\n          value_template: \"{{ value_json.object.power | float }}\",\n          entity_category: \"diagnostic\",\n          state_class: \"measurement\",\n          device_class: \"power\",\n          unit_of_measurement: \"W\"\n        }\n      },\n      voltage:{\n        entity_conf: {\n          value_template: \"{{ value_json.object.voltage | float }}\",\n          entity_category: \"diagnostic\",\n          state_class: \"measurement\",\n          device_class: \"voltage\",\n          unit_of_measurement: \"V\"\n        }\n      },\n      outage:{\n        integration: \"binary_sensor\",\n        entity_conf: {\n          entity_category: \"diagnostic\",\n          device_class: \"power\"\n        }\n      },\n      power_sum:{\n        entity_conf: {\n          value_template: \"{{ (value_json.object.power_sum | float) / 1000 }}\",\n          state_class: \"total_increasing\",\n          device_class: \"energy\",\n          unit_of_measurement: \"kWh\"\n        }\n      },\n      state:{\n       integration: \"switch\",\n       entity_conf: {\n          value_template: \"{{ value_json.object.state }}\",\n          command_topic: \"{command_topic}\",\n          state_on: \"open\",\n          state_off: \"close\",\n          payload_off: '{{\"dev_eui\":\"{dev_eui}\",\"confirmed\":true,\"fPort\":85,\"data\":\"CAAA/w==\"}}',\n          payload_on: '{{\"dev_eui\":\"{dev_eui}\",\"confirmed\":true,\"fPort\":85,\"data\":\"CAEA/w==\"}}'\n        }\n      },\n      rssi:{\n        entity_conf: {\n          value_template: \"{{ value_json.rxInfo[-1].rssi | int }}\",\n          entity_category: \"diagnostic\",\n          device_class: \"signal_strength\",\n          unit_of_measurement: \"dBm\",\n        }\n      }\n    }\n  };\n}\n```\n\nDevice information is used only for visualization, entities describe sensor details - how they are integrated into HA. value_template defines sensor value extraction rules from device payload and possible conversions (like converting to int/float and applying needed factors). Integration type is needed for MQTT to implement proper processing together with device class definition. More information about MQTT discovery fields can be found in the [HA MQTT integration docs](https://www.home-assistant.io/integrations/mqtt).\n\n## Add-on version\nSee https://github.com/modrisb/chirpha for add-on version of this integration.\n\n## Credits\n[ChirpStack](https://chirpstack.io/) : open-source LoRaWAN Network Server\u003cbr\u003e\n[Home Assistant](https://github.com/home-assistant) : Home Assistant open-source powerful domotic plateform with MQTT integratio.\u003cbr\u003e\n[HACS](https://hacs.xyz/) : Home Assistant Community Store gives you a powerful UI to handle downloads of all your custom needs.\u003cbr\u003e\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmodrisb%2Fchirp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmodrisb%2Fchirp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmodrisb%2Fchirp/lists"}