Repository navigation
Device Feature Management
Ramses Extras supports per-device feature management, allowing users to enable features only for specific devices.
Internally:
-
DeviceFeatureMatrixstores which devices have which features enabled. -
SimpleEntityManagerorchestrates entity lifecycle based on that matrix.
Each feature can specify which device types it supports using
allowed_device_slugs.
Example:
AVAILABLE_FEATURES = {
"humidity_control": {
"allowed_device_slugs": ["FAN"],
# ...
},
"hello_world": {
"allowed_device_slugs": ["*"],
# ...
},
}The DeviceFeatureMatrix tracks which features are enabled for which devices.
High-level usage:
matrix.enable_feature_for_device("fan_device_1", "humidity_control")
features = matrix.get_enabled_features_for_device("fan_device_1")
# Returns: {"humidity_control": True}Users can enable features for specific devices through the config flow:
- Select features.
- For each feature, select which devices to enable it for.
- Confirm the changes.
- The system creates entities only for the selected device/feature combinations.
The generic feature selection step exists, but the actual entity lifecycle flows
through SimpleEntityManager.validate_entities_on_startup() and
SimpleEntityManager.calculate_entity_changes().
The matrix state is stored in the Home Assistant config entry under the
device_feature_matrix key so configuration persists across restarts.
Back to: Home Prev: Framework Foundation Next: Entity Management
- Feature Catalog
- CO2 Control
- Humidity Control (Balance)
- Temp Control (Bypass)
- FAN Configuration (Sensor Control)
- HVAC Fan Card
- Ramses Debugger
-
Device Simulator -
⚠️ Use only on dedicated system/container - Default Feature
- Hello World (Developer Example)