Neato BotVac Connected binding?

oh2bindings
binding
vacuum
Tags: #<Tag:0x00007fd31093fea0> #<Tag:0x00007fd31093fd10> #<Tag:0x00007fd31093fb30>

(Jfbarnard) #183

None of the available jar files worked for me so I compiled the latest source available on the unreleased Openhab Neato addons github and fixed a few errors to make the binding work properly :

-Sending commands didn’t work so equalsIgnoreCase was used instead of “==” for comparing two string in sendCommand and in sendGetGeneralInfo of the NeatoRobot.java file
-Added a few lines to also pause the robot before sending the return to dock when sending the dock command
-Commented out the CHANNEL_ERROR case in publishChannel function

This is just a temporary solution for those of you who still want to use the binding until the official code gets updated :
https://drive.google.com/file/d/1mXch5HNQflEz1HdOtAcB-Jt7jKbaVqke/view?usp=sharing


(Dirk) #184

Thanks a lot! I can confirm the jar you provide works for my D5 Connected.


(Maciej Swic) #185

Same here, works on D5 Connected. Did you submit a pull request to the original GitHub repo?


(Holger Eisold) #186

@jfbarnard Thanks a lot for this… :slight_smile:

do you have also a example of your neato-vs.map file?

i still receive a

[WARN ] [rm.AbstractFileTransformationService] - Could not transform '' with the file 'neato-sv.map' : Target value not found in map for ''

(Ahiel) #188

cat openhab_conf/transform/neato-sv.map ui_alert_busy_charging=Busy Charging
ui_error_navigation_noprogress=Navigation Issue
ui_alert_recovering_location=Recovering Location
ui_error_brush_overload=Brush Overload
ui_error_dust_bin_full=Dust Bin Full
ui_error_dust_bin_emptied=Dust Bin Emptied
ui_error_brush_stuck=Brush Stuck

// Curent state of the vacuum cleaner
INVALID=Invalid
IDLE=Idle
BUSY=Busy
PAUSED=Paused
ERROR=Error

ON=Yes
OFF=No

// Current action of the vacuum cleaner
HOUSE CLEANING=Cleaning House
SPOT CLEANING=Spot Cleaning
MANUAL CLEANING=Manual Cleaning
DOCKING=Docking
USER MENU ACTIVE=User Menu Active
SUSPENDED CLEANING=Suspended Cleaning
UPDATING=Updating
COPYING LOGS=Copying Logs
RECOVERING LOCATION=Recovering Location
IEC TEST=Iec Test

// Current or last cleaning mode
CLEAN-MODE-ECO=Eco
CLEAN-MODE-TURBO=Turbo

// Modifier of current or last cleaning
CLEAN-MODIFIER-NORMAL=Normal
CLEAN-MODIFIER-DOUBLE=Double

// Current or Last category of the cleaning
CLEAN-CATEGORY-HOUSE=House Cleaning
CLEAN-CATEGORY-SPOT=Spot Cleaning
CLEAN-CATEGORY-MANUAL=Manual Cleaning

NULL=NULL
-=NA
=NA

(Holger Eisold) #189

@NCO thank you… i’ve also have had problems executing the script… but add “python” in front of the path helped… now i’m very happy with :slight_smile:


(Holger Eisold) #190

thank you… that is perfectly working without errors… :slight_smile:


(Fabi) #191

Do I have to use Botvac cloud or does it also work when cleaner is offline (only local WLAN connection to OH; but no internet access)?
I am from Germany, so I have some doubts using cloud services :grimacing:


(Mapicke) #192

Hey, I tried the latest build from jfbarnard. With it I have the same problem like before. I tried to switch robot language from german to english. Also for german I have tried the option to switch from 24h to 12h. But my status in paper ui is always --> "OFFLINE - COMMUNICATION_ERROR Unacceptable range for date"
Neato model: Botvac Connected 2.2.0
Any ideas? thx…

log:

11:06:27.041 [DEBUG] [ab.binding.neato.internal.NeatoRobot] - Will get STATE for Robot Nummer ZWEI
11:06:27.551 [DEBUG] [ab.binding.neato.internal.NeatoRobot] - Result from getRobotState: {“message”:“Unacceptable range for date”}
11:06:27.552 [ERROR] [ab.binding.neato.internal.NeatoRobot] - Error when getting Robot State. Error message Unacceptable range for date
11:06:27.552 [ERROR] [b.binding.neato.handler.NeatoHandler] - Error when refreshing state. Error: Unacceptable range for date


