ON THIS PAGE

  • Installation
  • Usage
  • Building OAK Apps without an OAK device
  • Example: Build the UVC C++ example on self-hosted oak-agent and install it on an OAK4 device

Self-hosted oak-agent

The oak-agent service can be self-hosted on amd64 and arm64 Linux machines. Self-hosted oak-agent requires Docker and systemd to be installed on the host.

Installation

Install the latest stable version by running:
Command Line
1curl -fsSL https://oakagent-releases.luxonis.com/self-hosted/stable/install-oak-agent.sh | sudo bash -s -- -y --password linux123

Usage

Find the host where oak-agent is installed by running oakctl device list:
Sh
1oakctl device list
2+---+------------------+--------------------------------+----------------------------------------+------------------------+---------------+-------------------+
3| # | Serial Number    | Device                         | Connection                             | OS                     | Agent Version | Setup             |
4+=============================================================================================================================================================+
5| 1 | 0e40028535f13370 | Raspberry Pi 5 Model B Rev 1.1 | 10.12.11.231, 10.12.102.35, 172.17.0.1 | Ubuntu 24.04.4 LTS     | 0.21.0        | Setup (unadopted) |
6+---+------------------+--------------------------------+----------------------------------------+------------------------+---------------+-------------------+
Manage the service with systemd:

Enable oak-agent

Sh
1sudo systemctl enable oak-agent

Disable oak-agent

Sh
1sudo systemctl disable oak-agent

Building OAK Apps without an OAK device

Self-hosted oak-agent can be used to build OAK Apps without an OAK4 device. This is useful for CI or for preparing .oakapp packages on a separate Linux host.If you want to install the built app on an OAK4 device afterward, the self-hosted agent must run on an arm64 Linux machine.

Example: Build the UVC C++ example on self-hosted oak-agent and install it on an OAK4 device

This example uses a Raspberry Pi 5 as the self-hosted oak-agent host and an OAK4 device as the deployment target.

Install the self-hosted agent on Raspberry Pi 5

List available devices and connect oakctl to the self-hosted agent

Sh
1oakctl device list
2+---+------------------+--------------------------------+----------------------------------------+------------------------+---------------+-------------------+
3| # | Serial Number    | Device                         | Connection                             | OS                     | Agent Version | Setup             |
4+=============================================================================================================================================================+
5| 1 | 0e40028535f13370 | Raspberry Pi 5 Model B Rev 1.1 | 10.12.11.231, 10.12.102.35, 172.17.0.1 | Ubuntu 24.04.4 LTS     | 0.21.0        | Setup (unadopted) |
6+---+------------------+--------------------------------+----------------------------------------+------------------------+---------------+-------------------+
7| 2 | 2795412959       | Luxonis, Inc. OAK4-D R9        | 10.12.102.126, 172.23.136.130          | Luxonis OS RVC4 1.32.1 | 0.20.0        | Setup (unadopted) |
8+---+------------------+--------------------------------+----------------------------------------+------------------------+---------------+-------------------+
9oakctl device connection set 1 # Connect to the first device

Clone the oak-examples repository

This repository contains the UVC C++ example.
Sh
1git clone --depth 1 --branch main https://github.com/luxonis/oak-examples
2cd oak-examples
3git submodule update --init --recursive

Build the UVC app

Sh
1cd cpp/uvc
2oakctl app build .

Install the built OAK App on the OAK4 device

Sh
1oakctl app install *.oakapp -d 2
The -d 2 argument selects the OAK4 device from the list above.

Check that the UVC app is running

Sh
1oakctl app list -d 2
2+---+--------+---------------------------------+---------+--------------+
3| E | App Id | Identifier                      | Status  | Frontend URL |
4+=======================================================================+
5| * | d4ed4  | com.example.streaming.uvc:3.0.0 | running |              |
6+---+--------+---------------------------------+---------+--------------+