Enable I2C and Camera Interface

Here we are using the Raspberry Pi’s I2C and Camera interfaces, but by default they are disabled, so we need to enable them first.

  1. Input the following command:

    sudo raspi-config
  2. Choose 3 Interfacing Options by press the down arrow key on your keyboard, then press the Enter key.

  3. Then P5 I2C.

  4. Use the arrow keys on the keyboard to select <Yes> -> <OK> to complete the setup of the I2C.

  5. Go to 3 Interfacing Options again and select P1 Camera.

  6. Again select <Yes> -> <OK> to complete the setup.

  7. After you select <Finish>, a pop-up will remind you that you need to reboot for the settings to take effect, select <Yes>.