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

Set init position & yaw angle in the same frame as /hydrus/uav/cog/odom topic in simulator #537

Open
HarukiKozukapenguin opened this issue Nov 26, 2022 · 0 comments

Comments

@HarukiKozukapenguin
Copy link
Contributor

HarukiKozukapenguin commented Nov 26, 2022

I'm now using HYDRUS simulator following this instruction
I now want to set initial position and initial yaw as I want by setting spawn_x, spawn_y, spawn_yaw in bringup.launch
in the following coordinate:, which is the same coordinate as /hydrus/uav/cog/odom topic

  • position is CoG of hydrus
  • yaw is the direction of link2

But, I found that this initial position and yaw angle is "initial edge of link1 before changing the servo angle set in Servo.yaml (before this change, all link is 0 deg)"

So, I tuned the initial position in the following way

  1. set joint angle in Servo.yaml file
  2. launch w/o any spawn argument, and check initial yaw angle by rostopic echo /hydrus/uav/cog/odom
  3. launch again by setting argument spawn_yaw = -(2's yaw angle) , and check initial position by rostopic echo /hydrus/uav/cog/odom
  4. launch again by setting argument spawn_x:=-(3's x) spawn_y:=-(3's y) spawn_yaw:= -(2's yaw angle) and the hydrus show up in the origin and yaw direction is link2 direction

In the above algorithm, it is difficult to set initial spwawn position as I want in the desired coodinate, so, in my personal code, I make new argument in bringup.launch (init_(x,y,yaw)_error) to tune and spawn easily now.

Question
Is there any other ways to set initial position in /hydrus/uav/cog/odom coodinate?

@HarukiKozukapenguin HarukiKozukapenguin changed the title Set init position & yaw angle from CoG of HYDRUS's link2's frame Set init position & yaw angle in the same frame as /hydrus/uav/cog/odom topic in simulator Nov 26, 2022
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