{"id":27382093,"url":"https://github.com/lukaskirner/tokio-sunspec","last_synced_at":"2025-04-13T15:26:59.517Z","repository":{"id":98096813,"uuid":"583120777","full_name":"lukaskirner/tokio-sunspec","owner":"lukaskirner","description":"A tokio-based SunSpec library ","archived":false,"fork":false,"pushed_at":"2023-03-22T14:31:23.000Z","size":67,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-12T15:51:26.533Z","etag":null,"topics":["client","library","modbus","non-blocking","rust","sunspec","tokio"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lukaskirner.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2022-12-28T20:38:56.000Z","updated_at":"2023-07-28T12:15:46.000Z","dependencies_parsed_at":"2024-01-16T00:18:43.253Z","dependency_job_id":null,"html_url":"https://github.com/lukaskirner/tokio-sunspec","commit_stats":{"total_commits":26,"total_committers":3,"mean_commits":8.666666666666666,"dds":"0.15384615384615385","last_synced_commit":"b28f7368ce23022d21049bc55abe8c7ddefb2a02"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukaskirner%2Ftokio-sunspec","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukaskirner%2Ftokio-sunspec/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukaskirner%2Ftokio-sunspec/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukaskirner%2Ftokio-sunspec/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lukaskirner","download_url":"https://codeload.github.com/lukaskirner/tokio-sunspec/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248734468,"owners_count":21153210,"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":["client","library","modbus","non-blocking","rust","sunspec","tokio"],"created_at":"2025-04-13T15:26:59.001Z","updated_at":"2025-04-13T15:26:59.506Z","avatar_url":"https://github.com/lukaskirner.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tokio-sunspec\n\nA pure [Rust](https://www.rust-lang.org)\n[SunSpec](https://en.wikipedia.org/wiki/SunSpec) library\nbased on [tokio](https://tokio.rs).\n\n[![Crates.io](https://img.shields.io/crates/v/tokio-sunspec.svg)](https://crates.io/crates/tokio-sunspec)\n[![Apache 2.0 licensed](https://img.shields.io/badge/license-Apache%202.0-blue.svg)](./LICENSE)\n\n## Features\n\n- [x] Pure Rust library\n- [x] Non-blocking\n- [x] TCP Client\n- [x] RTU Client\n- [x] Model discovery\n- [x] Type safe SunSpec models\n- [ ] Repeating models\n\n## Installation\n\n```toml\n[dependencies]\ntokio-sunspec = \"*\"\n```\n\n## Examples\n\nThe `src/models/` folder contains all pre generated models which may be available by the device. If you need to add your own model you can generate one with included Python script in the `scripts` folder.\n\n### TCP Connect example for SMA Inverter\n\n```rust\nlet socket_addr = \"\u003cip-address\u003e:502\".parse().unwrap();\nlet device_id: u8 = 126;\nlet start_addr: u16 = 40000;\n\nlet mut client = tokio_sunspec::connect_tcp(socket_addr, device_id, start_addr).await?;\n\nlet res = client.read_point(model1::Mn).await?;\nassert_eq!(res, \"SMA\");\n```\n\n## Protocol-Specification\n\n- [SunSpec Information Model Specification (PDF)](https://sunspec.org/wp-content/uploads/2015/06/SunSpec-Information-Models-12041.pdf)\n\n## Fruther notice\n\nThis lib only implements the SunSpec part. The connection via modbus is done by the [tokio-modbus](https://github.com/slowtec/tokio-modbus) lib.\n\n## License\n\nCopyright (c) 2023 Lukas Kirner\n\n[Apache-2.0](LICENSE.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flukaskirner%2Ftokio-sunspec","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flukaskirner%2Ftokio-sunspec","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flukaskirner%2Ftokio-sunspec/lists"}