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

Connection issues between ROS Melodic and Optitrack Streaming Engine #59

Open
geothan opened this issue Mar 19, 2021 · 7 comments
Open

Comments

@geothan
Copy link

geothan commented Mar 19, 2021

I can't retrieve the pose of a 3D object in ROS . I have 2 computers, one with Windows 10 and one with Ubuntu 18.

The Windows PC has Motive: Tracker 2.2.0 with the following settings in Optitrack Streaming Engine:

  1. Bradcase Frame Data: On
  2. Local Interface: the computer's IP, not loopback
  3. Rigid Bodies: On
  4. Transmission Type: Multicast
  5. Command Port: 1510
  6. Data Port: 1511
  7. Multicast Interface: 239.255.42.99

The Linux PC has ROS Melodic and with following installation steps:
cd ~/catkin_ws/src
git clone https://github.com/ros-drivers/mocap_optitrack.git
cd ..
catkin build

The project was built with the below modifications:

  1. Command Port: 1510
  2. Data Port: 1511
  3. Multicast Interface: 239.255.42.99

I run the following command :
roslaunch mocap_optitrack mocap.launch

and get the below:

roslaunch mocap_optitrack mocap.launch
... logging to /home/george/.ros/log/0bbc8108-88c0-11eb-a872-000c2978f07e/roslaunch-ubuntu-69992.log
Checking log directory for disk usage. This may take a while.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://ubuntu:38971/

SUMMARY

PARAMETERS

  • /mocap_node/optitrack_config/command_port: 1510
  • /mocap_node/optitrack_config/data_port: 1511
  • /mocap_node/optitrack_config/enable_optitrack: True
  • /mocap_node/optitrack_config/multicast_address: 239.255.42.99
  • /mocap_node/rigid_bodies/1/child_frame_id: Robot_1/base_link
  • /mocap_node/rigid_bodies/1/odom: Robot_1/Odom
  • /mocap_node/rigid_bodies/1/parent_frame_id: world
  • /mocap_node/rigid_bodies/1/pose2d: Robot_1/ground_pose
  • /mocap_node/rigid_bodies/1/pose: Robot_1/pose
  • /mocap_node/rigid_bodies/1/tf: tf
  • /mocap_node/rigid_bodies/2/child_frame_id: Robot_2/base_link
  • /mocap_node/rigid_bodies/2/odom: Robot_2/Odom
  • /mocap_node/rigid_bodies/2/parent_frame_id: world
  • /mocap_node/rigid_bodies/2/pose2d: Robot_2/ground_pose
  • /mocap_node/rigid_bodies/2/pose: Robot_2/pose
  • /mocap_node/rigid_bodies/2/tf: tf
  • /rosdistro: melodic
  • /rosversion: 1.14.10

NODES
/
mocap_node (mocap_optitrack/mocap_node)

auto-starting new master
process[master]: started with pid [70002]
ROS_MASTER_URI=http://localhost:11311

setting /run_id to 0bbc8108-88c0-11eb-a872-000c2978f07e
process[rosout-1]: started with pid [70013]
started core service [/rosout]
process[mocap_node-2]: started with pid [70020]
[ WARN] [1616164398.362593479]: Could not get server version, using auto

@jadhm
Copy link

jadhm commented Mar 22, 2021

@geothan Hi, did you define the the id streaming of the rigidbody ? because what you see in the config yaml file of this package that there are 2 rgigbodies are defines the first one with the streaming id 1 and the other is 2 so please make sure that the rigigbody in motive has the streaming id of 1 or 2

image

@geothan
Copy link
Author

geothan commented Mar 24, 2021

Hi @jadhm!

i think that i i've defined properly the streaming ID.

motive

I redownload and built the driver optitrack succesfully, making the below change:

Screenshot from 2021-03-24 12-38-50

I executed the following:

Screenshot from 2021-03-24 12-41-06

Could the specific driver not be compatibe with motive 2.2? Can i define server version? Generally, linux and windows computers see each other through ip ping. Windows PC is connected through Ethernet and Linux PC wirelessly in router.

@jadhm
Copy link

jadhm commented Mar 24, 2021

Hi @geothan
That's weird but it should work because I am also using motive 2.2.0 and the driver is compatible with it. could you please try to launch it using --screen so I can see the initialization logs
roslaunch mocap_optitrack mocap.launch --screen

and if you try rostopic list would you see the all the topics ?

@geothan
Copy link
Author

geothan commented Mar 24, 2021

Hi @jadhm ,

Here is a screenshot of launch file execution:

Screenshot from 2021-03-24 17-03-15

The result of topics is the following:

Screenshot from 2021-03-24 17-10-05

The first time that i tried the above settings, topics of robot1 weren't visible only parameter_descriptions and parameter_updates topics. These topics are empty, is that normal?

Screenshot from 2021-03-24 17-21-28

Finally, when i run
roslaunch mocap_optitrack mocap.launch & rosrun rviz rviz

Shall i see my robot in rviz? Because i see an empty world.

Screenshot from 2021-03-24 17-25-35

@jadhm
Copy link

jadhm commented Mar 25, 2021

It seems it works just fine ! I see that you can read the topic /mocap_node/Robot_1/pose which is basically the position of the tracked object. So I don't think you have any problems and for visualizing the pose in RVIZ you should add the topic manually and also configure the Fixed frame.

@lixryjz
Copy link

lixryjz commented Dec 18, 2021

hi,yet I am very happy to see that, but i have down the fixed frame and add topic as you said in RVIZ,there is only a red line with an arrow.can you tell me how to do?i hope you can screenshot

@chennuo0125-HIT
Copy link

@geothan @lixryjz the problem has been solved ? i get same problem as follows:

[ WARN] [1679050884.023240442]: Could not get server version, using auto

and no more print

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

4 participants