This was a fun challenge (and a total hack). In the end it wasn’t that sophisticated, but it was a good exercise in UDP as well as data compression.
I made public tonight a repo I’ve had for a while that contains BeamNG experiments.
I was looking for a way to segment some IoT devices from my main network and disable their network connections on demand programmatically. The Guest Network feature on the router does a good job of segmenting the network, so I wanted a way to turn the guest network’s interface off and on based upon conditions.
Example scenario: You have cloud-based IoT cameras and want to cease all traffic when you’re home.
This puts toggling any interface on the router behind an HTTP endpoint. Since an interface is created when a guest network is enabled, we can now enable and disable that network whenever we want.
See the GitHub repo for a parts list, wiring diagram, and Arduino code.