Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enumeration TriggerMode not available #87

Open
linzha0 opened this issue Jan 28, 2022 · 0 comments
Open

Enumeration TriggerMode not available #87

linzha0 opened this issue Jan 28, 2022 · 0 comments

Comments

@linzha0
Copy link

linzha0 commented Jan 28, 2022

Hi, I have a stereo-camera system (2 flir blackfly s usb3 cameras). I use one as primary camera and the other one as secondary camera (Master-slave mode). Use MCU trigger primary camera, use primary camera's exposure state as trigger signal for secondary camera.

I use following launch file to start stereo-camera. Every thing seems working fine, when I change trigger rate in MCU, I can find two camera frame rate change as I set. Also, both camera exposure time are look same (expect camera system jitter).

Launch file:

<?xml version="1.0"?>

<launch>
  <!-- Common parameters -->
  <arg name="camera_name" default="rov/sensors/stereo" />
  <arg name="camera_manager" default="stereo_camera_manager" />
  <!-- Right = primary, Left = secondary -->
  <arg name="right_camera_serial" default="20181913" />
  <arg name="right_camera_calibrated" default="0" />
  <arg name="left_camera_serial" default="20181918" />
  <arg name="left_camera_calibrated" default="0" />
  <arg name="start_delay_right" default="3.0" />


  <node pkg="nodelet" type="nodelet" name="$(arg camera_manager)"
        args="manager" output="screen" required="true" >
        <param name="num_worker_threads" value="4" />
  </node>


  <group ns="$(arg camera_name)" >
    <group ns="right" >

      <node pkg="nodelet" type="nodelet" name="camera_nodelet"
            args="load spinnaker_camera_driver/SpinnakerCameraNodelet /$(arg camera_manager)" 
            launch-prefix="bash -c 'sleep $(arg start_delay_right); $0 $@'" >
            
        <!-- +++++++++++ Basic +++++++++++ -->
        <param name="frame_id" value="right_camera" />
        <param name="serial" value="$(arg right_camera_serial)" />
        <param name="image_format_color_coding" value="BGR8" />       <!-- BayerRG8 -->

        <!-- +++++++++++ Acquisition +++++++++++ -->
        <param name="acquisition_mode" value="Continuous" />          <!-- Continuous: acquires image continously -->
        <param name="acquisition_frame_rate_enable" value="False" />  <!--False: controlled by trigger -->
        <!-- <param name="acquisition_frame_rate" value="20" />           Value: image captured by given framte rate -->

        <!-- +++++++++++ Trigger +++++++++++  -->
        <param name="trigger_source" value="Line3" />                 <!-- Line3: Green color and Pin 1 -->
        <param name="enable_trigger" value="On" />
        <param name="trigger_activation_mode" value="RisingEdge" />
        <!-- +++++++++++ Exposure +++++++++++ -->
        <param name="exposure_mode" value="Timed" />                  <!-- Timed: exposure time in a specified value -->
        <param name="exposure_auto" value="Continuous" />             <!-- Off: given fixed exposure time; Continuous: auto exposure time -->
        <param name="auto_exposure_time_upper_limit" value="5500" /> 
        <param name="auto_exposure_time_lower_limit" value="1000" />
        <!-- <param name="exposure_time" value="5000" />                  exposure time in microseconds -->
        <param name="line_selector" value="Line2" />                  <!--Line2: Red color and Pin 3-->
        <param name="line_mode" value="Output" />                     <!--Output: output exposure state-->
        <param name="line_source" value="ExposureActive" />           <!--ExposureActive: indicates when the image sensor is exposing-->
        <param name="line_inverter" value="False"/>

        <!-- +++++++++++ Analog +++++++++++ -->
        <param name="auto_gain" value="Continuous" />
        <param name="auto_white_balance" value="Continuous" />

        <!-- +++++++++++ Calibration +++++++++++ -->
          <!-- Use the camera_calibration package to create this file -->
          <!-- <param name="camera_info_url" if="$(arg right_camera_calibrated)"
              value="file://$(env HOME)/.ros/camera_info/$(arg right_camera_serial).yaml" /> -->
      </node>

    </group> <!-- end of group "right" -->

    <group ns="left" >

      <node pkg="nodelet" type="nodelet" name="camera_nodelet"
            args="load spinnaker_camera_driver/SpinnakerCameraNodelet /$(arg camera_manager)" >
            
        <!-- +++++++++++ Basic +++++++++++ -->
        <param name="frame_id" value="left_camera" />
        <param name="serial" value="$(arg left_camera_serial)" />
        <param name="image_format_color_coding" value="BGR8" />       <!-- BayerRG8 -->

        <!-- +++++++++++ Acquisition +++++++++++ -->
        <param name="acquisition_mode" value="Continuous" />          <!-- Continuous: acquires image continously -->
        <param name="acquisition_frame_rate_enable" value="False" />  <!--False: controlled by trigger -->
        <!-- <param name="acquisition_frame_rate" value="20" />           Value: image captured by given framte rate -->

        <!-- +++++++++++ Trigger +++++++++++  -->
        <param name="trigger_source" value="Line3" />                 <!-- Line3: Green color and Pin 1 -->
        <param name="enable_trigger" value="On" />
        <param name="trigger_activation_mode" value="RisingEdge" />
        <param name="trigger_overlap_mode" value="ReadOut" />

        <!-- +++++++++++ Exposure  +++++++++++ -->
        <param name="exposure_mode" value="TriggerWidth" />           <!-- Timed: exposure time in a specified value; TriggerWidth: same as primary camera -->
        <!-- <param name="exposure_auto" value="Off" />           Off: given fixed exposure time; Continuous: auto exposure time -->
        <!-- <param name="auto_exposure_time_upper_limit" value="10000" /> --> 
        <!-- <param name="auto_exposure_time_lower_limit" value="300" /> -->
        <!-- <param name="exposure_time" value="3000" />                 exposure time in microseconds -->
        <param name="line_selector" value="Line2" />                   <!-- Line2: Red color and Pin 3 -->
        <param name="line_mode" value="Output" />                      <!-- Output: output exposure state -->
        <param name="line_source" value="ExposureActive" />            <!-- ExposureActive: indicates when the image sensor is exposing -->
        <param name="line_inverter" value="False"/>

        <!-- +++++++++++ Analog +++++++++++ -->
        <param name="auto_gain" value="Continuous" />
        <param name="auto_white_balance" value="Continuous" />

        <!-- Calibration -->
        <!-- Use the camera_calibration package to create this file -->
        <!-- <param name="camera_info_url" if="$(arg left_camera_calibrated)"
               value="file://$(env HOME)/.ros/camera_info/$(arg left_camera_serial).yaml" /> -->
      </node>
 
      
    </group> <!-- end of group "left" -->

  </group> <!-- end of group "rov/sensors/stereo" -->

