In this chapter we have learned how PWM works and how it encodes information in both the frequency and the duty cycle. We have seen how the frequency is key to working with a passive buzzer and learned to manipulate it directly. We also learned how servos use PWM in a special way and how to modify the configuration to match the specs of a target servo. Finally, we have learned how to use PWM as analog output with a simple circuit.
So far we have used single direction protocols. Let's step up a level and start working with bidirectional communication with I2C, which also supports multiple devices on the same bus. This will be the focus of the next chapter.