i got mikrotik router and now running HASSbian on RPI3, If I want to enable miktorik component in HASS (like this: https://home-assistant.io/components/device_tracker.mikrotik/) my RPI3 can’t start this service, because missing some libraries…!!!
anyone else got same problem? what is right setup to use mikrotik as device tracker? I’d like to achieve that I can use output from mikrotik about connected clients to my local wifi network to use presense detection. got different androis, ios and Windows Mobile devices…
thank you
grz
Hello,
still not working. I get this error in log file:
> 2017-06-20 21:19:48 ERROR (MainThread) [homeassistant.components.device_tracker] Error setting up platform mikrotik
> Traceback (most recent call last):
> File "/usr/local/lib/python3.4/dist-packages/homeassistant/components/device_tracker/__init__.py", line 151, in async_setup_platform
> platform.get_scanner, hass, {DOMAIN: p_config})
> File "/usr/lib/python3.4/asyncio/futures.py", line 388, in __iter__
> yield self # This tells Task to wait for completion.
> File "/usr/lib/python3.4/asyncio/tasks.py", line 286, in _wakeup
> value = future.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 "/usr/local/lib/python3.4/dist-packages/homeassistant/components/device_tracker/mikrotik.py", line 41, in get_scanner
> scanner = MikrotikScanner(config[DOMAIN])
> File "/usr/local/lib/python3.4/dist-packages/homeassistant/components/device_tracker/mikrotik.py", line 71, in __init__
> self._update_info()
> File "/usr/local/lib/python3.4/dist-packages/homeassistant/util/__init__.py", line 303, in wrapper
> result = method(*args, **kwargs)
> File "/usr/local/lib/python3.4/dist-packages/homeassistant/components/device_tracker/mikrotik.py", line 142, in _update_info
> cmd='/interface/wireless/registration-table/getall'
> File "/usr/local/lib/python3.4/dist-packages/librouteros/api.py", line 80, in __call__
> return self._readResponse()
> File "/usr/local/lib/python3.4/dist-packages/librouteros/api.py", line 103, in _readResponse
> reply_word, words = self._readSentence()
> File "/usr/local/lib/python3.4/dist-packages/librouteros/api.py", line 89, in _readSentence
> words = dict(self.parseWord(word) for word in words)
> File "/usr/local/lib/python3.4/dist-packages/librouteros/api.py", line 89, in <genexpr>
> words = dict(self.parseWord(word) for word in words)
> File "/usr/local/lib/python3.4/dist-packages/librouteros/api.py", line 34, in parseWord
> _, key, value = word.split('=', 2)
> ValueError: need more than 1 value to unpack
or do you have some special characters inside… (I had the Problem, that i was using “Umlaute: ÜÖÄ”) after getting rid of them… everything worked liked expected.
I’ve been running for Wi-Fi presence my Mikrotik RB715G-2HnD long time trough SNMP and it works so good that I don’t even want to try this component. See if this works for you: