Hello,
I’m trying to connect Home-Assistant with the SMA webconnect, but without success.
The configuration part looks like
sma
sensor sma:
- platform: sma
host: 192.168.1.112
password:[MYPASWORD]
sensors:
current_consumption: [total_consumption]
current_power:
total_yield:
Someone that can point me in the good direction?
Thanx in advance
Wim
Logging ;
2017-12-14 11:49:58 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/pysma/init.py”, line 45, in _fetch_json
url, data=json.dumps(payload), headers=headers, params=params)
File “/usr/lib/python3.6/site-packages/aiohttp/helpers.py”, line 99, in iter
ret = yield from self._coro
File “/usr/lib/python3.6/site-packages/aiohttp/client.py”, line 267, in _request
conn = yield from self._connector.connect(req)
File “/usr/lib/python3.6/site-packages/aiohttp/connector.py”, line 402, in connect
proto = yield from self._create_connection(req)
File “/usr/lib/python3.6/site-packages/aiohttp/connector.py”, line 748, in _create_connection
_, proto = yield from self._create_direct_connection(req)
File “/usr/lib/python3.6/site-packages/aiohttp/connector.py”, line 831, in _create_direct_connection
req=req, client_error=client_error)
File “/usr/lib/python3.6/site-packages/aiohttp/connector.py”, line 796, in _wrap_create_connection
return (yield from self._loop.create_connection(*args, **kwargs))
File “uvloop/loop.pyx”, line 1723, in create_connection
File “uvloop/loop.pyx”, line 1712, in uvloop.loop.Loop.create_connection
File “/usr/lib/python3.6/asyncio/futures.py”, line 331, in iter
yield self # This tells Task to wait for completion.
File “/usr/lib/python3.6/asyncio/tasks.py”, line 244, in _wakeup
future.result()
File “/usr/lib/python3.6/asyncio/futures.py”, line 236, in result
raise CancelledError
concurrent.futures._base.CancelledError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File “/usr/lib/python3.6/asyncio/tasks.py”, line 181, in _step
result = coro.throw(exc)
File “/usr/lib/python3.6/site-packages/homeassistant/components/sensor/sma.py”, line 125, in async_sma
values = yield from sma.read(keys_to_query)
File “/usr/lib/python3.6/site-packages/pysma/init.py”, line 79, in read
yield from self.new_session()
File “/usr/lib/python3.6/site-packages/pysma/init.py”, line 52, in new_session
URL_LOGIN.format(self._ip), self._new_session_data)
File “/usr/lib/python3.6/site-packages/pysma/init.py”, line 46, in _fetch_json
return (yield from res.json())
File “/usr/lib/python3.6/site-packages/async_timeout/init.py”, line 35, in exit
self._do_exit(exc_type)
File “/usr/lib/python3.6/site-packages/async_timeout/init.py”, line 80, in _do_exit
raise asyncio.TimeoutError
concurrent.futures._base.TimeoutError