Hardware Layer Library

The provided Prophesee plugin allows application developers to access device-specific implementation of facilities. This can be useful for cases where the camera hardware is known and there is a need to leverage a functionality not exposed through the generic API of Metavision HAL.

To do this, the application should link to metavision_psee_hw_layer library:

find_package(MetavisionPSEEHWLayer REQUIRED)
target_link_libraries(<your_app> PRIVATE Metavision::PSEEHWLayer)

Device-specific definitions of the facilities are accessible along Metavision headers under psee_hw_layer/devices/ folder.

In the application code, the facility can be retrieved and casted towards the actual class used in the plugin:

#include <metavision/psee_hw_layer/devices/imx636/imx636_ll_biases.h>

(...)

Metavision::I_LL_Biases ll_biases = device->get_facility<Metavision::I_LL_Biases>();
// Get actual device implementation
Metavision::Imx636_LL_Biases *imx636_ll_biases = dynamic_cast<Metavision::Imx636_LL_Biases *>(ll_biases);

A complete sample demonstrating this use case can be found in <install-prefix>/share/metavision/hal_psee_plugins/cpp_samples/metavision_imx636_facility_casting_sample/.

In order to run applications using metavision_psee_hw_layer, the library path should be updated to include the folder containing the metavision_psee_hw_layer shared library:

Linux

export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/path/to/plugins

Windows

set PATH=%PATH%;C:\path\to\plugins\

Note that metavision_psee_hw_layer is delivered along with Prophesee plugin for each release of Metavision SDK. If you build an application that is using metavision_psee_hw_layer, make sure to use the shared library shipped with the plugin that will be used to run the application (if you use a library shipped with another version of the Prophesee plugin, it might end up in an undefined behaviour).

Warning

psee_hw_library is not a stable API. Applications relying on it might not have the same behaviour from one version of the library to another. Its current purpose is to help with prototyping and/or debugging when features are not yet accessible through the HAL API.

Note

This hardware layer library is a design choice made by Prophesee to enable more user flexibility in using the device. Other plugin developers can opt not to follow this choice.