(Michael Bauer) #193

Hi, can somebody help? I have inserted my Vorwerk-Credentials but got a “Not allowed” in the Event-Log.

2018-02-26 23:39:28.036 [INFO ] [b.binding.neato.handler.NeatoHandler] - {"message":"Not allowed"}
2018-02-26 23:39:28.040 [INFO ] [b.binding.neato.handler.NeatoHandler] - Authentication Response: {"message":"Not allowed"}

The credentials are correct.


(Jens Hoffmann) #194

Hi, I tried to integrate the clening map as described by @fatman42285. If I execute the script, I get following error message.

pi@raspberrypi:/etc/openhab2/html/neato-botvac $ python3 /etc/openhab2/scripts/neato-botvac-getlastmap.py
Traceback (most recent call last):
  File "/etc/openhab2/scripts/neato-botvac-getlastmap.py", line 13, in <module>
    link     = account.maps[serial]['maps'][0]['url']
KeyError: 'OPS11111-XXXXXXXXXXX'

Account information and serial are correct. I checked it several times

Has anyone an idea what could be the problem?

Thx


(Bernd Weltrowski) #195

Hi Jens,

try python or python2

Bernd


(Jens Hoffmann) #196

With python or python2 get this message

Traceback (most recent call last):
  File "/etc/openhab2/scripts/neato-botvac-getlastmap.py", line 2, in <module>
    from pybotvac import Account
  File "/usr/local/lib/python2.7/dist-packages/pybotvac-0.0.6-py2.7.egg/pybotvac/__init__.py", line 1, in <module>
    from .account import Account
  File "/usr/local/lib/python2.7/dist-packages/pybotvac-0.0.6-py2.7.egg/pybotvac/account.py", line 5, in <module>
    import urllib.parse
ImportError: No module named parse


(Dirk) #197

When using version 0.0.5 of pybotvac it will work. Since the last commit (on Feb 10, 2018) ‘urllib.parse’ is being imported, which is named differently on python2. You can fix it by changing line 5 on ‘pybotvac/account.py’ from ‘import urllib.parse’ to ‘import urlparse’. After this modification run ‘python setup.py install’ again.


(Jens Hoffmann) #198

ok, I did this. Now I get with python2 the same message as with python3. please see my first post. Still the problem with KeyError

python2 /etc/openhab2/scripts/neato-botvac-getlastmap.py
Traceback (most recent call last):
  File "/etc/openhab2/scripts/neato-botvac-getlastmap.py", line 13, in <module>
    link     = account.maps[serial]['maps'][0]['url']
KeyError: 'OPS11111-XXXXXXXXXXX'


(Dirk) #199

Maybe you have entered the secret string returned by the pybotvac app instead of the Neato account password? As troubleshoot steps you could follow the instructions how to get the map described on: https://github.com/stianaske/pybotvac


(Jens Hoffmann) #200

Where could I entered the secret instead of the account password? In the script neato-botvac-getlastmap.py?

I got the same error message when I tried to get the map following the instruction.

pi@raspberrypi:/etc/openhab2/scripts $ python
Python 2.7.13 (default, Nov 24 2017, 17:33:09)
[GCC 6.3.0 20170516] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from pybotvac import Account
>>> map = Account('account mail', 'account password').maps
>>> download_link = map['OPS11111-XXXXXXXXXXXXXX']['maps'][0]['url']
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
KeyError: 'OPS11111-XXXXXXXXXXXXXX'

(Maciej Swic) #201

Hi again, do you have your changes available somewhere please? I would be happy to make a pull request to the original repo to fix this for everyone.


(Jfbarnard) #202

Sorry, I deleted the source after I tweaked the few things for the fix. However I recently browsed the repo for the binding and saw that the lines I fixed myself were already spotted by the reviewer and were in the list of changes requested


(Patrick S. Barowski) #203

Anyone a idea?

I got the neato connected D7 since some days… and tried to get the binding working.

Getting this error:
Status: OFFLINE - COMMUNICATION_ERROR java.util.concurrent.ExecutionException: java.net.SocketTimeoutException: Connect Timeout