Buy Me A Coffee
If you want the weekly version, you can find it here.(only in italian now)

Cronothermostat Package for Home Assistant.

Immagine cronotermostato

This package creates a series of entities and automations to make sure that the thermostat works in various modes that can be selected by the user and that it is possible to turn it on at certain times and whether or not you are at home. Let's see how to install it.

Prerequisites
Installation with climate entity no pre installated
Installation with climate entity installated
Card configuration
How it work

Prerequisites

To operate, it needs an already installed climate entity or 2 entities: a switch that activates and deactivates the thermostat and a temperature sensor.
To install this package you will need:
1. have configured the packages
2. install
button-card, card-mod, state-switch and attributes (from HACS)

Installation with climate entity not pre-installed

Download the chronothermostat-master.zip file (clone or download at the top right and then download zip) and unzip the files.
Copy the files in this way:
Pkg_cronotermostato_v1_3_6.yaml in the packages folder
blue.jpg, impostazioni.jpg and fiamma.gif in the folder www/images/lovelace /

Open the file Pkg_cronotermostato_v1_3_6.yaml and make the following changes:

  1. replace switch.sonoff_10004b541f with the switch that turns on the thermostat (line 33))
  2. replace sensor.sonoff_10004b541f_temperature with the temperature sensor (line 34)
  3. replace device_tracker.iphone7 with your device_tracker (line 35)
  4. replace the home zone with your own zone if it is different (line 36)
  5. replace the notification service with your own (line 37)
  6. if you already have the sensor.time, comment it (lines from 156 to 158)
  7. if you want a hysteresis, i.e. that the thermostat switches off at a higher temperature or that it switches on again at a lower temperature than the one set, you will have to change hot_tolerance and cold_tolerance. Example: setting the temperature to 23 and setting cold_tolerance to 2 and hot_tollerance to 0, the thermostat will turn off when it reaches 23 degrees and will turn back on at 21. By default, cold_tolerance: 0.5 and hot_tolerance: 0.
    Restart home assistant

Installation with climate entity already installed

Download the chronothermostat-master.zip file (clone or download at the top right and then download zip) and unzip the files
Copy the files in this way:
Pkg_cronotermostato_v1_3_6_no_climate.yaml in the packages folder
blu.jpg e fiamma.gif in the folder www/immagini/lovelace/

Open the file Pkg_cronotermostato_v1_3_6_no_climate.yaml and make the following changes:

  1. replace device_tracker.device with your device_tracker (line 32)
  2. replace the home zone with your own zone if it is different (line 33)
  3. replace the notification service with your own (line 34)
  4. replace climate thermostat with your own (line 35)
  5. if you already have the sensor.time, comment it (lines from 138 to 140)
    Restart home assistant

    For card configuration:

    For those who use raw mode, create a new card and copy the contents of lovelace_raw.yaml.
    For those who use the yaml mode, open the lovelace_yaml.yaml file and copy the content into your lovelace file.

How it work

Immagine cronotermostato

In the main card you will find a button at the top right to open the settings of the on and off times for the AUTO and PREHEATING mode, below you will find a leaf that opens the settings for the ECO mode, at the top left a gear to open the settings. In the center on the left there is the temperature of your sensor while on the right the set temperature that you can change with the 2 arrows that are positioned above and below of it; in the center it is indicated by a flame if the thermostat is currently on or off; below are the 5 operating modes; the selected mode will be highlighted in yellow.

Operating mode

The thermostat is configured to operate in 5 modes:

OFF: thermostat off.

MANUAL: thermostat on, does not take into account times and position.

AUTO: the thermostat switches on only if you are at home and if the time is between the set time intervals.

PRE: the thermostat turns on at the set time even if you are away from home.

ECO: set a lower temperature, ideal for the night or if you want to leave a lower temperature when you are not at home.

When the thermostat is on, in any mode except OFF, it will remain on until it reaches the set temperature and will turn on again if the temperature drops again.
ECO mode is automatically activated at the set time and then returns to the previous mode and the previous temperature once it arrives at the set time to switch off the ECO mode. You can also activate it manually by clicking on the ECO button. To deactivate it, simply choose a different mode and the previously set temperature will also return. If you want to deactivate ECO mode with the times set, you can do it from the settings menu.

Immagine cronotermostato

From the home page, clicking on the leaf at the top right, the eco mode settings menu will open.
Here you can enter the on and off times of the mode and the temperature to be set when this mode is activated.
By clicking on the arrow at the top right you will return to the home page.

From the home page, by clicking on the icon at the top right, the settings menu will open for switching on in AUTO and PREHEATING mode.
Here you can set the time for switching the thermostat on and off. There are 3 time bands with the possibility of disabling the last 2 in case you want to operate the thermostat with a mono-hourly or bi-hourly band; just click on/off above the band.
By clicking on the arrow at the top right you will return to the home page.

nuova impostazioni

From the home page, clicking on the gear at the top left, the thermostat settings menu will open.
From here you can choose whether or not to activate the ECO mode with the times set.
You can select the exit mode, when you are in AUTO mode and leave the house; there are 2 modes: OFF and ECO. The first turns off the thermostat to turn it back on when you return; the second leaves the thermostat on by lowering the temperature to the ECO temperature and then restoring the temperature before returning.
L'ultima ozione serve per scegliere se ricevere o meno un messaggio all'accensione del termostato.
For any problem write on the
forum.