Adding support for Netatmo Thermostat

Shall I put this file too (now there is none)??

No, this was only for me, changes for the presence.

yes the values are back.

As usual only one thermostat is working

https://github.com/gieljnssns/My_Home-Assistant/tree/master/homeassistant/custom_components/climate

https://github.com/gieljnssns/My_Home-Assistant/tree/master/homeassistant/deps/smart_home

Can you test one final time for today?
But keep those old files somewhere on your computer…

Will try tonight.

Csn you help me with something please. I do so many times sudo reboot and wait so long for the reboot and restart.

I hvae HASS on pi3 with AIO instller (virtual environment)

Instead of doing sudo reboot I could do
sudo su -s /bin/bash hass
source /srv/hass/hass_venv/bin/activate

then what source /srv/hass/hass_venv/bin/stop and then source /srv/hass/hass_venv/bin/restart?

And is it possible to do a bath file … because I always forget the commands, so for simplicity I do sudo reboot.

But would rsther give a simple to remember command and launch all the above series of commands for stopping/restrtingg HASS.

I hope I am clear

Changed with this code after installing 0.39.

Only one thermostat is showing.

WHich version should I put back?

I hope this 2

Hi claudio,

for your hass user you can automate a few things. Here is what I’ve set up:

~/.bash_profile

if [ -f ~/.bashrc ]; then
   source ~/.bashrc
fi

and

~/.bashrc

source /srv/homeassistant/bin/activate; cd ~/.homeassistant/

This will activate the virtual environment when ever you log in.

I do start/stop/restart my home assistant instance with systemd services as I have set it up on ubuntu, but you can write simple batch scripts like restart.sh in your hass profile, which would do just that.

Btw. you don’t need to stop and restart. Restart only should usually be enough.

Hi, I have the same problem with my two Netatmo Thermostats. The temperature are the same on the display values!
I have tried to download the netatmo.py on https://github.com/gieljnssns/My_Home-Assistant and copied it in my /root/.homeassistant/custom_components/netatmo.py and the Thermostat.py in my /root/.homeassistant/dep/smart_home/Thermostat.py but when I restart hass all climate Netatmo entities are not present! My HA version is the last .040.0
Do you think that newers future versions will correct this bug?
Regards

Hi,

No, those do not work. Which where the 2 working?

I think this.

Hi @gieljnssns, has this been merged into the mainline? I’ve just ordered a netatmo thermostat and can’t wait to get that thing into HA. :wink:

One thermostat will work, multiple not.
I don’t know how to fix this.

At least one works, that’s enough for me right now. Now I need to get it hooked up to the boiler to play with it. :wink: Cheers

I just got my Netatmo Thermostat working and noticed the following. I set up the netatmo platform in HA which brought the thermostat into HA. Than I added the climate component and now I have the same thermostat twice. Is the climate component redundant? What is the correct way to use this?

In the end I removed the climate component as the netatmo component itself seems to automatically load the climate component.

Hi!

Now my DEPS directory is empty, where do I put your THERMOSTAT.PY file?

since some HASS version inside the DEPS directory does not exist the SMART_HOME directory. Where do I have to put the file THERMOSTAT.PY ?

I create a smart_home directory and put there the file.

I receive this error

2017-09-21 13:12:32 ERROR (MainThread) [homeassistant.components.climate] Error while setting up platform netatmo
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/helpers/entity_component.py”, line 164, in _async_setup_platform
SLOW_SETUP_MAX_WAIT, loop=self.hass.loop)
File “/usr/lib/python3.4/asyncio/tasks.py”, line 372, in wait_for
return fut.result()
File “/usr/lib/python3.4/asyncio/futures.py”, line 277, in result
raise self._exception
File “/usr/lib/python3.4/concurrent/futures/thread.py”, line 54, in run
result = self.fn(*self.args, **self.kwargs)
File “/home/homeassistant/.homeassistant/custom_components/climate/netatmo.py”, line 52, in setup_platform
add_callback_devices([NetatmoThermostat(data, module_name, device)])
File “/home/homeassistant/.homeassistant/custom_components/climate/netatmo.py”, line 78, in init
self.update()
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/util/init.py”, line 306, in wrapper
result = method(*args, **kwargs)
File “/home/homeassistant/.homeassistant/custom_components/climate/netatmo.py”, line 160, in update
self._target_temperature = self._data.thermostatdata.setpoints(module=self._name, device=self._device)
AttributeError: ‘ThermostatData’ object has no attribute ‘setpoints’

smart_home is located at

/srv/homeassistant/homeassistant_venv/lib/python3.5/site-packages/smart_home