Skip to main content

Crate hailort_sys

Crate hailort_sys 

Source
Expand description

Raw FFI bindings to the HailoRT runtime library.

These bindings mirror the C API declared in <hailo/hailort.h> from the hailo-ai/hailort open-source project. They give Rust code direct access to the Hailo AI HAT+ on Raspberry Pi.

§Safety

Every function in the ffi module is unsafe. Callers must uphold all invariants described in the upstream C API documentation: https://hailo.ai/developer-zone/

§Linking

The build.rs script attempts pkg-config first, then falls back to searching /usr/lib and /usr/local/lib for libhailort.so.

§Module layout

ModuleContents
constantsSizing limits and default parameter values
handlesOpaque C handle types
statushailo_status return code and all error constants
enumsAll other C enum type aliases and their variants
typesStructs, unions, and callback type aliases
ffiunsafe extern "C" function declarations

Re-exports§

pub use constants::*;
pub use enums::*;
pub use ffi::*;
pub use handles::*;
pub use status::*;
pub use types::*;

Modules§

constants
Sizing limits, array capacities, and default parameter values.
enums
C enum type aliases and their named variant constants.
ffi
Raw extern "C" declarations for every public HailoRT function.
handles
Opaque C handle types.
status
hailo_status return-code type and every named status constant.
types
Structs, unions, and callback type aliases.