3
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

ROS2 nav2 初期位置(Rvizの2D Pose Estimate)をコマンドで送信する

Last updated at Posted at 2022-06-29

参考

初期位置をコマンドから送信する

コマンド

ros2 topic pub -1 /initialpose geometry_msgs/PoseWithCovarianceStamped '{ header: {stamp: {sec: 0, nanosec: 0}, frame_id: "map"}, pose: { pose: {position: {x: 0.1, y: 0.0, z: 0.0}, orientation: {w: 0.1}}, } }'

上記コマンドの内、座標(x,y,z)と向き(w)で表されているので、
x:0.1、y:0.0、z:0.0、w:0.1
これを自分のロボットがいる位置と向きに合わせて送る。

自分の位置は一度Rvizで座標、向きを確認するのが早い。
xyz座標:Rvizの左メニュー内のTF-base_footprint-Position-x、y、zの値
w(向き):Rvizの左メニュー内のTF-base_footprint-Orientation-wの値

参考画像
Screenshot from 2022-06-29 13-50-51.png

3
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?