> For the complete documentation index, see [llms.txt](https://docs.idew.org/code-robotics/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.idew.org/code-robotics/tutorials/detect-other-conditions.md).

# F. Detect Other Conditions

In this sixth tutorial, you'll learn how to make your robot detect other conditions (e.g., surface drop-offs, the robot's pitch and roll, when the robot is upside-down, when the robot is bumped, etc.) using its IR line sensors and accelerometer.

## Tutorial Goals <a href="#tutorial-goals" id="tutorial-goals"></a>

The goals of this tutorial are to help you:

* Program a robot app that uses the IR line sensors to detect a surface drop-off
* Program a robot app that uses the accelerometer to measure the robot's pitch and roll
* Program a robot app that uses the accelerometer to detect if the robot is upside down
* Program a robot app that uses the accelerometer to detect if the robot has been bumped
