5.1.4 Logical camera – configuration

Course subject(s) Module 5. Robot Vision

In the previous lecture, we learned how to add a logical camera to our factory simulation in Gazebo. This lecture, we will learn how to configure a few parameters of the logical camera so we can use the information it provides. You can follow along the instructions in this video in the context of the download files for this module.

In hrwros.world:

  • We can see some work is already done for us.
  • The conveyor model:
    • It has a pose where the first three entries indicate the position of the camera with respect to a fixed reference frame, such as the world.
    • The last three entries indicate the orientation of the camera using the same reference.
    • The orientation is defined using normal Euler1 angles: Roll, Pitch, Yaw. The conventions here get confusing quickly, so we will always provide you these orientations during the course.

In the models folder:

  • A model for the logical camera already exists (in your weekly downloads, you will have two models, logical_camera1 and logical_camera2).
  • It has a model.config, and a model.sdf file.
    • The .config files contain administrative information.
    • We explored the .sdf files in the last lecture.
  • In the model.sdf file:
    • It has a name unique to the camera. Different cameras will need different, unique names!
    • The plugin specification simulates the functionality of the camera.
    • The namespace is a prefix to the ROS topics published by the logical camera.
    • It is also possible to implement camera noise, but we won’t use that in this course.
    • There is also a (unique!) link name like for ‘normal’ robots in the world.
    • Lastly, there is a sensor element, which has a name and a type. The name should again be unique!
    • These unique names will be used when the topics will be published, so pay attention.
    • The sensor element defines all information about the camera properties, such as FOV and aspect ratios.
Creative Commons License
Hello (Real) World with ROS - Robot Operating System by TU Delft OpenCourseWare is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
Based on a work at https://online-learning.tudelft.nl/courses/hello-real-world-with-ros-robot-operating-systems//.
Back to top