OK, I spend a bit more time on this and with the help of one of the Gurus over at the German homebridge forum got this up and running in no time. I can now control Play / Pause / Repeat Track, Previous Track, Next Track etc. for each zone via Siri
The problems I had before related to the fact, that I did not install the roon-exptension-http-api as a system service that stays alive all the time - just like my homebridge.
The install description here https://github.com/st0g1e/roon-extension-http-api is not describing the final - and most important - step of making that API run permanent. Probably assuming everybody knows this…
Here is how I got there:
Prerequisites:
- A running homebridge installation on Rapsi, NAS or wherever.
- This means that node.js is already installed as this is also used for homebridge, no need to install again.
Then follow the description https://github.com/st0g1e/roon-extension-http-api to copy and install the API. Test it in a browser as described. I used the “Pause” command for testing.
Assuming your test is successful, make the API run permanently as follows:
Create a service file. I called it roon-extension:
sudo nano /etc/systemd/system/roon-extension.service
In the nano editor, paste the following lines:
[Unit]
Description=Roon Extension
After=network-online.target
Wants=network-online.target
[Service]
User=pi
WorkingDirectory=/home/pi/Roon
ExecStart=/usr/local/bin/node server.js
Restart=on-failure
RestartSec=5
[Install]
WantedBy=multi-user.target
The WorkingDirectory is the directory where you installed the API. Correct the path accordingly. For me that path was the one you see above.
Once you pasted the above and are sure the WorkingDirectory is pointing correctly, save the file. This gets you back to command line.
Tpye:
sudo systemctl daemon-reload
and then:
sudo systemctl restart roon-extension; sudo journalctl -fau roon-extension
You should now see something like this on your terminal screen:
Jun 06 14:51:30 homepi systemd[1]: Started Roon Extension.
Jun 06 14:51:31 homepi node[14612]: Listening on port: 3001
If you get his, you can exit that dialog (CTRL+C), get back on the commandline and enter one final command to start the service automatically every time the Raspi gets rebooted:
sudo systemctl enable roon-extension
DONE! All you need to do now is to install the https://www.npmjs.com/package/homebridge-http-switch on your homebridge (if it isn’t already installed), edit your config.json and create a stateless switch for every command you want to have in homebridge.
Reboot homebridge and Roon and Siri will be able to talk to each other!