{"id":15024128,"url":"https://github.com/mjkillough/sioctl-rs","last_synced_at":"2025-06-30T06:08:26.170Z","repository":{"id":57667530,"uuid":"259142739","full_name":"mjkillough/sioctl-rs","owner":"mjkillough","description":"Rust bindings around OpenBSD's sndio/sioctl_*.","archived":false,"fork":false,"pushed_at":"2020-05-28T17:52:44.000Z","size":12,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-12T18:49:23.156Z","etag":null,"topics":["audio","openbsd","rust","sioctl","sndio","sound"],"latest_commit_sha":null,"homepage":null,"language":"Rust","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/mjkillough.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":"2020-04-26T22:03:12.000Z","updated_at":"2024-11-04T06:30:06.000Z","dependencies_parsed_at":"2022-09-02T13:25:45.294Z","dependency_job_id":null,"html_url":"https://github.com/mjkillough/sioctl-rs","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/mjkillough/sioctl-rs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mjkillough%2Fsioctl-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mjkillough%2Fsioctl-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mjkillough%2Fsioctl-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mjkillough%2Fsioctl-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mjkillough","download_url":"https://codeload.github.com/mjkillough/sioctl-rs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mjkillough%2Fsioctl-rs/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262720641,"owners_count":23353450,"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":["audio","openbsd","rust","sioctl","sndio","sound"],"created_at":"2024-09-24T19:59:50.005Z","updated_at":"2025-06-30T06:08:26.097Z","avatar_url":"https://github.com/mjkillough.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sioctl-rs\n\nAn interface for reading the state of [`sndio`] controls.\n\nThis crate provides a wrapper around the [`sioctl_open(3)`] APIs for reading\nand watching the state of [`sndio`] controls.\n\nAn inteface to the defautl [`sndio`] device can be opened by\n[`Sioctl::new()`]. The initial state of controls can be read by calling\n[`Sioctl::controls()`] and callbacks for subsequent changes can be requested\nvia [`Sioctl::watch()`].\n\nThere is currently way to set the value of controls. If this would be useful\nto you, please feel free to submit a PR.\n\n[`sndio`]: http://www.sndio.org/\n[`sioctl_open(3)`]: https://man.openbsd.org/sioctl_open.3\n[`Sioctl::new()`]: struct.Sioctl.html#method.new\n[`Sioctl::controls()`]: struct.Sioctl.html#method.controls\n[`Sioctl::watch()`]: struct.Sioctl.html#method.watch\n\n## Example\n\n```rust\nuse sioctl::Sioctl;\n\nfn main() {\n    let s = Sioctl::new();\n\n    // Initial state of all controls.\n    for control in s.controls() {\n        println!(\"{:?}\", control);\n    }\n\n    // Watch for changes to all controls:\n    let mut watcher = s.watch(|control| println!(\"{:?}\", control));\n\n    // ...\n\n    // When done, call join() to shutdown watching.\n    watcher.join();\n}\n```\n\nA more complete example is available in [`src/bin/sioctl.rs`].\n\n[`src/bin/sioctl.rs`]: https://github.com/mjkillough/sioctl-rs/blob/master/src/bin/sioctl.rs\n\n## Installation\n\nThe `sndio-sys` crate requires `libclang.so` which is present in the `llvm` package:\n\n```\ndoas pkg_add llvm\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmjkillough%2Fsioctl-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmjkillough%2Fsioctl-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmjkillough%2Fsioctl-rs/lists"}