OK, thanks for your explanation.
The HLC-Topics are created on my correct mqtt-broker.
Maybe I should alter my question more precisely:
Should something happen inside these topics, wenn HLC is active?
If not, what must be sent (for example) with the topic " mqtt.0.hermes.leds.onMessage" that sometings happen with the LED-ring?
Nothing have to be sent to have the led on when service starts.
HLC doesn’t send anything on mqtt, it just listen on some topics to give a visual feedback.
And once more, actual version of rhasspy doesn’t publish every hermes topics so it doesn’t work actually. Just get the led on, I get the wakeword detected animation, but after that nothing, it stay in this state until I restart the service.
So, pretty unusable with actual rhasspy, but having it set on the rpi, it should begin to work without doing anything when we update to rhasspy version with all hermes topics.
Is HermesLedControl working on an docker install of rhasspy ?
I got this error after the installation of HLC
Jun 11 18:23:57 raspberrypi systemd[1]: Started Hermes Led Control.
Jun 11 18:23:58 raspberrypi python3[1293]: Starting Hermes Led Control v. 2.0.6
Jun 11 18:23:58 raspberrypi python3[1293]: Initializing HermesLedControl
Jun 11 18:23:58 raspberrypi python3[1293]: Initializing Rhasspy settings
Jun 11 18:23:58 raspberrypi python3[1293]: Loading configurations
Jun 11 18:23:58 raspberrypi python3[1293]: Error loading configurations: 'mqtt'
Jun 11 18:23:58 raspberrypi systemd[1]: hermesledcontrol.service: Succeeded.
Jun 11 18:24:01 raspberrypi systemd[1]: Started Session c2 of user pi.
Jun 11 18:24:03 raspberrypi systemd[1]: hermesledcontrol.service: Service RestartSec=5s expired, scheduling restart.
Jun 11 18:24:03 raspberrypi systemd[1]: hermesledcontrol.service: Scheduled restart job, restart counter is at 18.
Jun 11 18:24:03 raspberrypi systemd[1]: Stopped Hermes Led Control.
Did we have to install mosquito or something else ?
I’m not quite sure. But with a separate mqtt broker you will be on the safe side, also for any future application. It requires nearly no resources. Just do a simple linux installation since this is the easiest way. Not in docker since configuration is more complicated.
You can. You just need to map the ports from your rhasspy docker or , if you are deploying hermes_led_control as a docker container aswell, just link them in a docker compose file for example.
That will expose the internal mqtt broker.
You can find an example for Node-RED and Rhasspy here. The same method works for linking other containers: they’re all in the same virtual network that Docker Compose creates and they can reach each other by their container name on their exposed ports.
I would like to know if there is a way to change the idle led status/animation trough MQTT ?
I yould like my automation system (Jeedom) to send various status to rhasspy/hermesLedControl by lighting the led with different patterns.
for example, if a mail was detected in my mail box light in yellow …
in red if my security alarm is activated…
For anyone interested to get it running with the rhasspy docker image, the integrated MQTT broker and the HLC installscript, I’m using this docker-compose.yml for Rhasspy:
The additional port is what you might mostly be interested in.
Additionally you need to tell HLC the MQTT target. Unfortunately it’s not possible to specify no config file. So I simply created a profile.json in HLC’s main folder:
Normally this configuration is being read from the profile.json of rhasspy. But if you’re using the internal broker there’s no MQTT section being written to the profile.json.
And last but not least this is my adjusted systemd unit file I’m using:
[Unit]
Description=Hermes Led Control
[Service]
WorkingDirectory=/home/pi/hermesLedControl_v2.0.9
ExecStart=/home/pi/hermesLedControl_v2.0.9/venv/bin/python3 main.py --pathToConfig=profile.json --engine=rhasspy --hardware=respeaker2 --pattern=projectalice
Restart=always
RestartSec=5
User=pi
[Install]
WantedBy=multi-user.target
Hello,
I made modification inside the code to add a new topic to change idle status dynamically.
For now I’m able to set an animation or pattern for idle Status (and change it) through MQTT.
I also modify the Breath animation to pass it severals colors, and also to add a sleep after all (or one) color breath.
This helped me to get it working with my Respeaker 4. The shell script in the wiki did not work on my raspberry pi4 and was not creating the configuration correctly.
I manually created a folder under pi/home/hermesLedControl with a configuration.yml file and the profile.json example that you provided. Added the link to profile.json in the config file:
pathToConfig=‘profile.json’
Opened the 12183 port of the Rhasspy image in docker and those lovely LEDS came into action.
Spent so much time on it this weekend and had almost given up home so thank you!