Thanks for sharing your post. If you don’t mind, I have a few follow-up questions that could help us troubleshoot:
- Did you get a chance to test this skill before Misty took the latest update? If so, did she behave any differently?
- Are you seeing any error messages on Misty’s display (a “Hardware Heartbeat Failure” message, or something similar?)
- What type of floor(s) are you working on?
- Describe the lighting in the room (i.e. windows, time of day, room lighting)
- Have you done a visual inspection of ToF covers (for scratches, dust, etc.)?
That your skill performs as expected when you disable hazards would indicate you’re getting false positives that prevent Misty from backing up. The
SignalFail status code is fairly innocuous, and isn’t likely to be the culprit; that status code indicates the sensor isn’t getting enough “pings” back to get a valid reading, which typically happens when an obstacle is too small or too far away. My understanding is that
SignalFail code in and of itself doesn’t trigger the hazards system.
Misty’s time-of-flight sensors are powerful hardware but do perform differently depending on Misty’s environment. (I know from reading other threads that you’ve been testing in a few locations. ) Debris like dust or pet hair can also accrue on the sensor covers, which could interfere with getting accurate readings. It’s a good practice to regularly clean the ToF sensor covers by blowing them clean with low-pressure compressed air.
The “sweet spot” for accurate ToF readings is within ~1.2 meters of the robot; as distance values get larger, the readings become less reliable. That said, certain environmental conditions can trigger false positives in the hazard system, even when obstacles are well outside the 1.2 meter range. We are working to provide more tools and better educational materials to support developers who want to understand the sensors better and dig in when they’re not behaving as expected. Some of this information should appear in the forums within the next few days.
To try and pin down the reading that’s preventing Misty from moving, you might do the following:
- Try connecting Misty to the Command Center and subscribing to time-of-flight data before you run the code you shared above. Make sure Misty’s hazard system is set to its default settings. Watch the readings as your robot drives, and if Misty doesn’t move as expected, check to see if the distance readings are accurate.
- You could also try running the skill while streaming event messages from the
HazardNotification WebSocket connection. When Misty doesn’t drive, this message would tell you exactly which hazard state caused her to ignore the locomotion command. A quick way to stream
HazardNotification data is by using a tool like Simple Websocket Client.