EEC180/181 Tutorial: Using the D8M-GPIO 8-Megapixel Camera

EEC180/181, Digital Systems Design


  1. Overview
  2. This tutorial describes and provides the code for a starter design that uses a basic method to receive data from a D8M-GPIO 8-megapixel camera connected to the DE1-SoC board through the GPIO interface.

    The Terasic D8M-GPIO is an 8-megapixel camera kit with a 2x20 pin GPIO connector interface. It includes a MIPI camera module and a MIPI decoder. The MIPI camera module captures images and sends them out in a MIPI video signal package. This packet is converted into a 10-bit parallel Bayer pattern through a MIPI decoder. The data is transmitted through a 2x20 pin GPIO connector. The MIPI camera module has a built-in Voice Coil Motor (VCM) to control its focal length. Users can adjust the focus via the I2C interface.

  3. Setup
  4. Connect an external display to the DE1-SoC board with a standard VGA cable.

    Set the monitor's ratio to 4:3 so the image will appear properly proportioned.

    Connect the D8M camera to the DE1-SoC board into the outermost GPIO expansion port (GPIO 1) and the camera face toward the outside of the board. Carefully make sure all the pins are secure and inserted fully into the connectors. Make sure the camera is fully pushed into the GPIO expansion slot. It should be a snug fit, be careful not to break the boards by pressing too hard.

    Program the DE1-SoC board with the sample project, you should see the camera video on the display.

  5. Description and Code
  6. camera.pdf, overview of the hardware to interface with the camera port

    DE1_D8M.v5.zip, verilog source code

      Because they are used so often, the top-level module also includes ports for the LED and HEX displays, the SW switches, and the KEY push buttons; as well as very simple code to turn the LED and HEX displays off by default.

      Because the VGA display will very often be used when the camera is being used, the VGA port interface is also included in this starter code.

  7. Common Pitfalls
  8. Reference material
  9. camera.zip has some additional logic for the camera output but it is not utilized in the top level so its exact purpose is unclear.



EEC 181 | B. Baas | ECE Dept. | UC Davis
2022/04/11  Written
2022/05/10  Updated camera.zip
2022/05/25  Added first pitfall
2025/02/20  Moved camera.zip to the new Reference section. Added DE1_D8M.v5.zip which was previously used for only Lab 5.
Written by Ziyuan Dong and Bevan Baas