Roomba Vs Poop: Teaching Robots To Detect Pet Mess

Imagine this: you come home after a day at work. As you open the door, your nose is the first alert that something is very, very wrong. Instead of the usual house smell, your nose is assaulted with the distinctive aroma that means your dog had an accident. The smell is stronger though — as if Fido brought over a few friends and they all had a party. Flipping the lights on, the true horror is revealed to you. This was a team effort, but only one dog was involved.

At some point after the dog’s deed, Roomba, your robot vacuum, took off on its scheduled daily run around the house. The plucky little robot performed its assigned duties until it found the mess. The cleaning robot then became an agent of destruction, smearing a foul smelling mess throughout the space it was assigned to clean. Technology sometimes has unintended consequences. This time, your technology has turned against you.

This scene isn’t a work of fiction. For a select few families, it has become an all too odoriferous reality just begging for a clever fix.

r900iRobot’s Roomba has been around for 14 years now. Over the years Roomba has evolved into a complex robotic vacuum. Current models have the iconic front bump sensor, as well as cliff sensors for stairs. A forward IR sensor allows the robot to slow down before striking furniture. Dirt detectors determine if an area is clean, or needs more attention. The flagship 900 series even includes a camera and computer running the Visual Simultaneous Localization and Mapping (vSLAM) algorithm.

All these sensors are great for 99% of the cleaning a Roomba will perform. However, the 1% edge cases are where the demons hide. The demon in this case is a steaming surprise left behind by a pet. [Jesse Newton] found himself in just such a situation last week. His Facebook post on the subject quickly went viral. An iRobot spokesperson was quoted in The Guardian as saying  “Quite honestly, we see this a lot. We generally tell people to try not to schedule your vacuum if you know you have dogs that may create such a mess. With animals anything can happen.” The spokesperson went on to say that their engineers are working on the issue. If the spokesperson (and The Guardian) are to be believed, Somewhere inside iRobot, there is an engineer contemplating all the life choices that brought them to this assignment: designing a system to allow the robot to detect pet droppings.

iRobot, the company behind the little circular robot, was quick to embrace the hacker community. Many models of the Roomba include a serial connection. There is even a special Create model for hackers, schools, and makers. Here at Hackaday we believe in giving back. iRobot has given quite a bit to the hacker community over the years. Helping the beleaguered iRobot engineers in their quest to detect the disgusting is the least we can do.

It turns out that sensing animal or human waste is no easy task. Here are a few ideas we came up with:

  • Methane – The most familiar method for hackers would be methane detection. We have low cost sensors such as the MQ-4 that are specifically designed for this. In fact, that’s exactly what [IntStarFoo] is testing out in this YouTube video. The problem is that the methane isn’t produced by the fecal matter itself, but the bacteria which are along for the ride. The anaerobic bacterial process takes time, so a fresh sample may not have a detectable amount of methane around it.
  • Methanethiol – one of the chief contributors to aroma of human or animal waste is methanethiol, or methyl mercaptan. Detectable by humans down to 1 part per billion (ppb), this is the same chemical added to natural gas to give it that distinctive smell. When a nose is not present, methanethiol is often detected using field sampling followed by gas chromatography in the lab. Sensors do exist, but they are up around $500 USD.
  • Other gasses – waste emits a potpourri of gasses, including hydrogen (H2), methane (CH4), carbon dioxide (CO2), hydrogen sulfide (H2S), methanethiol (CH3SH), and dimethyl sulfide (CH3SCH3). Perhaps combinations of these gases could be used as indicators that man’s best friend is having a bad day.
  • Cameras – High end Roombas already have a camera. However, it is facing up at too steep an angle to detect anything directly in front of the robot. Adding a front facing camera similar to the hazcams used in Mars rovers might be helpful here. This would also help keep Roomba from knocking over trash cans. The downside is that not all droppings are created equal. The medical industry has provided us with The Bristol Scale, which ranges from Type 1: Separate hard lumps, like nuts, to Type 7: Watery, no solid pieces, entirely liquid. It would take some creative vision programming to detect all types.
  • Conductivity – waste will have a water content. An array of conductivity sensors along the front of the robot could detect if it is pushing on something wet.

