Platform
  • RVC
  • Features
  • Depth
  • Deployment
  • Camera Sensors
  • Environmental Specifications
  • Comparisons

ON THIS PAGE

  • Code

FSYNC Y-Adapter

Based on
RVC
Dot projector
No
Infrared
No
IMU
None

Looking for more details? Visit specific features at Platform -> Features

Overview

FSYNC Y-adapter allows users to easily hardware synchronize multiple devices that have M8 auxiliary connector. If cameras are hardware synchronized, they will all start sensor exposure at the same time for each frame.Devices that have M8 auxiliary connector can be split into two groups based on wiring and voltage requirements - Newer and Older devices:
Device groupDevice ListFSYNC capabilityFSYNC voltage on M8
Older devicesSupport only external FSYNC signal from function generator10V-24V FSYNC signal
Newer devicesSupport external FSYNC signal both from from function generator AND other OAK devices5V FSYNC signal
All devices listed above are compatible with the FSYNC Y-Adapter.

FSYNC results

To demonstrate the FSYNC functionality, we threw an object past six OAK4-D cameras stacked vertically. We recorded the same test twice: first with the cameras synchronized, then unsynchronized.
In the synchronized recording, the flying object appears in the same position across all camera streams.
In the unsynchronized recording, the streams are misaligned, which is marked with red indicators in the image.The streams are black and white to reduce bandwidth when recording six cameras simultaneously at 60 FPS.

External FSYNC Signal from OAK Device

If you have multiple Newer devices, you can FSYNC daisy-chain them using the wiring schematic below. In this configuration, only one OAK device acts as the "FSYNC Master," while all others run as "FSYNC Slave." If you need more than 3 devices in one chain, cumulative internal resistance may reduce signal integrity and prevent reliable operation. For larger setups, contact us at support@luxonis.com.
The device with no cable connected to the "IN" port (M8 female connector) automatically outputs the internal FSYNC signal and acts as the "FSYNC Master" for other devices in the chain. Devices with a cable connected to the "IN" port act as "FSYNC Slave." On OAK Thermal and OAK-D ToF this works with all depthai versions, and on OAK4 devices it works starting with depthai 3.4.0.

Code

You can find runnable python and C++ code examples in our git repository. If you strip it down to the essential FSYNC setup, these are the key lines that matter most:
Python
1# Get role (MASTER / SLAVE)
2role = device.getExternalFrameSyncRole()
3
4# Master defines FPS, slaves follow
5cam = pipeline.create(dai.node.Camera).build(
6    socket,
7    sensorFps=fps if role == dai.ExternalFrameSyncRole.MASTER else None
8)
9
10# Create Sync node (runs on host)
11sync = pipeline.create(dai.node.Sync)
12sync.setRunOnHost(True)
13sync.setSyncThreshold(datetime.timedelta(milliseconds=1000 / (2 * fps)))
14
15# Link camera outputs into sync
16cam.requestOutput(...).link(sync.inputs["cam"])
17
18# IMPORTANT: start master first, then slaves
19master_pipeline.start()
20slave_pipeline.start()
Concepts by steps:
  • Get role → getExternalFrameSyncRole()
  • Master sets FPS, slaves don't
  • Use Sync node on host PC
  • Link all camera streams into it
  • Master pipeline must start before slaves
everything else in the example scripts is just plumbing for multi-device handling.For more in-depth information on data synchronization, visit this page.

External FSYNC Signal from Function Generator

You can also trigger FSYNC with an external signal (for example, from a signal generator). Older devices require 10V-24V on the FSYNC line, while Newer devices require a 5V trigger signal.

Wiring diagram

Photo of the wiring

Make sure that the LOW level is 0V, and that HIGH voltage is above 10V for Older devices and above 5V for Newer devices. Also note that ~5 microseconds pulse is required by OV9x82 sensor, while IMX sensors will get triggered even at ~500 ns pulse.

BNC to M8 adapter

We made our own BNC to M8 adapter by splitting one BNC to BNC cable and one M8 to M8 cable. We then used that to connect the signal generator (BNC) to the FSYNC Y-adapter (M8).The signal line (BNC core) has to be connected to pin 1 of the M8 cable (FSYNC line). GND from the BNC connector (so the shielding around it) has to be connected to both pin 3 (GPIO3/5V -DETECT/ISOLATED FSYNC GND) and pin 8 (GND) of the M8 cable. If GPIO3 is not connected to the ground, the camera on the first FSYNC Y-adapter won't work, only the cameras after it will be synced together. This is because the first FSYNC Y-adapter will pull the GPIO3 to GND, as seen in the schematics below.

Code

Older devices

Python
1# One needs to set the FSYNC mode to INPUT to all camera's sensors:
2cam1 = pipeline.create(dai.node.MonoCamera)
3cam1.initialControl.setFrameSyncMode(dai.CameraControl.FrameSyncMode.INPUT)
4
5cam2 = pipeline.create(dai.node.ColorCamera)
6cam2.initialControl.setFrameSyncMode(dai.CameraControl.FrameSyncMode.INPUT)
7# ...

Newer devices

If you strip it down to the few lines that matter, here they are:
Python
1# No need to get role, all devices are slaves
2cam = pipeline.create(dai.node.Camera).build(
3    socket
4)
5
6# Create Sync node (runs on host)
7sync = pipeline.create(dai.node.Sync)
8sync.setRunOnHost(True)
9sync.setSyncThreshold(datetime.timedelta(milliseconds=1000 / (2 * fps)))
10
11# Link camera outputs into sync
12cam.requestOutput(...).link(sync.inputs["cam"])
13
14# start all slaves
15slave_pipeline.start()
  • All cameras are slaves → no FPS set, they follow an external sync signal
  • Sync node runs on host to combine streams across devices
  • setSyncThreshold(...) defines how close timestamps must be to count as synced
  • Camera outputs are linked into sync inputs for grouping
  • Start all pipelines → cameras wait for external trigger and Sync groups frames
For more in-depth information on data synchronization, visit this page.

Dimensions and Weight

  • Weight: 5g
  • Width: 23.5 mm
  • Height: 33 mm
  • Length: 10 mm