In this chapter, we will build a spying eye. In more detail, we will build a project that uses an Android Things board to control a camera and a servomotor that we will use to rotate the camera. Through this project, we will learn how to use PWM pins. The Pulse Width Modulation (PWM) pin is a different kind of pin that we will use to control different types of peripherals such as servo motors. In more details, in this chapter we will explore:
- How to use PWM pins in Android Things
- How to control servo motors
- How to use cameras
At the end of this chapter, we will build a fully working Android Things system that is able to acquire images using the camera and, at the same time, we will be able to control the camera direction using a servo motor.