These are just a few seed ideas to get you started. For the real answers we turn it over to you, our readers. How would you help iRobot through this dilemma? To put it more bluntly, how would you teach a robot to detect poo?

119 thoughts on “Roomba Vs Poop: Teaching Robots To Detect Pet Mess

  1. Not being familiar with the Roomba’s capabilities, I’m assuming it is intended to clean up dry matter only (dust, dirt, etc). I’m thinking the moisture detection would be the preferred route. Even a puddle of milk or Kool-Aid smeared around is not a happy time.

    Another challenge one owner I know has with the Roomba/Pet war – pet hair. Wrapping around wheel shafts. It’s nearly a monthly maintenance task for him to pull out a knife and cut away hair that has been collected. (Only father/son in the house with a large, long haired mutt).

    1. Indeed; not knowing the internal construction, I’m surprised there wasn’t some form of ‘puddle’ check to ensure that the unit didn’t try and clean up when a kitchen appliance leaks or someone spills anything, as generally water+electronics don’t usually get on (although I notice that iRobot do have a line of “mopping” units).

      A quick check of the Roomba FAQ sounds like all users (even those without pets) should put on a moisture detector:
      http://homesupport.irobot.com/app/answers/detail/a_id/75/~/can-roomba-sweep-water-from-the-floor%3F
      “No, Roomba should never be used to pick up any liquid, including water”

    2. I wonder if you can do some reflection testing for puddles (thinking milk, water, juice)?

      I have a Botvac. It does an amazing job of picking up pet hair and even detects when the spinning brushes aren’t spinning well enough and alerts you to clean the bearing areas which avoids damaging the motor, etc.

    3. BTW, moisture detection would also deal with mud – either being tracked in or dumped from planters tipped over by pets/kids/etc.

      The more I think about it, and read about iRobot’s own FAQ regarding moisture, the more I’m wondering why it hasn’t been implemented already? What am I missing?

      1. One thing my wife pointed out is that conductivity based moisture sensors could be thwarted by metal furniture. Stainless steel appliances might be an issue too – though I believe many of those have a varnish coating.

        1. Depends at what point the sensor is placed; if it was protruding forward then, yes, I could definitely see it being confused by metal objects (table legs, etc) but if it was under or just after the brushes then it could at least enter a ‘panic’ mode and stop what it is doing to avoid further damage (to itself and the home)

          1. You could use a more sophisticated conductivity test. Metal conducts very well at any frequency. Water less so, with DC, and perhaps has a certain profile at different frequencies. Perhaps a capacitive test rather than a resistive one.

          2. If the moisture sensor contacts are slightly recessed in a piece of plastic then they could still detect liquid hazards, but not get confused by metal flooring or furniture.

        2. One simple test that could fix that, potentially:

          – Forward facing conductivity sensor tripped, bump sensor tripped = solid object, back up.
          – Forward facing conductivity sensor tripped, bump sensor not tripped = mud or poop, shut down

          Or you could put the sensor slightly underneath but not in contact with a normal floor. If that one is triggered, the unit would shut down.

      1. and when the refrigerator leaks or heaven forbid, the high pressure steam hose from the hot water to our dryer burst and we had 2″ of water throughout our home… Or snow drifts piling up outside and leak past the threshold as it warms up outside… Liquid mess isn’t limited to pets only

    4. In case you don’t own a roomba, there are a few things to consider. The pathing logic cycles between several logical, methodical, and random direction changes at random intervals. It’s strength is in its simplicity and over a decade of revisions and optimizations. Any solution to the dog shit dilemma needs to be a simple one as well.

      I think the first comment about moister detection was spot on. All liquids are a hazard to a roomba. Some sort of resistance check in the direction of the path that looks for a range (that organic liquids and pastes would have) over several milliseconds, would likely work. Too many commenters are thinking along the lines of a Boolean continuity check scenario. We live in an analog world and anyone dealing with robotics needs to think about it that way.
      I’ll check the resistance of spilt milk. So for the rest of you…

      Thank you for volunteering to stick test leads into dog shit for science! Grab a multimeter and follow the dog around outside. You’ll know when the test starts.

      1. Except not all fluids are conductive…. Ultra pure water, is on the order of 18M Ohms. Household liquids are probably somewhat more conductive, but that doesn’t mean a big glob of axle grease is going to be…

    1. When i first got my roomba i would look through the bin to see what it had collected. Spiders (living) were a common thing it cleaned up. The spindly legged ones, not the hunting/jumping kind. Beetles resist the roomba pretty well. Until the cats find them. Then the roomba will clean up the corpses and dismembered parts.

      My guess is you need something that can fulfill the cat role and be resistant to scorpion stings. It doesn’t have to clean up the scorpion kill. Just leave the bits where the roomba will find them. Or maybe a replace one of the roomba brush rollers with a bladed one? It would just drive over the scorpion over and over and over until the battery died or the mess disappeared. Like the terminator. Pretty much the same thing it currently does with poop.

    1. That is what I try first. IIRC I read an tutorial a while ago about how to make opencv recognize a banana with only 40 pictures of bananas. A webcam and 40 turds are easily obtainable for a proof of concept.

      1. disgree. the dog could step in it or maybe there are multiple dogs. to image recognize all the varieties and states of it, that does not sound like an easy problem at all.

        the solutions I’ve heard involve cameras and a big back-end computer that is online and can do the image processing and recognition for you. the embedded device is unlikely to have the power to do that locally.

        that brings up the privacy issue. I would never accept a roving camera robot in my home. not in a million years, no matter what ‘benefit’ they promise. I don’t trust iot companies and once you require a web back-end and a cloud, I lose all interest.

        taking a different approach, I wonder if you could build a sensor that is dog-wearable (lol) and can at least give hints that an accident (haha) happened and where. that adds much more smartness to the system than not having it. wonder if anyone is thinking along those lines?

        1. I agree, but I don’t own a dog or a Roomba, and I don’t ever plan on getting either. I just offered a suggestion that I thought might be made to work. Heck, you can integrate color sensors into your Lego projects these days, it can’t be too darn hard to make a microcontroller tell the thing to stop if it sees the color brown!
          (yes, I know that this wouldn’t work in many instances, but in many others it could)

          1. But most dirt is brown. A lot of flooring is brown as well. So, if it stops at the color brown, it won’t pick up much of the crud that it’s meant to clean. It also won’t continue if the flooring is brown. It already has that problem with black flooring; it detects any black to be a drop off and it backs away or shuts down.

      2. They thing was that you only needed a relatively small amount of pictures and run these through a software that generates thousands of variants based on these. Then you have thousands of samples to run through another algorithm that generates a fingerprint file that opencv can use to recognize objects with light processing load. The heavy lifting is done in advance on more powerful machine.

        IIRC that is…

    2. i think they should use not a poop detection, but should use an unknown object detection, for the first days the rooma should scan objects it can be done while driving around and at one time when you think or the roomba thinks after a week “i know everything on the floor” than on every unknown new object it should avoid it scan it and asks its owner if its save to eat?
      maybe that kind of solution will work much better

  2. This is something I’ve been contemplating for my HaD Prize entry (https://hackaday.io/project/9072-open-autonomous-domestic-robots). Right now I have a color sensor mounted on the front of the robot to detect transitions between different types of floor by sensing a change in color. However, I don’t think it’d be much more difficult to use this to detect if the floor suddenly starts changing to an unexpected color (e.g. brown) and stopping the cleaning process as a result.

    1. I like this idea, it would work really well with the existing room mapping they have, and may be the most effective route for a number of messes. (Everything from strawberry jam, to poo, to whatever)

    1. Robots need a ‘seek and let fido outside every 4 hours’ mode. If dogs can be taught to play ball with a robot you should be able to teach them to ask a robot to be let outside. Then again, dog doors are a thing and there are issues with letting fido out when you’re not home. Still I’d like to see assistive robots for pets — it would signal that we’re really making progress toward meaningful assistive robots for humans.

      If you didn’t get my reference about playing ball with a robot, it’s GoDogGo and this will plaster a huge grin on your face:

      https://www.youtube.com/watch?v=PY6fG9k3ZO4

  3. meta comment: imagine the scene at HAD when the boss asks the illustrator for a drawing to accompany this topic.

    “yeah, we have this roomba thing we’re writing about. yeah, it has poop in it. we need some illustration for this. what do you have in mind?”

    lols

    not really something I’d enjoy drawing, myself, but I guess the job is sometimes a bit, uhhh, off-color, at times.

    1. It was more like, “Hey we have this article titled Roomba vs Poop,could you do an illustration of a Roomba detecting a dog’s mess in a room?” Then artist proceeds to draw a swirl of poop about to engage in a no holds bar wrestling match with a Roomba.

      I love my job.

  4. I read a comment in a thread somewhere…the guy was an engineer at Roomba, and he posted a couple of photos of the results of a Roomba-poop encounter. About what you’d expect — trails of poop smeared everywhere. The referenced Facebook post describes it pretty accurately.

    Folks, if you own a Roomba and a pet, please be careful what your pet eats…

  5. How about a vision system that flags anything out of the ordinary (color/shape detection) and texts a picture to you for a clean/leave it alone decision? Then maybe pair that with a learning AI that could figure out what poop does or does not look like. Have the AI in the cloud (with people opting in, of course) so it could learn from all users.

    1. This seems like the least computationally-intensive route. Flag the questionable area to be avoided until a human can confirm the decision. Though it would be strange getting random texts of floor stains.

  6. What is it lately (the last two weeks or so) with all these remarkably similar stories of people who had a dog crap in their house and their Roomba turning it into an artwork, before being generously replaced under warranty? Methinks this smells not only of dogpoop, but product placement.

    ===Jac

  7. What about a thermal imager watching the room? Before the incident, there’s one hot-spot moving around (dog). Just afterwards, there are two: one moving, one stationary.

    The sensors are still relatively pricey, but coming down.

  8. I vote for #2 — Methanethiol sensor as well as a moisture sensor.

    Anyone who owns a Roomba and a dog is wealthy enough to buy one as an insurance policy against having shitty artwork on their floor when they come home from work. Mass adoption press technology to get better (cheaper). So we can afford to play with them.

    At the end iRobot could make a killing using the “Kirby Model” — whole house cleaning systems. Only these are networked. Your vacuum detects moisture or a mess, relays back to the mopping unit, and continues its cycle when everything is done.

    No housewife necessary!

  9. It seems to me that noses have a chemical detection capability that is pretty sensitive to outgassing from poo. Maybe there is a way to replicate that process with an as-yet undeveloped sensor. Perhaps some organic substances detectably change state in the presence or absence of these gasses.

  10. Or, you know, vacuum your floors yourself. Won’t impress your visitors as much, but then neither will a stinky carpet. And it’s far less expensive, especially considering the headaches.

    Dishwashers I can understand. Vacuuming robots, not so much. I have friends with a Roomba, and they generally look rueful when discussing it.

    1. It comes down to the cost and use comparison: cleaning woman vs. cleaning robot. But the cleaning woman also can do laundry, ironing and cleaning other places than the floor, e.g. the bathroom. and sometimes the cat-litter-box

  11. It would be awesome if iRobot provided API or some way for us to modify or at least observe the internal state of the Roomba. I have a Roomba myself and there are several improvements to be had. I had cases where it pushed a potted plant way too much until the pot cracked. Once it got badly stuck on a cable under the TV cabinet. And yet another time it was somehow jammed (infinite loop) between two chairs – there was an obvious exit, but it just couldn’t figure it out. Now I have to make sure that the environment is completely “Roomba safe” before scheduling it, but with kids leaving things behind etc, you never know. I would like to e.g. see what picture/model of the world the Roomba creates as it goes about its business. I know there are some expensive Roombas for modders (without the vaccuum cleaner), but I want to hack the real thing.

    1. Yes, this is the way to go for sure. It would be possible to design a single wavelength imaging system which would be much more cost effective. 1950nm or 1450nm would do the trick. Those wavelengths are moisture regions and will easily differentiate poop/vomit from floor.

  12. What about detecting a temperature difference in the floor? I know it’s not a perfect solution but with enough testing and some clever software you could probably create something that could reliably detect “puddles” of temperature that differ significantly from the surrounding floor.

      1. I understand that alone it leaves something to be desired but what does it look like if you put a pile of poop in that puddle created by the light? Does the light puddle have a much wider and graduated puddle compared to the poo? Does the poo stand out from light puddle even while on top of it. That’s why I was wondering if there could be something done extra done on the software side and maybe and additional sensor of some sort. I still think it’s a good and cheap start to the problem.

  13. I thought about a poop collecting robot before, but concluded that it is very difficult task, especially outdoors on meadows! A robot would have to drive his way over the whole area again and again and again. I thought about temperature sensors, but what if the poop is not very fresh or if it is hot outside? Of course I thought about methane sensors, but I don’t think the sensors are sensitive enough to smell poop from more than just a few centimeters. And if it’s windy … no, methane sensors would not work well. And again, if the poop is not fresh, it’s more difficult to smell it. I think the most efficient way would be a software recognition of poop, but I can’t do it and I think it won’t be able to differ my purse from poop. However, if you would come up with a poop collecting robot in Germany, you will certainly get attention!

    1. I my idle times I have often thought of this. Most of the time my lawn is a nice green color – except during a heat wave where sometime it gets a tad brown. The big issue is how does one pick up the poop (like the alliteration?). We have three beagles that over a few weeks will produce output of various densities. The hard chunky ones would be fairly easy but what to do with the ones with a density approaching water? I thought a tank of liquid nitrogen to squirt on the ‘loose’ ones to turn them less loose may be the solution – but then thinking further wondered what the wife would think about the nitrogen burnt lawn!

  14. Everyone seems to be concentrating on turd avoidance. Why is that? I say embrace the poop! Make a Roomba that can handle anything. After all, if you hired a cleaning woman and came home to find immaculate floors right up to some arbitrary exclusion zone around a steamer, you’d be pretty ticked. It’s a dirty job, so I say make the robot do it.

    Not saying it’d be easy, and it would probably increase the price of a Roomba beyond the affordable. But I’d love to see a practical domestic robot that could handle a lot of different cleaning scenarios. Given enough utility, I’d bet they’d sell.

    1. You know, there are several companies around here that will scoop the poop out of your yard – for a price. If folks are willing to pay $200 (or more) for a litter box that scoops itself, I bet they’ll pay for a robot that cleans the floors and handles the poop. Now just have to make sure it doesn’t steal all the Lego pieces the kids left out…

  15. I know of some people that said bot could not move at all due to random clothes dropping and scattering. They need a laundry gathering bot first.
    Strings and things are a real problem with anything that rotates.

  16. Maybe feeding your cat/dog a detectable, radioactive substance, RFID chips or friggin nanobots will help with the detection issue. Or more elegantly, solve the problem at the root and get a robot-pet. Ideally one that vacuums the floor.

  17. First, it should be able to detect moisture and avoid it if possible; there are several good ideas on here for that. Secondly, because sensors sometimes fail or get confused, it should be looking backwards at its tracks and if it detects a smear/streak pattern it should stop vacuuming/moving. This way any substance (poop, vomit, milk, etc) it’s smearing would be isolated to a small area in the event it rolled over it.

  18. I don’t see this as a problem that needs to be solved, I see it as poetic justice. If there is a problem it is the pet owner’s failure to cater for the pet’s needs and inventing a Turdba just facilitates further neglect. Perhaps a robot to take the animal for a walk where it can find a nice piece of nature to dedicate in would be a more humane goal?

      1. It must be nice to sit on one’s high horse and preach about how someone should care for their pet. I happened to adopt a pet with a disability and there are occasional accidents despite my best efforts. I care for my pet but because of the kind of pet I chose to adopt, there are occasional accidents. Telling people like me that they are getting what they deserve for adopting a pet with special needs is reprehensible. Telling anyone that they are getting what they deserve because there is an occasional accident is nearly as bad. It must be wonderful being as perfect as you are….

    1. It must be nice to sit on one’s high horse and preach about how someone should care for their pet. I happened to adopt a pet with a disability and there are occasional accidents despite my best efforts. I care for my pet but because of the kind of pet I chose to adopt, there are occasional accidents. Telling people like me that they are getting what they deserve for adopting a pet with special needs is reprehensible. Telling anyone that they are getting what they deserve because there is an occasional accident is nearly as bad. It must be wonderful being as perfect as you are….

  19. I’m sure I’ve seen aerosol air-fresheners in public lavatories with bum-gas sensors that pump out one smell to cover another.* These must be able to differentiate the smell of fear from aerosol propellent and pot-pourri scent. One of those could be liberated from its task and attached to the cleaner to instigate an emergency stop before things get messy.

    In homes that have a Roomba running on a timer, there’s the “Roomba effect” where people habitually keep the floor clear of small items that might interfere with cleaning, leading to a tidier home. As a bonus, this might extend to keeping the air fresh to prevent smells interfering with cleaning.

    * Tear down mentioned here http://hackaday.com/2011/09/21/air-wick-odor-detect-teardown/, but the blog linked has gone.

  20. It can only be resolved by the use of a triple layer detecting system:
    Level one: Vision System == Looks like shit
    Level 2: Methanethiol detector == Smells like shit
    Level 3: Electrodes with reactive plating:==Taste like shit
    Then you can really take an educated decision…. Must be shit

  21. Perhaps detection is too expensive? Who knows what a bot will run over that will make a disastrous mess.

    Why not have a “verify” function. Is the carpet cleaner than when I started? Or oh crap, I’m making a mess and I should stop until someone finds me.

    Having a camera that detects the carpet before and after and doing some basic color checking should for most carpets provide a sanity check that the carpet is indeed cleaner than when the bot started. My guess is it would be pretty easy to learn what the homes carpet looks like on a typical basis. Likely pretty easy to learn that a big brown streak instead of the regular red/blue color is a problem. Maybe the bot will get two feet before it aborts, but better than the whole house.

  22. Free – I have a roomba which is in many pieces, after I got frustrated trying to clean it after an “accident”. I would rather it go to someone willing and able to clean it and put it back together, or use it for scientific purposes, rather than sending it to the dump. I’m in north-central Maryland. Text me at 443-370-3957 if interested in roomba.

  23. I didn’t read this entire chain too long to read all, but read most. How about an user adjustable undesirable/unknown object avoidance radius. Once identified the bot stays x distance away and then only time it targets or goes back to that “off limit radius” is after the bot sends a picture of it to the owner’s phone and the owner approves.

  24. Others may have said something similar in this thread but it seems pretty simple. The robot already maps the area during setup so I would suggest mapping the surface as well. Because more than just poop can cause a problem such as a stray sock or other flat-ish objects, surface mapping can avoid all sorts of mishaps. Using a front facing camera or a combination of camera and sonar, the surface can be mapped during the initial room setup. Then the stored information can be compared in near real-time to the original image so when a new “obstacle” presents itself, the robot can just simply navigate around whatever the new obstacle is. Programming the “something new is in my way so I need to go around it” logic is pretty straightforward as anyone who is familiar with Raspberry Pi could program it in pretty short order with access to the correct sensors.

  25. Dirt Detect uses acoustic sensors, nowadays it does it to insist in the area, but programming as well for another frequencies (wet, too wet) it could better stay away from the area (just as it avoids the stairs).

  26. Well, this is an obvious problem with an obvious solution.
    The Roomba Wet/Dry Steamvac.
    Give it a way to refill water and cleaning solution, and dump waste water, and an internal heating coil.
    Sensors in the brush can detect moisture and contaminants in the carpet just like it can detect when the floor is clean, so it knows if it’s encountered something like grape jelly or cat pee or dog poop. When it finds a wet mess, it uses its heating coils to boil up some water from its tank (remembering where the mess is and going for a recharge and refill first if needed) and blasts the steam and cleaning solution into the carpet until the sensors detect clean. Then it dries it for you and sucks the water up, and goes to dump the waste water. And then continues. Come back to spot- steam cleaned, sanitized, and dried carpets wherever your carpet is too dirty or messy.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.