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

FIX Invalid argument ERROR migration from tf to tf2 #63

Open
wants to merge 1 commit into
base: lunar-devel
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Introduction
This Fork is to fix error **Invalid argument passed to lookupTransform argument source_frame in tf2** which cased by **migration from tf to tf2**

This issues was described [here](https://github.com/rst-tu-dortmund/teb_local_planner_tutorials/issues/9)
# Using
- Create catkit workspace:
```
$ mkdir -p ~/catkin_ws/src
$ cd ~/catkin_ws/
$ catkin_make
```
- Build only stage_ros and it's dependencies:
```
$ cd ~/catkin_ws/src
$ git clone https://github.com/AMRobots/stage_ros.git
$ cd ../
catkin_make --only-pkg-with-deps stage_ros
```
8 changes: 4 additions & 4 deletions src/stageros.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -183,11 +183,11 @@ StageNode::mapName(const char *name, size_t robotID, Stg::Model* mod) const

if ((found==std::string::npos) && umn)
{
snprintf(buf, sizeof(buf), "/%s/%s", ((Stg::Ancestor *) mod)->Token(), name);
snprintf(buf, sizeof(buf), "%s/%s", ((Stg::Ancestor *) mod)->Token(), name);
}
else
{
snprintf(buf, sizeof(buf), "/robot_%u/%s", (unsigned int)robotID, name);
snprintf(buf, sizeof(buf), "robot_%u/%s", (unsigned int)robotID, name);
}

return buf;
Expand All @@ -209,11 +209,11 @@ StageNode::mapName(const char *name, size_t robotID, size_t deviceID, Stg::Model

if ((found==std::string::npos) && umn)
{
snprintf(buf, sizeof(buf), "/%s/%s_%u", ((Stg::Ancestor *) mod)->Token(), name, (unsigned int)deviceID);
snprintf(buf, sizeof(buf), "%s/%s_%u", ((Stg::Ancestor *) mod)->Token(), name, (unsigned int)deviceID);
}
else
{
snprintf(buf, sizeof(buf), "/robot_%u/%s_%u", (unsigned int)robotID, name, (unsigned int)deviceID);
snprintf(buf, sizeof(buf), "robot_%u/%s_%u", (unsigned int)robotID, name, (unsigned int)deviceID);
}

return buf;
Expand Down