{"id":32172174,"url":"https://github.com/gertjana/p1_parser","last_synced_at":"2025-10-21T18:29:50.416Z","repository":{"id":49346503,"uuid":"151871136","full_name":"gertjana/p1_parser","owner":"gertjana","description":"Parses Smartmeter P1 telegrams","archived":false,"fork":false,"pushed_at":"2019-11-20T10:45:17.000Z","size":74,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-09T19:32:20.169Z","etag":null,"topics":["elixir-lang","p1","smartmeter"],"latest_commit_sha":null,"homepage":"","language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gertjana.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}},"created_at":"2018-10-06T18:45:30.000Z","updated_at":"2022-07-24T19:49:33.000Z","dependencies_parsed_at":"2022-09-22T16:03:16.692Z","dependency_job_id":null,"html_url":"https://github.com/gertjana/p1_parser","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/gertjana/p1_parser","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gertjana%2Fp1_parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gertjana%2Fp1_parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gertjana%2Fp1_parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gertjana%2Fp1_parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gertjana","download_url":"https://codeload.github.com/gertjana/p1_parser/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gertjana%2Fp1_parser/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280313686,"owners_count":26309535,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-21T02:00:06.614Z","response_time":58,"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":["elixir-lang","p1","smartmeter"],"created_at":"2025-10-21T18:29:47.233Z","updated_at":"2025-10-21T18:29:50.411Z","avatar_url":"https://github.com/gertjana.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![codebeat badge](https://codebeat.co/badges/bb2e3c59-1bfc-4cac-88e6-1a7064eca124)](https://codebeat.co/projects/github-com-gertjana-p1_parser-master) [![Build Status](https://travis-ci.org/gertjana/p1_parser.svg?branch=master)](https://travis-ci.org/gertjana/p1_parser) [![Hex.pm](https://img.shields.io/hexpm/v/p1_parser.svg)](https://hex.pm/packages/p1_parser) [![Hex.pm](https://img.shields.io/hexpm/dt/p1_parser.svg)](https://hex.pm/packages/p1_parser)\n\n\n# P1 Parser\n\nParses telegram's as they are output through the P1 serial port of a smartmeter\n\nNote that this only applies to Dutch smartmeters. \n\n## Installation\n\n```elixir\ndef deps do\n  [\n    {:p1_parser, \"~\u003e 0.2.2\"}\n  ]\nend\n```\n\n## Usage \n\nGet a usb to p1 cable and plug it in, you should see it appear as a serial device\n\nOn an raspberry pi it will show up as `/dev/ttyUSB0`, now the smartmeter will ouput a telegram every x seconds\n\nuse a serial libray like for instance `nerves_uart` to connect to it and receive telegrams\n\neach line in the telegram can now be parsed like this\n```elixir\niex\u003e P1.parse!(\"1-0:1.8.1(123456.789*kWh)\")\n```\nWhich will result in\n```\n[\n  %P1.Channel{channel: 0, medium: :electricity},\n  %P1.Tags{tags: [:total, :energy, :consume, :low]},\n  [%P1.Value{unit: \"kWh\", value: 123456.789}]\n]\n```\n\n## Documentation \n\nThe docs can be found at [https://hexdocs.pm/p1_parser](https://hexdocs.pm/p1_parser).\n\n## Contribute\n\n`|\u003e fork |\u003e feature branch |\u003e pull request`\n\n## Reference \n\nI used https://www.netbeheernederland.nl/_upload/Files/Slimme_meter_15_a727fce1f1.pdf as a reference\n\n## Todo's\n\n - ~~Parse units~~\n - ~~Parse Summer/Winter time information in timestamp~~\n - ~~return structs~~\n - ~~Convert timestamps to proper date/times~~\n - Parse entire telegram\n - Validate checksum\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgertjana%2Fp1_parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgertjana%2Fp1_parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgertjana%2Fp1_parser/lists"}