{"id":22352081,"url":"https://github.com/bertreb/pimatic-smartmeter3","last_synced_at":"2025-06-12T03:35:17.534Z","repository":{"id":57324280,"uuid":"209117157","full_name":"bertreb/pimatic-smartmeter3","owner":"bertreb","description":"Pimatic smartmeter energy reader","archived":false,"fork":false,"pushed_at":"2020-08-04T12:52:33.000Z","size":40,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-30T02:04:08.910Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"CoffeeScript","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/bertreb.png","metadata":{"files":{"readme":"README.md","changelog":"HISTORY.md","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":"2019-09-17T17:31:18.000Z","updated_at":"2020-08-04T12:52:36.000Z","dependencies_parsed_at":"2022-09-21T00:55:02.414Z","dependency_job_id":null,"html_url":"https://github.com/bertreb/pimatic-smartmeter3","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/bertreb/pimatic-smartmeter3","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bertreb%2Fpimatic-smartmeter3","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bertreb%2Fpimatic-smartmeter3/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bertreb%2Fpimatic-smartmeter3/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bertreb%2Fpimatic-smartmeter3/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bertreb","download_url":"https://codeload.github.com/bertreb/pimatic-smartmeter3/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bertreb%2Fpimatic-smartmeter3/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259390250,"owners_count":22850197,"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","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":[],"created_at":"2024-12-04T12:17:04.958Z","updated_at":"2025-06-12T03:35:17.487Z","avatar_url":"https://github.com/bertreb.png","language":"CoffeeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"pimatic-smartmeter3\n===================\n\nReading \"Smartmeter\" energy (electricity and gas) usage through P1 port.\nThis plugin is a based on the smartmeter versions of saberone and rick00001. \nThis plugin supports serialport version 6 (node v4 and v8) and gives the possibility to read ascii based Datagrams from Smartmeters (like the DSMR). You can change the regex formulas for the energy values in the device config. \nIf this plugin doesn't fit, you could use the more advanced pimatic-smartmeter-obis plugin (https://github.com/bertreb/pimatic-smartmeter-obis).\n\nInstallation\n------------\nTo enable the smartmeter plugin add this to the plugins in the config.json file.\n\n```\n...\n{\n  \"plugin\": \"Smartmeter3\"\n}\n...\n```\n\nand add the following to the devices\n\n```\n{\n  \"id\": \"smartmeter3\",\n  \"class\": \"Smartmeter3Device\",\n  \"name\": \"smartmeter3\",\n  \"serialport\": \"/dev/ttyUSB0\",\n  \"baudRate\" : 115200,\n  \"dataBits\" : 8,\n  \"parity\" : \"none\",\n  \"stopBits\" : 1,\n  \"flowControl\" : true\n}\n```\n\nThen install through the standard pimatic plugin install page.\n\n\nConfiguration\n-------------\nYou can configure what serialport to use and the serialport settings.\n\nThe device provides the following 4 variables:\n- $\\\u003cdevice id\\\u003e.actualusage (Actual usage in Watt)\n- $\\\u003cdevice id\\\u003e.tariff1totalusage (Tariff 1 total usage in kWh) \n- $\\\u003cdevice id\\\u003e.tariff2totalusage (Tariff 2 total usage in kWh) \n- $\\\u003cdevice id\u003e\\.gastotalusage (Gas total usage in m3) \n\nThe number of decimals in de Gui can be changed via xAttributeOptions.\n\nDifferent smartmeter versions\n---------------------------------------\nThe current version has been tested with a DSMR5.0 smartmeter.\nIf your smartmeter version uses different data field you can change the RegEx in de device config to meet your smartmeter.\n\nA simple commandline tool can help to get your smartmeter data and build your RegExp. \nThe tool is a node.js app/tool that dumps the P1 data straight to a file. \n\nRun the following commands from the root of this plugin.\n\n```\nnpm install\nchmod +x logP1.js\n./logP1.js\n```\n\nRegEx configuration\n---------------------------------------\nBelow the 5 customizable Regular Expression (RegEx) fields in the config.json device section. The RegEx is used to filter out the specific data. A RegEx string need double backslashes (escape character in strings). If you edit the RegEx in the Gui Device page, you can use the normal single backslashes.\n\n```\n{\n  \"t1TotalUsage\": \"^1-0:1\\\\.8\\\\.1\\\\(0+(\\\\d+\\\\.\\\\d+)\\\\*kWh\\\\)\",\n  \"t2TotalUsage\": \"^1-0:1\\\\.8\\\\.2\\\\(0+(\\\\d+\\\\.\\\\d+)\\\\*kWh\\\\)\",\n  \"activeTariff\": \"^0-0:96.14.0\\\\(0+(.*?)\\\\)\",\n  \"actualUsage\": \"^1-0:1.7.0\\\\((.*?)\\\\*\",\n  \"gasTotalUsage\" : \"^0-1:24\\\\.2\\\\.1\\\\(\\\\d{12}.\\\\)\\\\(0+(\\\\d+\\\\.\\\\d+)\\\\*m3\\\\)\"\n}\n```\n \nIf you have issues, please create an issue overe here : https://github.com/bertreb/pimatic-smartmeter3/issues\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbertreb%2Fpimatic-smartmeter3","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbertreb%2Fpimatic-smartmeter3","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbertreb%2Fpimatic-smartmeter3/lists"}