UPDATE June 2022: The Shelly Pro 4PM has received its Australian certification!
For years I’ve been running my home automation switchboards using “temporary” controllers using Ethernet-enabled Arduino boards controlling DIN-rail mounted relays. My hope was that some day, someone would release a DIN-rail mounted control system with wired connectivity.
And now, all these years later, Allterco have done it. The new Shelly Pro 4PM looks like exactly the device I’ve been waiting for.
Disclosure: Allterco sent me this pre-release unit free of charge. However, I have personally paid for Shellys in the past and I’m sure I will in future. They had no input into this video, which is my own honest assessment of the Pro 4PM.
Resources
- Shelly “Pro” range overview
- Shelly Pro 4PM
- SuperHouse #24: Home automation system architecture
- SuperHouse #34: Science or sorcery? Sonoff T4EU1C no-neutral wifi touch switch
MQTT control
The Shelly Pro 4PM supports MQTT control out of the box. All you need to go is go into the MQTT configuration menu, put in the details for your broker, and it will be ready to go.
The MQTT topics are based on the device ID of the specific Shelly module, but converted to lower case. You can find the ID by opening the web interface and looking at the bottom:
The topic for sending commands to the Shelly is of the form:
shellypro4pm-<device_id>/rpc
So based on the device ID in the screenshot above, you can see the command topic would be:
shellypro4pm-84cca87e4a80/rpc
Messages are sent and received as JSON. To turn on an output, send a message to the command topic of the form:
{"id":1, "src":"user_1", "method":"Switch.Set", "params":{"id":0, "on":true}}
This example turns on the first channel, because in the “params” section it has the ID set to 0 and the “on” value set to “true”. To turn off the first channel, change the “on” value to “false”.
Turn control the second channel, use the id “1”, and so on.
To see events published by the Shelly, including when channels change state and how much power each device is using, subscribe to the topic of the form:
shellypro4pm-<device_id>/events/rpc