Sensors use slave-master protocols for interfacing with microcontrollers and microcomputers. Among many different slave-master protocols, I2C and SPI protocols are the common serial communication protocols widely found in embedded devices. Both protocols let the microcontroller/microcomputer take the master role and allow interfacing of several sensors and embedded blocks on a common bus. This tutorial will discuss the implementation of the I2C protocol in MicroPython and explore how sensors are interfaced with ESP8266 and ESP32 using the I2C bus. Learn more about the I2C protocol before continuing this tutorial.