Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Error Handling & Logging

Error Types

Each crate defines its own error type:

  • GenicamError – high-level facade errors
  • GigeError – GVCP/GVSP transport errors
  • GenApiError – node evaluation and register I/O errors
  • GenCpError – GenCP protocol encoding errors
  • XmlError – XML parsing errors

All error types implement std::error::Error and Display.

Logging

The workspace uses the tracing crate for structured logging. Enable it with:

#![allow(unused)]
fn main() {
tracing_subscriber::fmt::init();
}

Or set RUST_LOG=debug to see detailed protocol traces.