Overview

            DepthAI device (eg. OAK-D)                                  Host (eg. RaspberryPi)
┌───────────────────────────────────────────────┐                   ┌─────────────────────────┐
│                                               │                   │                         │
│       Node                            Node    │                   │ # Your python code that │
│  ┌─────────────┐                   ┌──────────┤                   │ # runs on the host      │
│  │             │                   │          │                   │                         │
│  │             │preview       input│          │   XLink protocol  │ # Get the frame         │
│  │ ColorCamera ├───────────────────┤ XLinkOut ├──────────────────►│ data=q_preview.get()    │
│  │             │     ImgFrame      │          │(USB/Ethernet/PCIe)│ frame=data.getCvFrame() │
│  │             │     Message       │          │                   │ # Show the frame        │
│  └─────────────┘                   └──────────┤                   │ cv2.imshow("rgb",frame) │
│ inputControl ▲                                │                   │                         │
│              │                                │                   │                         │
│              │                        Node    │                   │                         │
│              │                      ┌─────────┤                   │ # Control the camera    │
│              │                      │         │                   │ cc=dai.CameraControl()  │
│              │                  out │         │   XLink protocol  │ cc.setManualFocus(100)  │
│              └──────────────────────┤ XLinkIn │◄──────────────────┤ q_cam_control.send(cc)  │
│                  CameraControl      │         │(USB/Ethernet/PCIe)│                         │
│                     Message         │         │                   │                         │
│                                     └─────────┤                   │                         │
│                                               │                   │                         │
└───────────────────────────────────────────────┘                   └─────────────────────────┘
                                A simple pipeline visualzied

Device

Device is the DepthAI module itself. On the device there is a powerful vision processing unit (VPU) from Intel, called Myriad X (MX for short). The VPU is optimized for performing AI inference algorithms and for processing sensory inputs (eg. calculating stereo disparity from two cameras).

For more details, click here

Pipeline

The upper flowchart is a simple pipeline visualized. So a pipeline is collection of nodes and links between them.

For more details, click here

Nodes

Each node provides a specific functionality on the DepthAI, a set of configurable properties and inputs/outputs. On the flowchart above, we have 3 nodes; ColorCamera, XLinkOut and XLinkIn.

For more details, click here

Messages

Messages are sent between linked nodes. On the flowchart above, there are two links - visualized as arrows that are inside the device. There are a few different types of messages, on the chart we have ImgFrame and CameraControl

For more details, click here

Got questions?

We’re always happy to help with code or other questions you might have.