# Home Assistant Switch

Zdroj: https://docs.evcc.io/cs/smartswitches/home-assistant-switch

Home Assistant instances in your network will be auto-discovered and suitable entities (e.g. `switch.*`, `sensor.*`) will be suggested.

## Parametry

| Název | Popis | Výchozí / příklad | |
| --- | --- | --- | --- |
| uri | Home Assistant URI | http://homeassistant.local:8123 |  |
| switch | Entity ID of the switch device | switch.smartsocket |  |
| power | Entity ID for power measurement | sensor.smartsocket_power |  |
| standbypower | Standby power Power values above this value will be considered as charging power and hence status "charging". Negative values deactivate status detection. | 15 W |  |
| insecure | Accept self-signed certificates |  | pokročilé |
| temp | Entity ID for temperature measurement Heating devices only | sensor.heatpump_temperature | pokročilé |
| limittemp | Entity ID for temperature limit Limit configured in the device, heating devices only | sensor.heatpump_target_temperature | pokročilé |
| integrateddevice | Integrated device Integrated device. No charging sessions |  | pokročilé |
| heating | Heating device Shows °C instead of % |  | pokročilé |
| icon | Icon Will be displayed in the user interface (car, bike, bus, moped, motorcycle, rocket, scooter, taxi, tractor, rickshaw, shuttle, van, airpurifier, battery, bulb, climate, coffeemaker, compute, cooking, cooler, desktop, device, dishwasher, dryer, floorlamp, generic, heater, heatexchange, heatpump, kettle, laundry, laundry2, machine, meter, microwave, pump, smartconsumer, tool, waterheater) |  | pokročilé |

## Příklad konfigurace pro evcc.yaml

```yaml
chargers:
    - name: my_smartswitch
      type: template
      template: homeassistant-switch
      uri: http://homeassistant.local:8123 # Home Assistant URI
      switch: switch.smartsocket # Entity ID of the switch device
      power: sensor.smartsocket_power # Entity ID for power measurement, optional
      standbypower: 15 # Standby power (W), Power values above this value will be considered as charging power and hence status "charging". Negative values deactivate status detection. (optional)
      insecure: # Accept self-signed certificates, optional
      temp: sensor.heatpump_temperature # Entity ID for temperature measurement, Heating devices only (optional)
      limittemp: sensor.heatpump_target_temperature # Entity ID for temperature limit, Limit configured in the device, heating devices only (optional)
      integrateddevice: # Integrated device, Integrated device. No charging sessions (optional)
      heating: # Heating device, Shows °C instead of % (optional)
      icon: # Icon, Will be displayed in the user interface [car, bike, bus, moped, motorcycle, rocket, scooter, taxi, tractor, rickshaw, shuttle, van, airpurifier, battery, bulb, climate, coffeemaker, compute, cooking, cooler, desktop, device, dishwasher, dryer, floorlamp, generic, heater, heatexchange, heatpump, kettle, laundry, laundry2, machine, meter, microwave, pump, smartconsumer, tool, waterheater] (optional)
```
