MQTT Server
The open source Mosquitto MQTT server is included in the HEMS software distribution in a seperate docker container.
The Mosquitto server is available at 10.42.0.1:1883
Immersion Switch Integration
Shelly switches are used to add control to an existing immersion system. The Shelly integration and control is handled by MQTT rather than a custom component. This method was chosen as it provides autodiscovery and configuration.
The integration is handled by the shellies_discovery.py script as detailed on the HA Forum
Rest API based custom component integrations such as ShellyForHASS may also be investigated.
Install the hardware correctly.
Veryify that a new WiFi network is available -
shelly1-XXXXXX
Connect to this network and navigate your browser to
192.168.33.1
Verify that your Shelly switch is toggling as expected using the web interface
Change the Shelly WiFi configuration to use client mode, and connect it to the
ccoop-hems-xxx
network. The password is the Balena device name - you can find this by logging into BalenaCloud.
The Shelly will now restart in client mode and connect to the wifi network. Find the new IP address of the Shelly using
arp-scan
Under “Advanced - Developer Settings” enable MQTT.
Insert the Pi IP address in the server field, along with the MQTT port - it should always be
10.42.0.1:1883
Save the configuration.