Linux x64#

This guide provides instructions for setting up the development environment and using ItalaApi on Linux x64 machines. When installing ItalaSDK on Linux x64, several components are provided to support camera integration and development.

  • ItalaView is a desktop application designed to demonstrate and test camera features interactively.

  • ItalaApi, which offers programming interfaces for C++, C, Python, and .NET, enabling developers to integrate camera functionality into a wide range of applications.

  • Itala GENTL producer as a .cti file, allowing third-party software to interface with Itala cameras using the GenICam standard.

  • oegevmodule, a kernel module that provides support for Itala cameras on Linux systems. It is not distributed with the SDK, but a script located in /opt/itala-sdk/scripts/oegevmodules is included to download and install it on your system.

Installing oegevmodule#

Install the module:

cd /opt/itala-sdk/scripts/oegevmodules; sudo ./install_oegevmodule.sh

Check if the module is correctly installed:

sudo lsmod | grep oegevmodule

The above command returns the list of modules installed with “oegevmodule” in the name. If the command return an empty string, the module is not correctly installed.

After these steps, itala-sdk and ItalaView can use the module. You can check oegevmodule activity from the kernel logs:

sudo dmesg

Uninstall the module

sudo ./uninstall_oegevmodule.sh

If SecureBoot is enabled on your system, the kernel module must be signed in order to load correctly. Here is a guide on how to create a key pair and sign the module.

Check if SecureBoot is enabled:

sudo mokutil --sb-state
  1. Generate a signing key pair

    openssl req -new -x509 -newkey rsa:2048 \
       -keyout MOK.key \
       -out MOK.crt \
       -nodes -days 36500 \
       -subj "/CN=Opto Engineering Module Signing/"
    

    Convert the certificate to DER format:

    openssl x509 -in MOK.crt -outform DER -out MOK.der
    
  2. Enroll the key (MOK)

    sudo mokutil --import MOK.der
    
    • Set a temporary password

    • Reboot the system

    During reboot:

    • Select “Enroll MOK”

    • Confirm enrollment

    • Enter the password

    Verify enrollment after reboot:

    mokutil --list-enrolled
    
  3. Download the Opto Engineering kernel module

    Download the correct module package for your system from: https://www.opto-e.com/en/resources/itala-drivers

    Make sure to select the version matching your Linux distribution and kernel version.

    Extract the Package:

    tar -xvf <module_package_name>.tar.gz
    cd <module_package_name>
    
  4. Sign the kernel module

    Locate the "sign-file" tool installed in the system kernel headers:

    find /usr/src -name sign-file
    

    Sign the module:

    /path/to/sign-file sha256 MOK.key MOK.der oegevmodule.ko
    

    Verify the signature:

    modinfo oegevmodule.ko | grep signer
    
  5. Install the kernel module

    Execute the commands below from the <module_package_name> decompressed directory referenced at point 3.

    Add execution permission:

    sudo chmod +x install.sh
    

    Run the installation script:

    sudo ./install.sh
    

Note

Keep your private key (MOK.key) secure

Warning

The oegevmodule is distributed as a precompiled binary, targeting a specific kernel version. Any time the OS kernel is updated, oegevmodule needs to be reinstalled. After running a command such as sudo apt update && sudo apt upgrade, check if the kernel module is still loaded using lsmod | grep oegevmodule. If the module is not listed, reinstall oegevmodule.

Shared library management#

The ItalaSDK installer automatically adds its shared library locations to the linker search path by creating a configuration file under /etc/ld.so.conf.d/. This ensures that the necessary .so files are found by the system at runtime.

Configuration by language#

The following sections outline the necessary steps for the different supported programming languages.

With CMake

ItalaApi can be easily integrated into a CMake project. You can make the package findable by either:

  • Adding the ItalaApi CMake export path to the CMAKE_PREFIX_PATH variable: /opt/itala-sdk/cmake.

  • Setting the ItalaApi_DIR variable to that same location.

After that, you can find the package and link against its targets in your CMakeLists.txt:

find_package(ItalaApi REQUIRED)
find_package(GenApi REQUIRED)

# ...

target_link_libraries(your_target PRIVATE ItalaApi::ItalaApi GenApi::GenApi)

A set of CMake samples under /opt/itala-sdk/samples demonstrates how to configure projects to use ItalaApi.

Without CMake

If you are not using CMake, configure your tools as follows:

  • Include Path: Point to the /opt/itala-sdk/include folder.

  • Linker: Compile your code against the following shared libraries located in /opt/itala-sdk: * libItalaApi.so * libGenApi_gcc7_v3_3_OptoE.so * libGCBase_gcc7_v3_3_OptoE.so * libLog_gcc7_v3_3_OptoE.so

For users without a CMake installation, a sample Makefile is available under samples/ItalaApi/_Makefiles. It compiles and links all samples, placing the executables in the same directory. Note that this file is not relocatable.

With CMake

ItalaApiC can be easily integrated into a CMake project. You can make the package findable by either:

  • Adding the ItalaApiC CMake export path to the CMAKE_PREFIX_PATH variable: /opt/itala-sdk/cmake.

  • Setting the ItalaApiC_DIR variable to that same location.

Then, call find_package(ItalaApiC) in your CMakeLists.txt to make the target available for linking.

A set of CMake samples under /opt/itala-sdk/samples demonstrates how to configure projects to use ItalaApiC.

Without CMake

If you are not using CMake, configure your tools as follows:

  • Include Path: Point to the /opt/itala-sdk/include folder.

  • Linker: Compile your code against the libItalaApiC.so shared library available under /opt/itala-sdk.

For users without a CMake installation, a sample Makefile is available under samples/ItalaApiC/_Makefiles. It compiles and links all samples, placing the executables in the same directory. Note that this file is not relocatable.

On Linux, ItalaApiNET must be referenced manually in your project. When using the dotnet CLI, you can reference ItalaApiNET.dll inside your .csproj file using the <HintPath> tag.

<Reference Include="ItalaApiNET">
  <HintPath>/opt/itala-sdk/bin/ItalaApiNET.dll</HintPath>
</Reference>

Warning

ItalaApiNET.dll depends on other native shared libraries installed by the ItalaSDK. These libraries must be kept in the same folder as the DLL for the application to work correctly.

To use ItalaApiPython, you must install the itala wheel package using pip. The wheel file is located under /opt/itala-sdk/bindings.

Run the following command from the bindings directory to install the package:

.../bindings> python -m pip install itala-1.0.0-....whl

To use the API in your code, import the itala module from the itala package:

from itala import itala

ItalaView#

To launch from terminal ItalaView:

cd /opt/itala-sdk/application; ./ItalaView.Linux.x64

Hardware configuration#

For hardware or network configuration instructions, please refer to the camera’s manual.