Hi Thien
Thank you for your reply . In order to set the calibration data I followed your instructions at Precision Landing with ROS, Realsense T265 Camera and AprilTag 3 - Part 2⁄2.
I have almost setup my non-GPS flight drone, and I am looking for a safe indoor location to try it
Thank you guys , I am really grateful for your help and hope to contribute when I will gain experience.
Regards
gian
anyone i have some problems.
when i run roslaunch vision_to_mavros apriltags_to_mavros.launch
it’s shows “camera odom frame doesnt exist”, here’s the output :
SUMMARY
CLEAR PARAMETERS
- /apriltag_ros_continuous_node/
PARAMETERS
- /apriltag_ros_continuous_node/camera_frame: usb_cam
- /apriltag_ros_continuous_node/max_hamming_dist: 2
- /apriltag_ros_continuous_node/publish_tag_detections_image: True
- /apriltag_ros_continuous_node/publish_tf: True
- /apriltag_ros_continuous_node/standalone_tags:
- /apriltag_ros_continuous_node/tag_blur: 0.0
- /apriltag_ros_continuous_node/tag_bundles: [{‘name’: 'a3_bun…
- /apriltag_ros_continuous_node/tag_debug: 0
- /apriltag_ros_continuous_node/tag_decimate: 1.0
- /apriltag_ros_continuous_node/tag_family: tag36h11
- /apriltag_ros_continuous_node/tag_refine_edges: 1
- /apriltag_ros_continuous_node/tag_threads: 2
- /apriltag_ros_continuous_node/transport_hint: raw
- /apriltags_to_mavros/source_frame_id: usb_cam
- /apriltags_to_mavros/target_frame_id: a3_bundle
- /rosdistro: noetic
- /rosversion: 1.16.0
- /usb_cam/camera_frame_id: usb_cam
- /usb_cam/camera_info_url: file:///home/buv/…
- /usb_cam/camera_name: usb_cam
- /usb_cam/image_height: 480
- /usb_cam/image_width: 640
- /usb_cam/io_method: mmap
- /usb_cam/pixel_format: yuyv
- /usb_cam/video_device: /dev/video0
NODES
/
apriltag_ros_continuous_node (apriltag_ros/apriltag_ros_continuous_node)
apriltags_to_mavros (vision_to_mavros/vision_to_mavros_node)
usb_cam (usb_cam/usb_cam_node)
/usb_cam/
image_proc (image_proc/image_proc)
ROS_MASTER_URI=http://localhost:11311
process[usb_cam-1]: started with pid [3079]
process[usb_cam/image_proc-2]: started with pid [3080]
process[apriltag_ros_continuous_node-3]: started with pid [3081]
process[apriltags_to_mavros-4]: started with pid [3087]
[ INFO] [1700593740.284116499]: Initializing nodelet with 4 worker threads.
[ WARN] [1700593740.342449071]: Using default target_frame_id: /camera_odom_frame
[ WARN] [1700593740.359391722]: Using default source_frame_id: /camera_link
[ WARN] [1700593740.368333904]: Using default output_rate: 20.000000
[ WARN] [1700593740.373328442]: Using default gamma_world: -1.570796
[ WARN] [1700593740.379981271]: Using default roll_cam: 0.000000
[ WARN] [1700593740.383671261]: Using default pitch_cam: 0.000000
[ WARN] [1700593740.386560511]: Using default yaw_cam: 1.570796
[ INFO] [1700593740.394872057]: Precision landing disabled by default
[ INFO] [1700593741.273298336]: Loading tag bundle ‘a3_bundle’
[ INFO] [1700593741.273794498]: 0) id: 0, size: 0.078, p = [0,0,0], q = [1,0,0,0]
[ INFO] [1700593741.274017913]: 1) id: 1, size: 0.078, p = [0.095,0,0], q = [1,0,0,0]
[ INFO] [1700593741.274188590]: 2) id: 2, size: 0.078, p = [0.191,0,0], q = [1,0,0,0]
[ INFO] [1700593741.274344453]: 3) id: 3, size: 0.078, p = [0,-0.097,0], q = [1,0,0,0]
[ INFO] [1700593741.274519000]: 4) id: 4, size: 0.078, p = [0.095,-0.097,0], q = [1,0,0,0]
[ INFO] [1700593741.274665789]: 5) id: 5, size: 0.078, p = [0.191,-0.097,0], q = [1,0,0,0]
[ INFO] [1700593741.274792617]: 6) id: 6, size: 0.078, p = [0,-0.197,0], q = [1,0,0,0]
[ INFO] [1700593741.274910907]: 7) id: 7, size: 0.078, p = [0.095,-0.197,0], q = [1,0,0,0]
[ INFO] [1700593741.275035494]: 8) id: 8, size: 0.078, p = [0.191,-0.197,0], q = [1,0,0,0]
[ INFO] [1700593741.275137563]: 9) id: 9, size: 0.078, p = [0,-0.295,0], q = [1,0,0,0]
[ INFO] [1700593741.275244058]: 10) id: 10, size: 0.078, p = [0.095,-0.295,0], q = [1,0,0,0]
[ INFO] [1700593741.275361293]: 11) id: 11, size: 0.078, p = [0.191,-0.295,0], q = [1,0,0,0]
[ WARN] [1700593741.300778413]: remove_duplicates parameter not provided. Defaulting to true
[ INFO] [1700593741.922037383]: camera calibration URL: file:///home/buv/.ros/camera_info/head_camera.yaml
[ INFO] [1700593741.935996513]: Starting ‘usb_cam’ (/dev/video0) at 640x480 via mmap (yuyv) at 30 FPS
[ WARN] [1700593742.355470841]: unknown control ‘focus_auto’
[ INFO] [1700593742.490196643]: Camera model: fx = 572.913, fy = 650.912, cx = -22.6092, cy = 198.355
[ WARN] [1700593743.403325429]: “camera_odom_frame” passed to lookupTransform argument target_frame does not exist.
i already change the parameter target_frame and source_frame, here’s my launch file :
<!-- This node description you can take from usb_cam-test.launch -->
<node name="$(arg cam_name)" pkg="usb_cam" type="usb_cam_node" output="screen" >
<param name="video_device" value="/dev/video0" />
<param name="image_width" value="640" />
<param name="image_height" value="480" />
<param name="pixel_format" value="yuyv" />
<param name="camera_frame_id" value="usb_cam" />
<param name="camera_name" value="$(arg cam_name)" />
<param name="camera_info_url" value="file:///home/buv/.ros/camera_info/head_camera.yaml" />
<param name="io_method" value="mmap"/>
</node>
<!-- This node provides image rectification -->
<node name="image_proc" pkg="image_proc" type="image_proc" ns="$(arg cam_name)"/>
<!-- This node will launch apriltag_ros -->
<arg name="launch_prefix" default="" />
<arg name="node_namespace" default="apriltag_ros_continuous_node" />
<arg name="camera_name" default="/$(arg cam_name)" />
<arg name="camera_frame" default="usb_cam" />
<arg name="image_topic" default="image_raw" />
<!-- Set parameters -->
<rosparam command="load" file="$(find apriltag_ros)/config/settings.yaml" ns="$(arg node_namespace)" />
<rosparam command="load" file="$(find apriltag_ros)/config/tags.yaml" ns="$(arg node_namespace)" />
<node pkg="apriltag_ros" type="apriltag_ros_continuous_node" name="$(arg node_namespace)" clear_params="true" output="screen" launch-prefix="$(arg launch_prefix)" >
<remap from="image_rect" to="$(arg camera_name)/$(arg image_topic)" />
<remap from="camera_info" to="$(arg camera_name)/camera_info" />
<param name="camera_frame" type="str" value="usb_cam" />
<param name="publish_tag_detections_image" type="bool" value="true" />
</node>
<!-- This node will launch frame conversion from vision pose (tf) to mavros pose -->
<node pkg="vision_to_mavros" type="vision_to_mavros_node" name="apriltags_to_mavros" output="screen" >
<param name="target_frame_id" value="$(arg tag_name)" />
<param name="source_frame_id" value="$(arg cam_name)" />
<remap from="vision_pose" to="/mavros/vision_pose/pose" />
</node>
i dont know why it’s still using default camera_odom_frame and camera_link