Implementation of the Denon HEOS CLI Protocol.
Just clone the repository and install the crate as usual:
$ git clone https://github.com/Holzhaus/heos-rs.git
$ cd heos-rs
$ cargo install --path .Don't forget to make sure that your $PATH includes $HOME/cargo/bin.
You can run this as a command line tool.
To discover available HEOS servers via SSDP, you can run the discover subcommand.
$ heos discover
192.168.0.100Actual HEOS protocol request can be sent using the send subcommand.
For example, you can check if your hardware is signed into the HEOS account by running:
$ heos send --server 192.168.0.100 check-account
SignedIn = "[email protected]"If you do not specify the --server argument, the tool will try to discover servers automatically and then connect to the first server found.
You can also build your own software by using this crate as a library.
Make sure that the cli feature is disabled to avoid unnecessary dependencies.
$ cargo add heos --no-default-featuresIn your code, you need to connect to a server before you can start sending commands:
use heos::Server;
// Connect to server with known IP. Alternatively, you can use
// `heos::discover()` to discover servers via SSDP.
let server = Server::from("192.168.0.100".to_string());
let mut stream = server.connect().await.unwrap();
// Now we can start sending requests..
let response = stream.check_account().await.unwrap();
dbg!(&response);This software is [licensed][license] under the terms of the Mozilla Public License 2.0. Please also have a look at the license FAQ.
- HEOS CLI Protocol Specification v1.17 (2021-10-11)