</launch>

However, I found the secondary camera has a warning:

[ WARN] [1517155368.152494293]: [SpinnakerCamera]: (20181918) Enumeration TriggerMode not available.

I don't why is this come from? The secondary camera output is below, I can see the TriggerMode setup is processed twice, and second setup process cased this warning.

[ INFO] [1517155367.620637249]: [SpinnakerCamera]: (20181918) BinningHorizontal set to 1.
[ INFO] [1517155367.630002278]: [SpinnakerCamera]: (20181918) BinningVertical set to 1.
[ INFO] [1517155367.638626422]: [SpinnakerCamera]: (20181918) DecimationHorizontal set to 1.
[ INFO] [1517155367.647655396]: [SpinnakerCamera]: (20181918) DecimationVertical set to 1.
[ INFO] [1517155367.653561507]: [SpinnakerCamera]: (20181918) OffsetX set to 0.
[ INFO] [1517155367.658148698]: [SpinnakerCamera]: (20181918) OffsetY set to 0.
[ INFO] [1517155367.663546767]: [SpinnakerCamera]: (20181918) Width set to 1616.
[ INFO] [1517155367.668263397]: [SpinnakerCamera]: (20181918) Height set to 1240.
[ INFO] [1517155367.672312823]: [SpinnakerCamera]: (20181918) OffsetX set to 0.
[ INFO] [1517155367.675959150]: [SpinnakerCamera]: (20181918) OffsetY set to 0.
[ INFO] [1517155367.684918451]: [SpinnakerCamera]: (20181918) PixelFormat set to BGR8.
[ INFO] [1517155367.687783076]: [SpinnakerCamera]: (20181918) AcquisitionFrameRateEnable set to 1.
[ INFO] [1517155367.692248715]: [SpinnakerCamera]: (20181918) AcquisitionFrameRate set to 9.99935.
[ INFO] [1517155367.695046456]: [SpinnakerCamera]: (20181918) AcquisitionFrameRateEnable set to 0.
[ INFO] [1517155367.697960812]: [SpinnakerCamera]: (20181918) TriggerMode set to Off.
[ INFO] [1517155367.700327335]: [SpinnakerCamera]: (20181918) TriggerSource set to Line3.
[ INFO] [1517155367.700980752]: [SpinnakerCamera]: (20181918) TriggerSelector set to FrameStart.
[ INFO] [1517155367.703373727]: [SpinnakerCamera]: (20181918) TriggerActivation set to RisingEdge.
[ INFO] [1517155367.705400091]: [SpinnakerCamera]: (20181918) TriggerMode set to On.
[ INFO] [1517155367.706998764]: [SpinnakerCamera]: (20181918) LineSelector set to Line2.
[ INFO] [1517155367.708921083]: [SpinnakerCamera]: (20181918) LineMode set to Output.
[ INFO] [1517155367.710987302]: [SpinnakerCamera]: (20181918) LineSource set to ExposureActive.
[ INFO] [1517155367.712004283]: [SpinnakerCamera]: (20181918) LineInverter set to 0.
[ INFO] [1517155367.714010063]: [SpinnakerCamera]: (20181918) ExposureMode set to TriggerWidth.
[ INFO] [1517155367.717270060]: [SpinnakerCamera]: (20181918) ExposureAuto set to Continuous.
[ INFO] [1517155367.718477016]: [SpinnakerCamera]: (20181918) SharpeningEnable set to 0.
[ INFO] [1517155367.719554854]: [SpinnakerCamera]: (20181918) SaturationEnable set to 0.
[ INFO] [1517155367.721591318]: [SpinnakerCamera]: (20181918) AutoExposureExposureTimeUpperLimit set to 5000.
[ INFO] [1517155367.722248133]: [SpinnakerCamera]: (20181918) GainSelector set to All.
[ INFO] [1517155367.725972085]: [SpinnakerCamera]: (20181918) GainAuto set to Continuous.
[ INFO] [1517155367.729330549]: [SpinnakerCamera]: (20181918) BlackLevel set to 1.7.
[ INFO] [1517155367.730712346]: [SpinnakerCamera]: (20181918) GammaEnable set to 1.
[ INFO] [1517155367.733309692]: [SpinnakerCamera]: (20181918) Gamma set to 1.
[ INFO] [1517155367.737149456]: [SpinnakerCamera]: (20181918) BalanceWhiteAuto set to Continuous.
[ INFO] [1517155367.863459450]: devicePoll
[ INFO] [1517155368.073567504]: [SpinnakerCamera]: (20181918) BinningHorizontal set to 1.
[ INFO] [1517155368.082702864]: [SpinnakerCamera]: (20181918) BinningVertical set to 1.
[ INFO] [1517155368.090565057]: [SpinnakerCamera]: (20181918) DecimationHorizontal set to 1.
[ INFO] [1517155368.098278958]: [SpinnakerCamera]: (20181918) DecimationVertical set to 1.
[ INFO] [1517155368.103432738]: [SpinnakerCamera]: (20181918) OffsetX set to 0.
[ INFO] [1517155368.107335154]: [SpinnakerCamera]: (20181918) OffsetY set to 0.
[ INFO] [1517155368.111795406]: [SpinnakerCamera]: (20181918) Width set to 1616.
[ INFO] [1517155368.115756466]: [SpinnakerCamera]: (20181918) Height set to 1240.
[ INFO] [1517155368.119603925]: [SpinnakerCamera]: (20181918) OffsetX set to 0.
[ INFO] [1517155368.123237972]: [SpinnakerCamera]: (20181918) OffsetY set to 0.
[ INFO] [1517155368.131168332]: [SpinnakerCamera]: (20181918) PixelFormat set to BGR8.
[ INFO] [1517155368.133387492]: [SpinnakerCamera]: (20181918) AcquisitionFrameRateEnable set to 1.
[ INFO] [1517155368.143458168]: [SpinnakerCamera]: (20181918) AcquisitionFrameRate set to 9.99935.
[ INFO] [1517155368.145961634]: [SpinnakerCamera]: (20181918) AcquisitionFrameRateEnable set to 0.

