Add MOS gate control via select entity
Adds a Select entity with four options (Normal / Charge Disabled / Discharge Disabled / Both Disabled) that sends the 0xE1 write command to the BMS and immediately refreshes sensor state. Current option is derived from the mos_charge_enabled / mos_discharge_enabled bits already parsed on every poll. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -7,7 +7,7 @@ from homeassistant.core import HomeAssistant
|
||||
from .const import CONF_ADDRESS, CONF_POLL_INTERVAL, DEFAULT_POLL_INTERVAL, DOMAIN
|
||||
from .coordinator import BmsCoordinator
|
||||
|
||||
PLATFORMS = ["sensor", "binary_sensor", "number"]
|
||||
PLATFORMS = ["sensor", "binary_sensor", "number", "select"]
|
||||
|
||||
|
||||
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
||||
|
||||
Reference in New Issue
Block a user