Creation of Vorwerk Kobold Component

No yaml, through the integrations ui, seems to work ok…

Okay :grinning:
I’ve got the feeling that pybotvac needs some patches, when my PR is ready.

1 Like

Are there any news regarding the Vorwerk topic? The current api will be closed soon and without this component we will all lose the ability to controll our Vorwerk robots.

2 Likes

Thank you so much @trunneml for your work, I’m so happy, this is working with my VR300.

Since this morning I have been using your integration in my HA devcontainer and stumbled upon the following findings:

  • Map boundaries can be queried with self.robot.get_map_boundaries() if the map_id (ISO8601 time string when map creation was initiated) is known.
  • When the robot is cleaning a zone (e.g. when triggered from the app), the map_id can be retrieved from self.robot.state['cleaning']['mapId']. I used that id and hard-coded it into the integration for my HA instance in this commit 6b40c22@trunneml-vorwerk. Maybe the integration can also ‘harvest’ map ids when observing them in the robot’s state, so we can offer the zone cleaning functionality in the custom_cleaning service call already without some other auth methods?
  • I had to run python3 -m script.translations develop for the description of the config flow forms to show. This adds some json files in the translation folder.
  • The services.yaml can be updated to support selectors in the new UI mode.

Thanks for the link. But how do I integrate this code into my Home Assistant?

1 Like

Hi,

I only have the VR200 so I can’t test the map feature.
I had to delete the translations for the PR into Home-Assistant. Also I have to remove the schedule switch and the battery sensor. (They will be added later in a seperate PR).

As the PR needs more time to be integrated in Home-Assistant. I will create a custom-component GitHub repository for HACS.

My job is currently very busy, so I hope I will find the time next weekend.

3 Likes

Hi,

I’m keen to see this implemented too, I only have a VR200, but shout if you’d like another tester?

Thanks for your work on this so far…

I’m still working on the PR, but in the meantime you could use and test my integration as a custom_component: https://github.com/trunneml/homeassistant-vorwerk

1 Like

I will give it a test with my VR300.

Hi there,

i like to test with my VR200 and VR300. But some short questions:
How to get the SECRET?
The HACS integration has no UI? I have to config via configuration.yaml, right?

I’m a newbie, but very interested in getting this integration to work with my Home Assistant (my robot is a VR200).
Could you please guide me through the configuration?
I know basic things, but also where to find what I don’t know yet… I don’t want you to waste too much time, just give me some hints.

Thank you :slight_smile:

You don’t need the Secret or have to configure it by the configuration.yaml.

Just add the Vorwerk Kobold Integartion via the “Add Integartion” button under Configuration > Integartions.
The config flow will ask you for your email address and the one time password aka code.

Strange … I Installed over HACS and it installs under
/homeassistant/custom_components/custom_components/vorwerk
I think this is not correct. After HA restart there is no Integration via the UI.
If i clone the repositroy direct and place it in /custom_components/vorwerk i also have no Integration displayed …
Any Idea?

Today the Integration is displayed .) but then:

Fehler

Der Konfigurationsfluss konnte nicht geladen werden

Update:
The following errors occured in the log:
2021-04-21 19:41:06 ERROR (SyncWorker_9) [homeassistant.util.json] Could not parse JSON content: /config/custom_components/vorwerk/translations/de.json
Traceback (most recent call last):
File “/usr/src/homeassistant/homeassistant/util/json.py”, line 32, in load_json
return json.loads(fdesc.read()) # type: ignore
File “/usr/local/lib/python3.8/json/init.py”, line 357, in loads
return _default_decoder.decode(s)
File “/usr/local/lib/python3.8/json/decoder.py”, line 337, in decode
obj, end = self.raw_decode(s, idx=w(s, 0).end())
File “/usr/local/lib/python3.8/json/decoder.py”, line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 19 column 7 (char 620)
2021-04-21 19:41:06 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140341606218288] Error handling message: Expecting property name enclosed in double quotes: line 19 column 7 (char 620)
2021-04-21 19:46:58 WARNING (MainThread) [homeassistant.util.async
] Detected I/O inside the event loop. This is causing stability issues. Please report issue to the custom component author for vorwerk doing I/O at custom_components/vorwerk/config_flow.py, line 82: self._session.send_email_otp(self._email)

After copy en,json over de.json the config Fow starts but the second error occures when i enter the Mail address.

Additional Info from the error:
RuntimeError: I/O must be done in the executor; Use await hass.async_add_executor_job() at custom_components/vorwerk/config_flow.py, line 82: self._session.send_email_otp(self._email)

Yes, you need the en.json and de.json translation files.

And it looks like the new home assistant version has a problem with the auth flow.

I will look at it.

I had the same issue with the doubled folder when installing by hacks.
So, I created the folder manually by upload. Anyway, I also have the problem that there is no vorwerk integration I could install.

How did you bet the integration displayed?

Okay that with the double folder is strange i will look at it.

I fixed the wrong folder structure with hacs. Could you try it again?