[ WARN] [1517155368.147043030]: [SpinnakerCamera]: (20181918) Enumeration TriggerMode not available.

[ INFO] [1517155368.149143044]: [SpinnakerCamera]: (20181918) TriggerSource set to Line3.
[ INFO] [1517155368.149475091]: [SpinnakerCamera]: (20181918) TriggerSelector set to FrameStart.
[ INFO] [1517155368.151953354]: [SpinnakerCamera]: (20181918) TriggerActivation set to RisingEdge.

[ WARN] [1517155368.152494293]: [SpinnakerCamera]: (20181918) Enumeration TriggerMode not available.

[ INFO] [1517155368.153380937]: [SpinnakerCamera]: (20181918) LineSelector set to Line2.
[ INFO] [1517155368.155167917]: [SpinnakerCamera]: (20181918) LineMode set to Output.
[ INFO] [1517155368.156854540]: [SpinnakerCamera]: (20181918) LineSource set to ExposureActive.
[ INFO] [1517155368.157734194]: [SpinnakerCamera]: (20181918) LineInverter set to 0.
[ INFO] [1517155368.159028074]: [SpinnakerCamera]: (20181918) ExposureMode set to TriggerWidth.
[ INFO] [1517155368.161325725]: [SpinnakerCamera]: (20181918) ExposureAuto set to Continuous.
[ INFO] [1517155368.162597994]: [SpinnakerCamera]: (20181918) SharpeningEnable set to 0.
[ INFO] [1517155368.163781288]: [SpinnakerCamera]: (20181918) SaturationEnable set to 0.
[ INFO] [1517155368.165277358]: [SpinnakerCamera]: (20181918) AutoExposureExposureTimeUpperLimit set to 5000.
[ INFO] [1517155368.166048543]: [SpinnakerCamera]: (20181918) GainSelector set to All.
[ INFO] [1517155368.168656855]: [SpinnakerCamera]: (20181918) GainAuto set to Continuous.
[ INFO] [1517155368.171032388]: [SpinnakerCamera]: (20181918) BlackLevel set to 1.7.
[ INFO] [1517155368.171999992]: [SpinnakerCamera]: (20181918) GammaEnable set to 1.
[ INFO] [1517155368.173630921]: [SpinnakerCamera]: (20181918) Gamma set to 1.
[ INFO] [1517155368.176634444]: [SpinnakerCamera]: (20181918) BalanceWhiteAuto set to Continuous.
[ INFO] [1517155368.313266939]: [SpinnakerCamera::connect]: Detected device type: USB3Vision
[ INFO] [1517155368.941746277]: [SpinnakerCamera::connect]: Camera model name: Blackfly S BFS-U3-19S4C
[ INFO] [1517155368.947454334]: [SpinnakerCamera]: (20181913) DeviceLinkThroughputLimit set to 500000000.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant