Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.shelly.coordinator Namespace Reference

Classes

class  ShellyBlockCoordinator
 
class  ShellyCoordinatorBase
 
class  ShellyEntryData
 
class  ShellyRestCoordinator
 
class  ShellyRpcCoordinator
 
class  ShellyRpcPollingCoordinator
 

Functions

None __init__ (self, HomeAssistant hass, ShellyConfigEntry entry, _DeviceT device, float update_interval)
 
bool _async_device_connect_task (self)
 
None _async_reload_entry (self)
 
None _handle_ha_stop (self, Event _event)
 
None async_reconnect_soon (HomeAssistant hass, ShellyConfigEntry entry)
 
None async_setup (self, list[Platform]|None pending_platforms=None)
 
None async_shutdown_device_and_start_reauth (self)
 
ShellyBlockCoordinator|None get_block_coordinator_by_device_id (HomeAssistant hass, str device_id)
 
ShellyRpcCoordinator|None get_rpc_coordinator_by_device_id (HomeAssistant hass, str device_id)
 
str mac (self)
 
str model (self)
 
None shutdown (self)
 
int sleep_period (self)
 
str sw_version (self)
 

Variables

 _came_online_once
 
 _pending_platforms
 
 device
 
 device_id
 
 entry
 
 last_update_success
 
 ShellyConfigEntry
 

Detailed Description

Coordinators for the Shelly integration.

Function Documentation

◆ __init__()

None homeassistant.components.shelly.coordinator.__init__ (   self,
HomeAssistant  hass,
ShellyConfigEntry  entry,
_DeviceT  device,
float  update_interval 
)
Coordinator for a Shelly device.
Initialize the Shelly device coordinator.

Definition at line 97 of file coordinator.py.

◆ _async_device_connect_task()

bool homeassistant.components.shelly.coordinator._async_device_connect_task (   self)
private
Connect to a Shelly device task.

Definition at line 175 of file coordinator.py.

◆ _async_reload_entry()

None homeassistant.components.shelly.coordinator._async_reload_entry (   self)
private
Reload entry.

Definition at line 219 of file coordinator.py.

◆ _handle_ha_stop()

None homeassistant.components.shelly.coordinator._handle_ha_stop (   self,
Event  _event 
)
private
Handle Home Assistant stopping.

Definition at line 170 of file coordinator.py.

◆ async_reconnect_soon()

None homeassistant.components.shelly.coordinator.async_reconnect_soon ( HomeAssistant  hass,
ShellyConfigEntry  entry 
)
Try to reconnect soon.

Definition at line 848 of file coordinator.py.

◆ async_setup()

None homeassistant.components.shelly.coordinator.async_setup (   self,
list[Platform] | None   pending_platforms = None 
)
Set up the coordinator.

Definition at line 149 of file coordinator.py.

◆ async_shutdown_device_and_start_reauth()

None homeassistant.components.shelly.coordinator.async_shutdown_device_and_start_reauth (   self)
Shutdown Shelly device and start reauth flow.

Definition at line 225 of file coordinator.py.

◆ get_block_coordinator_by_device_id()

ShellyBlockCoordinator | None homeassistant.components.shelly.coordinator.get_block_coordinator_by_device_id ( HomeAssistant  hass,
str   device_id 
)
Get a Shelly block device coordinator for the given device id.

Definition at line 808 of file coordinator.py.

◆ get_rpc_coordinator_by_device_id()

ShellyRpcCoordinator | None homeassistant.components.shelly.coordinator.get_rpc_coordinator_by_device_id ( HomeAssistant  hass,
str   device_id 
)
Get a Shelly RPC device coordinator for the given device id.

Definition at line 828 of file coordinator.py.

◆ mac()

str homeassistant.components.shelly.coordinator.mac (   self)
Mac address of the device.

Definition at line 135 of file coordinator.py.

◆ model()

str homeassistant.components.shelly.coordinator.model (   self)
Model of the device.

Definition at line 130 of file coordinator.py.

◆ shutdown()

None homeassistant.components.shelly.coordinator.shutdown (   self)
Shutdown the coordinator.

Definition at line 166 of file coordinator.py.

◆ sleep_period()

int homeassistant.components.shelly.coordinator.sleep_period (   self)
Sleep period of the device.

Definition at line 145 of file coordinator.py.

◆ sw_version()

str homeassistant.components.shelly.coordinator.sw_version (   self)
Firmware version of the device.

Definition at line 140 of file coordinator.py.

Variable Documentation

◆ _came_online_once

homeassistant.components.shelly.coordinator._came_online_once
private

Definition at line 113 of file coordinator.py.

◆ _pending_platforms

homeassistant.components.shelly.coordinator._pending_platforms
private

Definition at line 151 of file coordinator.py.

◆ device

homeassistant.components.shelly.coordinator.device

Definition at line 106 of file coordinator.py.

◆ device_id

homeassistant.components.shelly.coordinator.device_id

Definition at line 164 of file coordinator.py.

◆ entry

homeassistant.components.shelly.coordinator.entry

Definition at line 105 of file coordinator.py.

◆ last_update_success

homeassistant.components.shelly.coordinator.last_update_success

Definition at line 229 of file coordinator.py.

◆ ShellyConfigEntry

homeassistant.components.shelly.coordinator.ShellyConfigEntry

Definition at line 89 of file coordinator.py.