Files
midea-meiju-codec/custom_components/midea_auto_cloud
Cyborg2017 2ac5880eb6 feat: add command template support for device control
- Add command field support to MideaNumberEntity and MideaSelectEntity
- Command templates allow defining fixed parameters in configuration
- Options/values are merged with command template before sending to device
- Backward compatible - existing configurations continue to work

Examples in device_mapping:

1. For NUMBER platform - brightness control with protocol template:
```yaml
Platform.NUMBER: {
    "lightness": {
        "min": 10,
        "max": 100,
        "step": 5,
        "command": {
            "electronic_control_version": 2,
            "type": "b6",
            "b6_action": "setting",
            "setting": "light",
            "lightness": "{value}"  # {value} placeholder for actual number value
        }
    }
}

2.For SELECT platform - gesture selection with protocol template:
```yaml
Platform.SELECT: {
    "gesture": {
        "options": {
            "off": {"gesture": "off"},
            "on": {"gesture": "on"}
        },
        "command": {  # Protocol template for gesture control
            "electronic_control_version": 2,
            "type": "b6",
            "b6_action": "setting",
            "setting": "gesture"
            # {gesture} value from options will be merged automatically
        }
    }
}
2026-01-07 11:22:04 +08:00
..
2025-10-16 00:27:04 +08:00
2025-10-14 20:37:39 +08:00
2026-01-05 20:27:12 +08:00