added "fake_odom"(ground truth with noise)
authorHenrique Scharlau Coelho <henriquescharlaucoelho@gmail.com>
Tue, 19 Dec 2023 01:12:19 +0000 (22:12 -0300)
committerHenrique Scharlau Coelho <henriquescharlaucoelho@gmail.com>
Tue, 19 Dec 2023 01:12:19 +0000 (22:12 -0300)
twil_2dnav/launch/nav2_navigator.launch.xml
twil_description/xacro/twil.urdf.xacro

index 88174cc..6920046 100644 (file)
@@ -52,7 +52,7 @@
 
     <node pkg="robot_localization" exec="ekf_node" name="ekf_filter_node">
         <param name="use_sim_time" value="$(var use_sim_time)"/>
-        <param name="odom0" value="/ground_truth"/>
+        <param name="odom0" value="/fake_odom"/>
         <param from="$(find-pkg-share twil_2dnav)/config/ekf_params.yaml"/>
     </node>
 
index f22efb3..a0d9d3c 100644 (file)
                <!--update_rate>100</update_rate-->
        </plugin>
 
+       <plugin name="fake_odom" filename="libgazebo_ros_p3d.so">
+               <frame_name>map</frame_name>
+               <body_name>twil_origin</body_name>
+        <gaussian_noise>0.2</gaussian_noise>
+               <ros>
+                       <remapping>odom:=fake_odom</remapping>
+               </ros>
+       </plugin>
+
   </gazebo>
 
   <xacro:if value="$(arg gps)">