Redirect all Metavision Error messages

Redirect all Metavision Error messages

Hello,

I am trying to redirect all Metavision error messages from console, to spdlog logger, which is set up to log both in console and file.
Metavision::Camera has a add_runtime_error_callback, but that would work only for the camera error. 
  1. camera_.add_runtime_error_callback([](const Metavision::CameraException &e) {
  2.     spdlog::error("Camera runtime error: {}", e.what());
  3.     throw;
  4. });

Also I was able to get HAL USB errors if I disable the event camera while the program is runnung:

[HAL][ERROR] ErrTransfert
[HAL][ERROR] LIBUSB_TRANSFER_STALL
[HAL][ERROR] ErrTransfert
[HAL][ERROR] LIBUSB_TRANSFER_NO_DEVICE
[HAL][ERROR] LIBUSB_TRANSFER_NO_DEVICE
[HAL][ERROR] ErrTransfert
[HAL][ERROR] LIBUSB_TRANSFER_NO_DEVICE
[HAL][ERROR] LIBUSB_TRANSFER_NO_DEVICE
[HAL][ERROR] ErrTransfert
[HAL][ERROR] LIBUSB_TRANSFER_NO_DEVICE
[HAL][ERROR] LIBUSB_TRANSFER_NO_DEVICE
[HAL][ERROR] ErrTransfert
[HAL][ERROR] LIBUSB_TRANSFER_STALL
[HAL][ERROR] USB Submit Error
[HAL][ERROR] Resubmit Error after Error
[HAL][ERROR] LIBUSB_ERROR_IO
[HAL][ERROR] ErrTransfert
[HAL][ERROR] LIBUSB_TRANSFER_STALL

How redirect also these messages, and all other possible errors and warning from the Metavision Library?

    As a Prophesee customer, join the community conversation. 
    Request your free access today.

      Information

      In this Community Forum, you can discuss products, technology and applications. Only registred users can post but everyone can read. To ask a private question, enter a support ticket in My Area https://support.prophesee.ai/portal/en/newticket