Neato BotVac Connected binding?

Hi @fatman42285,

thanks a lot for the detailed description. That should work for me :wink:
I will implement it into my habpanel though.

If I am not mistaken, this should work without your recently sent jar (because it’s actually running through the pybotvac, not the binding?), so your decsription should also work with the lastest jar by @scurb?

Sorry, I still struggle a little:

When I execute the script I get:

[09:11:43] pi@Homer:/usr/local/bin/pybotvac/cert$ su pi /etc/openhab2/scripts/neato-botvac-getlastmap.py
Passwort:
from: can't read /var/mail/pybotvac
from: can't read /var/mail/os
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 4: $'\r': Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 5: email: Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 6: password: Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 7: serial: Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 8: path_tmp: Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 9: path_dst: Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 10: map_file: Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 11: $'\r': Kommando nicht gefunden.
/etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 12: Syntaxfehler beim unerwarteten Wort `('
'etc/openhab2/scripts/neato-botvac-getlastmap.py: Zeile 12: `account  = Account(email, password)
[09:11:49] pi@Homer:/usr/local/bin/pybotvac/cert$

the script looks like:

#!/usr/bin/python
from pybotvac import Account
from os       import system

email    = 'xxx@hallo.welt'
password = 'passwort'
serial   = 'OPS1111-sonstwas'
path_tmp = '/etc/openhab2/html/tmp/'
path_dst = '/etc/openhab2/html/neato-botvac/'
map_file = 'botvac-last-map.png'

account  = Account(email, password)
link     = account.maps[serial]['maps'][0]['url']

account.get_map_image(link, path_tmp)

system('mv ' + path_tmp + '*-user-map.png ' + path_dst + map_file)

I copied the pybotvac folder into /usr/local/bin/ and added this folder into
/etc/profile

Hi NCO

did you a ‚python setup.py install‘ in the extracted pybotvap-master folder?

Hi NCO,

… yes!

Yes, I did.
I removed the folder above (/usr/local/bin/pybotvac) and installed pybotvac again.
Still the same issue.

Should I find any pybotvac somewhere else then (e.g. in /usr/bin/ or such?).
Is the (manual) adjustment of etc/profiles needed at all (rolled this back already).

What about /var/mail/
I don’t get the point of mail beeing involved somehow.

In the log I find:
Execution failed (Exit value: -559038737. Caused by java.io.IOException: Cannot run program “/etc/openhab2/scripts/neato-botvac-getlastmap.py” (in directory “.”): error=2, Datei oder Verzeichnis nicht gefunden).

When I try to execute it in the console I usually try:
su pi /etc/openhab2/scripts/neato-botvac-getlastmap.py
and get the errors mentioned in my previous post

GOT IT:
In the rule I needed “python” in the executeCommand line:
executeCommandLine("python /etc/openhab2/scripts/neato-botvac-getlastmap.py", 5000)

Hi NCO,

did you run the sample.py?

no, maybe I have missed something?
but now that it’s working I am fine with it.

Obviously bash interpreted the py script as it’s own. That’s why I tried

executeCommandLine("python /etc/openhab2/scripts/neato-botvac-getlastmap.py", 5000)

Anyway, thanks for your patience and help, Bernd.

1 Like

Hi NCO,

am I right? You got a cleaning map working with the Vorwerk Kobold VR200?

Maybe, you’ve realized that I created a little tutorial? Connecting Vorwerk Kobold VR200 to openHAB2
I integrate your map-file into this, if it’s ok for your.

Hi @anfaenger,

No, actually I am running my new botvac connected with the map feature (realized with the python script)

Hi Bernd,

I’m also very interested, can you please send me your jar file too?

Thank you very much

I sent you a mail …

Hi Bernd,

thanks for the file. It works perfectly!!!

Hello Bernd,
can you send me the jar file, too?

Thank you so much for your help in the community.
Best, Jens

Hi Bernd,

at first sorry for my bad english :slight_smile:
Is it possible to install your API as a normal Binding? I’m a really noob relating python and so on.
Can in manually install the binding via the jar file by adding it to the addons file?

I’ve tried to install the api with python and it seems to work, but now i’m not sure how to find it in the Paper UI?!

Thanks for helping me in that case.
BR David

Hello Bernd,

Can you send me the VR200 jar file too?
Thanks a lot.

Best regards Hans-Gerd

Thanks for the detailed description. I have now also a neato map in openHab! Great! :slight_smile:

Hello Bernd,

I would be glad if you send me the jar file, too.

Thank you!
Rainer

@NCO Hello Bernd,
Can you send me the jar file as well?
Thank you, Ton

Hello Bernd,

Can you send me the VR200 jar file too?
Thanks a lot.

Best regards Lars

Hello Bernd,
I just stumbled over this thread and couldn’t get around to wonder why everyone is asking for a binding jar via mail. Did you consider providing the jar publicly? You could upload to any of the establishes file hosters (like Dropbox or Google Drive) or ideally publish it directly to the dedicated Eclipse IoT Marketplace.

Edit: After inspecting this thread a bit more I realized that the binding was originally developed by @scurb but development stopped 7 months ago.
@fatman42285 did you consider contributing a Pull Request against the original repository? @scurb are you still active here? As it seems many are happily using the binding, how about you provide it to the main openhab2-addons repository?

Best! Thomas