7 releases (breaking)

new 0.15.0 Mar 20, 2025
0.14.0 Nov 20, 2024
0.13.0 Mar 17, 2024
0.12.0 Mar 11, 2024
0.9.0 Mar 19, 2023

#360 in Asynchronous

Download history 16/week @ 2024-11-30 8/week @ 2024-12-07 9/week @ 2025-02-01 11/week @ 2025-02-08 2/week @ 2025-02-22 41/week @ 2025-03-01 6/week @ 2025-03-08 55/week @ 2025-03-15

104 downloads per month
Used in 2 crates

MIT/Apache

155KB
3K SLoC

Rust SSIP Client

license Crates.io Version

Speech Dispatcher SSIP client library in pure rust.

The API is synchronous by default.

A non-blocking API can be used with a low-level polling mechanism based on poll, or with mio. This fork also offers a working version using the tokio flag, or an occasionally working async-std flag.

  • Unix socket.
  • TCP socket.
  • Stop, cancel, pause and resume.
  • List, set voices.
  • Set rate, pitch, volume.
  • Notifications.
  • Message history.
  • tokio support.
  • async-std support.
    • If you're interested in helping us implement this, please reach out on Gituhb.

Getting Started

To use the synchronous API or an asynchronous API compatible with low-level crates based on poll, use:

[dependencies]
ssip-client-async = "0.9"

For the tokio API, use:

[dependencies]
ssip-client = { version = "0.9", features = ["tokio"] }

For use with the zbus DBus API, use the dbus feature.

Example

use ssip_client::{FifoBuilder, ClientName};
let mut client = fifo::Builder::new().build()?;
client
    .set_client_name(ClientName::new("joe", "hello"))?
    .check_client_name_set()?;
let msg_id = client.speak()?.send_line("hello")?.receive_message_id()?;
client.quit()?;

See other examples in the repository.

License

This software is distributed under the terms of both the MIT license and the Apache License (Version 2.0).

See LICENSE-APACHE and LICENSE-MIT for details.


lib.rs:

SSIP client

ssip-client implements a Speech Dispatcher SSIP client library in pure rust.

See client::Client for the synchronous API and poll::QueuedClient for the asynchronous API.

Example

use ssip_client_async::{fifo, ClientName};
let mut client = fifo::Builder::new().build()?;
client
    .set_client_name(ClientName::new("joe", "hello"))?
    .check_client_name_set()?;
let msg_id = client.speak()?.send_line("hello")?.receive_message_id()?;
client.quit()?;

Dependencies

~7–23MB
~280K SLoC