FPGA · Firmware

VGA/HDMI video capture card over PCIe Gen2 x4

An M.2 capture card that takes VGA or HDMI, processes the video in a 10-bit pipeline on an Artix-7, and streams it to the host over PCIe Gen2 x4.

  • 10-bitvideo pipeline
  • Gen2 x4PCIe
  • 2inputs: VGA and HDMI

Architecture · block diagram

  • Main data path
  • Logic
  • Processor
  • Memory
  • Interconnect
  • Off-chip
M.2 video capture card: VGA/HDMI capture, 10-bit video pipeline with DDR3 frame buffer, PCIe Gen2 x4 DMAARTIX-7 · M.2 2280VGA inHDMI incapture10-bitcolor spacecrop · scaledeinterlaceDDR3frame bufferPCIe DMAGen2 x4HDMI audioembeddedhostPCIe Gen2 x4MCUI2C · EDID · card-ID · FW update
FIG. 01

The story

A capture card must accept a wide range of sources: analog VGA, or HDMI in different formats, interlaced or progressive, with embedded audio. It then delivers processed frames to the host. An M.2 2280 card has little board space. The FPGA handles the video processing, and a small MCU handles board management.

Challenges

Two different input types share one pipeline. Interlaced sources must come out progressive. Cards already in the field also needed firmware updates without a return to the factory.

What I built

Both inputs feed a capture stage that converts them to a common 10-bit format. The pipeline then runs color-space conversion, cropping and scaling, and deinterlacing. A DDR3 frame buffer holds the frames that the scaler and the deinterlacer need. A PCIe DMA engine streams finished frames to the host over Gen2 x4. The card also captures HDMI embedded audio with the video.

The MCU handles EDID emulation, which advertises the supported modes to the source. It also manages I2C, card-ID strapping and field firmware updates.

The hardest problem

Deinterlacing and scaling both need neighboring lines and fields. The DDR3 frame buffer holds that history without a stall in capture. A 10-bit pipeline avoids banding through color conversion and scaling.

The field-update path had to be fail-safe, because a failed update on a deployed card means a return. The MCU firmware updates cards that are already installed in customers' machines.

Result

The card captures VGA and HDMI, with HDMI audio, and streams over PCIe Gen2 x4. Color-space conversion, cropping, scaling and deinterlacing run in 10 bits on the FPGA. The MCU handles EDID emulation, card-ID strapping and field firmware updates.

Where it's used

Where you'd find something like this

01

KVM and remote server management

02

Capturing video from legacy and industrial equipment

03

Medical and industrial display recording, streaming

Available · Asia/Dhaka (UTC+6)

Have hardware that needs to work?

Tell me what you're building. I'll come back with questions, a rough scope and an estimate, usually within 2 days.

PAD 01 · I/O