-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Selective (Room Based) Cleaning #80
Comments
The Roomba module was written for the Roomba 980, which doesn't have selective maps, so it wasn't a feature that was included. Having said that, I have just pushed version 1.2.9, which now allows you to send any command to the roomba using json. Normally you just send a one word command such as:
Which will still work, but now you could also send this as:
You send the command as a json string to an mqtt topic So, in your case the json command would be:
This is obviously untested, as I don't have a roomba i7, but give it a try and see if it works. |
Hey Nick, confirmed working. Thanks for a quick and thorough response. Tried by just sending the command via MQTT, and was able to run a few successful cleans. Will mess around more tomorrow with different rooms/room combos. Looks like I just take the command the app sends (shown in the log of Roomba980) & reissue via MQTT or openhab in order to duplicate the same functionality. To all other i7 owners out there searching for this functionality, following the last command Nick posted, but replacing with the information that comes from the Roomba980-Python script should get you room specific cleaning jobs! For others - To get this info for your specific map/Roomba:
|
Great work, thanks. Will test with my i7 soon as I get a chance to update. |
Good to know it works, Looking at your log output, it seems that you have three maps defined:
I assume these correspond to three different areas/floors or something. The Within the map, there are probably sub areas (regions), corresponding to rooms, Your kitchen seems to be defined as:
So you can probably specify multiple regions/rooms per map by adding the region to the So you can probably send cleaning jobs for multiple rooms by sending something like:
Where X is the region id number and yyyy is the name (figured out by trial and error). The region id's are probably specific to a map, so you would have to make sure they correspond. If you edit the map, you would probably have to update the Don't know what If someone wants to send me a Roomba i7 I can probably figure it out... |
So I did have a ton of time to play with it over the weekend. You are right Nick, once I discovered roomba's other region identifiers, inserting them was fairly easy to get room specific cleaning jobs going that either used one or some of the rooms defined. I only changed the region info within the I still need to build out the functionality for the other two floors, I am assuming the I haven't played around with |
I understand, I just ordered a weather station for my wife that she doesn't know she needs yet. It'll help with her gardening! I feel that I should point out that traditionally women are allowed to divorce you if you buy them a vacuum cleaner for their birthday. Just saying... |
I now have an s9 and a Braava jet m6. I have re-written the library, and will be adding selective mapping. Anything else you found out about it would be appreciated, or I will have to figure it out myself. New version should be up in a few days. |
Hey Nick, here is an example of my full command I use to issue selective cleaning commands to Roomba. Keep in mind, I had to use the app to fully setup and run the training runs before using this.
I found these commands by running MQTT spy and looking at the last command that was issued to Roomba when running a selective clean for each specific room (using the app). This is the specific piece you are looking for & IIRC the easiest way I was able to get this was by running cleaning missions for each room I had setup via the app and then checking Roomba980 Python for what was sent to the roomba via Last Command:
From there, I wrote a [shitty and clunky] script which I use with the Exec binding in OH to trigger the appropriate combo of commands depending on the rooms I want cleaned. Hope thats helpful! |
Thanks, I’m working on the new version... |
Hello from Russia. Thanks for great work. |
You need to setup and configure roomba.py as a linux service and configure it to speak to your MQTT server. If roomba.py is not running and not communicating with your MQTT server, then your Mosquitto_pub commands wont do anything. Download the program MQTT Spy and make sure your roomba is connected to the MQTT server and reporting its status. |
I suggest you read through the documentation, it covers the usage with mqtt quite thoroughly. Mqtt works better than the REST interface. You need to run What machine is your Mosquitto broker running on? If it’s a different machine than the one you are issuing command on, you have to add Everything works on Ubuntu, that’s what I run |
@NickWaterton |
Sorry for the stupid questions, but i am a novice in mosquito technology. I installed MQTT Explorer and it's helping me to understand how it works. I append the name of my Roomba's robot to the topic address and its work! <mosquitto_pub -t /roomba/command/Bender -m "start"> |
It works! This command sended by MQTT to topic /roomba/command/Bender works (Bender is my Roomba's robot name).
|
Glad you figured it out! |
Hi , |
Hello,
Thanks for a great solution for integrating and controlling my Roomba i7 via Openhab.
I did have a question I could not seem to find an answer to. I have created several Smart Maps using the iRobot app on my mobile device to correspond to the different floors/rooms of my house. I am able to successfully pass basic commands to Roomba like start, dock, pause etc. however, I cannot figure out how to tell Roomba to use these maps to clean a specific area of my home.
I can see when initiating a room-specific clean that the data is showing up in the logs/statuses of this script. Any suggestions as to how I can pass these variables when initiating a cleaning job?
The text was updated successfully, but these errors were encountered: