New Netatmo climate component supporting multiple thermostats/valves

I think this has to be changed

from homeassistant.components.climate import (
    STATE_HEAT, STATE_IDLE, ClimateDevice, PLATFORM_SCHEMA,
    SUPPORT_TARGET_TEMPERATURE, SUPPORT_OPERATION_MODE, SUPPORT_AWAY_MODE)

becomes:

from homeassistant.components.climate import ( DOMAIN,
    ClimateDevice, PLATFORM_SCHEMA)
from homeassistant.components.climate.const import (
    STATE_HEAT, STATE_IDLE, SUPPORT_TARGET_TEMPERATURE, SUPPORT_OPERATION_MODE, SUPPORT_AWAY_MODE)

correct?

Could you explain how to integrate netatmo in 0.88?? Thankyou

He already explained it here:

You have do download the files from the links, rename them as he mentioned and place them in the folders.

So create a new folder in custom_componets “netatmo” and place those renamed files "init.py and climate.py in that folder.

Restart and you’re good to go.

thank you for the tip

I have this error on hass.io 0.87 could you help me?
thanks

019-02-22 12:21:14 ERROR (MainThread) [homeassistant.components.climate] Error while setting up platform netatmo
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity_platform.py", line 128, in _async_setup_platform
    SLOW_SETUP_MAX_WAIT, loop=hass.loop)
  File "/usr/local/lib/python3.6/asyncio/tasks.py", line 358, in wait_for
    return fut.result()
  File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/climate/netatmo.py", line 98, in setup_platform
    for room_id in room_data.get_room_ids():
  File "/config/custom_components/climate/netatmo.py", line 350, in get_room_ids
    if self.setup():
  File "/config/custom_components/climate/netatmo.py", line 363, in setup
    self.update()
  File "/usr/local/lib/python3.6/site-packages/homeassistant/util/__init__.py", line 315, in wrapper
    result = method(*args, **kwargs)
  File "/config/custom_components/climate/netatmo.py", line 386, in update
    self.homestatus.rooms[key]['therm_setpoint_temperature']

Thanks for writing this code, I really appreciate this !
(and it saves me a lot of time & work to try doing it myself :smiley: )

I installed the first 2 files, resulting in an error, and then added the changes for version 0.88
After step 2 my old UI-card was not available, and I could easily add cards for my thermostat and valves

3 questions though :

  • Do we have to remove the files again when the component has been included in HomeAssistant ?
  • Will the main files be updated for version 0.88, and do we have to remove the last 2 files manually then ?
  • Is there any more information available on the functions of the applet ? I can click a green leaf, eco, heat, cool, auto, manual, … but actually I don’t know what it does exactly :slight_smile:

Thanks again !
Steven

I have the same error but I use python3.7
Any succestion?

Error loading custom_components.netatmo.climate. Make sure all dependencies are installed

Traceback (most recent call last): File “/usr/local/lib/python3.7/site-packages/homeassistant/loader.py”, line 147, in _load_file module = importlib.import_module(path) File “/usr/local/lib/python3.7/importlib/init.py”, line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File “<frozen importlib._bootstrap>”, line 1006, in _gcd_import File “<frozen importlib._bootstrap>”, line 983, in _find_and_load File “<frozen importlib._bootstrap>”, line 962, in _find_and_load_unlocked ModuleNotFoundError: No module named ‘custom_components.netatmo.climate’; ‘custom_components.netatmo’ is not a package

Original post updated. I added files for HA 0.88, for those who still have issue please try as the updated procedure indicates, and let me know if you still have problems.

With 0.88 I got an error (or warning) when I used “homes” and “rooms”.
Don’t you get that too @Baosong_Shan?

  1. Yes, I will update this post when it is included.
  2. For 0.88, please follow the updated procedure.
  3. Green leaf (eco) corresponds “away mode” in Netatmo, blue snow (cool) => HG (frost guard), auto => schedule, heat => max.

No, I just tested, it works (case sensitive with room name). Please re-pull the latest version of __init__.py, because the first version had issue with operation modes.

If you put discovery to true, you don’t need an entry of netatmo under climate, otherwise you may get double entries.

I get this error when I use it like this (worked before):

climate:
  platform: netatmo
  home: house
  rooms:
    - bedroom
    - livingroom

Do we also need the homes structure when we only have one home, like this

climate:
  platform: netatmo
  homes:
    - name: house
      rooms:
        - bedroom
        - livingroom

Unfortunately, the format has to be followed no matter multiple homes or not.

Ok, did this change recently? Because the example above worked before.

Hi!

I have an issue with my config : two rooms, two relays (one by room), two thermostats (one by room/relay).

In the dashboard I see each thermostat two time, and the displayed temperatures are mixed (randomly!).

Here is my conf.yaml:
# Netatmo
netatmo:
api_key: !secret netatmo_api_key
secret_key: !secret netatmo_secret_key
username: !secret netatmo_username
password: !secret netatmo_password

climate:
  platform: netatmo
  homes:
    - name: Montfort
      rooms:
        - Bureau
        - Salon

HA dashboard:

And Netatmo dasboard: (there is a 0.1°C diff between HA and Netatmo, due to the update latency)

Any idea on what’s going on?

Mike

Try this @MickBru :

netatmo:
  api_key: !secret netatmo_api_key
  secret_key: !secret netatmo_secret_key
  username: !secret netatmo_username
  password: !secret netatmo_password
  discovery: false

Hi!

Discover is set to false, I now see only two item in HA dashboard.
But I still have the temperature issue:

Ok, first issue solves. Can’t help with the second, probably @Baosong_Shan

Well I can’t seem to get anything to work after upgrading to 0.88.2 and installing New Netatmo setup above.

Setting Discovery to True will find my termostats but the old “test-termostats” still appear on my Hassio Overview. I cannot figure out how this “home” and “room” setup is meant to be. Shouldn’t there be some kind of mapping between termostat room-id’s and room names?

May be an updated setup guide could help me and others.

What will have to be in the following folders?

  • \hassio\config\custom_components
  • \hassio\config\custom_components\climate
  • \hassio\config\custom_components\netatmo

Log is also showing this error: ThermostatData::setup() got error.

I hope I can get a clue how to get Netatmo Termostats up and running again.