I know this is an old thread, but it’s still useful. I too am converting away from my horrid Xfinity system and repurposing the devices it came with. I was able to get my device working using your method, but have stumbled upon an interesting issue.
When I connect the switchable outlet to a device with a passive power source, the backflow of power is apparently kicking the switch to remain “on.” Since these switches (according to others) use older code relating to HA1.2 you could think maybe this is just a hardware limitation, but this was being used with my Xfinity system the same way, connected to the same device, yet when I turned the attached device off - it stayed off.
I’ve done some troubleshooting and can affirm it only misbehaves when something that has a capacitor/battery is attached… i.e. USB charger and a phone. When the USB charger is plugged into the outlet with a USB cord attached the device works correctly. The moment a phone is plugged into the USB the switch will only briefly turn off and then kick back “on” by itself after 2-5 seconds.
With my application, I am using it to power a doggie cam in a bathroom where I keep my pets when I’m not home. Ideally, I’d like the camera to stay off until I leave home - so by leaving my home the outlet will trigger on, and I have a camera to see my dogs. Since the camera is in a bathroom, having a permanently powered-on camera is not cool. This camera is a newer camera that’s micro USB powered. It does not have a battery, but it likely has a capacitor on the devices mobo. I’ve tested multiple USB chargers, cables, and devices and the only thing that remains consistent is devices that have a secondary, passive power source.
TIA for any input.