Then you would use smart lighting to mirror each speed of the fan controller to a separate virtual switch. You would have 4 virtual switches. You would turn the virtual switch on/off and then use an automation within smart lighting to mirror the fan speed to the virtual switch. You would need an automation for each speed/virtual switch.