Missing local device groups feature
Posted: Thu Jun 10, 2021 12:28 pm
Device groups should work on the LAN without needing the cloud. The simplest example of this is putting light bulbs into a group. If I tell that group to turn off/on that should happen instantly on the LAN without needing to travel to the cloud and then have the cloud change each bulb individually. So set the group status locally using the LAN first -- and then let the cloud catch up on the status.
This can be implemented with distributed MQTT. Distributed MQTT is really simple. All of the devices on the LAN watch a multicast address and then you simply broadcast the MQTT commands to that address. The devices look at the MQTT commands and then execute the applicable ones. To secure this encrypt the messages and generate a unique key for each LAN.
For example...
Flip switch
Multicast MQTT - Group A on
everyone sees the multicast
Members of Group A turn on
now update the new status in the cloud.
See how this hides the cloud lag? It also works if the Internet is down. Multicast is not routable so these messages never leave the LAN. You also can't hack from outside since you can't generate Multicast externally either. And the multicast is encrypted with unique key per LAN so someone on the LAN can't hack.
This can be implemented with distributed MQTT. Distributed MQTT is really simple. All of the devices on the LAN watch a multicast address and then you simply broadcast the MQTT commands to that address. The devices look at the MQTT commands and then execute the applicable ones. To secure this encrypt the messages and generate a unique key for each LAN.
For example...
Flip switch
Multicast MQTT - Group A on
everyone sees the multicast
Members of Group A turn on
now update the new status in the cloud.
See how this hides the cloud lag? It also works if the Internet is down. Multicast is not routable so these messages never leave the LAN. You also can't hack from outside since you can't generate Multicast externally either. And the multicast is encrypted with unique key per LAN so someone on the LAN can't hack.