ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Error connecting Staubli CS8 robot to ROS

asked 2015-02-11 15:06:26 -0500

ROSkinect gravatar image

updated 2015-02-12 05:08:08 -0500

Hi there !

I have a robot Staubli tx60 and I want to connect it with ROS, I have a package for that but it doesn't work: I get this message:

[ERROR] [1423580378.785944834]: Failed to connect to Staubli CS8 Controller.

image description

This message comes from the package not from ROS.

in the other side I have my CS8 emulator in other machine in windows7:

image description

The objectif is to connect CS8 Emulator that has an IP address with ROS using a package

Anyone worked with CS8 emulator in ROS ?

This is the package that I use.

edit retag flag offensive close merge delete

Comments

There is probably more output on the console than just this single error? Could you update your post with some more context as well?

gvdhoorn gravatar image gvdhoorn  ( 2015-02-12 01:47:35 -0500 )edit

@gvdhoorn I just edit my question and add more information

ROSkinect gravatar image ROSkinect  ( 2015-02-12 03:27:53 -0500 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2015-02-12 07:55:54 -0500

ROSkinect gravatar image

I did some modification in main function:

instead of:

if ( argc<2 || (strstr(argv[1],"http://")!=argv[1]) || !strstr(argv[1],":800/") )

I use

if ( argc<2 || (strstr(argv[1],"http://")!=argv[1]) )

And it works !

edit flag offensive delete link more

Comments

1

Yes that first line doesn't really make sense. Nice to hear that it works now. You should accept your own answer, to mark it answered.

gvdhoorn gravatar image gvdhoorn  ( 2015-02-12 09:16:42 -0500 )edit
1

answered 2015-02-12 03:52:45 -0500

gvdhoorn gravatar image

updated 2015-02-12 05:44:36 -0500

Are you sure you correctly configured the IP address for the staubli node to connect to (in controller.h)?

According to your screenshot, the node is trying to connect to 10.1.22.254, but your CS8 emulator shows its using 10.1.22.64? I'm not 100% sure the simulator reports the IP of the pc it's running on, but in any case you should check that the ROS node is using the correct address.


Edit: check firewall settings on the Windows machine. It might be that the emulator is only allowed to accept traffic on private or public networks. Disabling it would give a quick way to test this (but please do return it to a working state afterwards).


Edit2:

Looking at the source in the archive you linked, two things stand out:

 ROS_INFO("* * * * * * * * * * * * * * * * * * * * * * * * *");
 ROS_INFO("* MAKE SURE CS8 CONTROLLER IS IN NETWORKED MODE *");
 ROS_INFO("* * * * * * * * * * * * * * * * * * * * * * * * *");

And:

if(staubli.Login( url, "default", ""))
{
    ROS_INFO("Connected to Staubli CS8 Controller.");
}
else
{
    ROS_ERROR("Failed to connect to Staubli CS8 Controller.");
}

So:

  1. Is the controller in Networked Mode
  2. I'm guessing the Login(..) method uses some sort of username/password combination. Has that info been changed on the controller perhaps? Is the password for default still "" (an empty string)?
edit flag offensive delete link more

Comments

Sorry I uploaded the wrong photo, Now it's OK !

I'm not using the package that has (controller.h) because I got lot of errors when I compile it, I use another one that you can download it, up there in the end of my question.

The PC and CS8 have the same address: 10.1.22.64 and ROS has 10.1.16.15

ROSkinect gravatar image ROSkinect  ( 2015-02-12 04:39:58 -0500 )edit

If you don't use the cu-ros-pkg, why do you link to the PDF?

Also: have you checked your firewall settings?

gvdhoorn gravatar image gvdhoorn  ( 2015-02-12 04:48:17 -0500 )edit

My firewall is deactivated in both side in Ubuntu and Windows 7.

The PDF explains what I want exactly, but I can delete it if my question is clear enough

ROSkinect gravatar image ROSkinect  ( 2015-02-12 05:07:48 -0500 )edit

Does nc 10.1.22.64 800 work? Or do you get a connection refused error?

gvdhoorn gravatar image gvdhoorn  ( 2015-02-12 05:41:46 -0500 )edit

no, it doesn't BUT I did some modification in main function: instead of:

if ( argc<2 || (strstr(argv[1],"http://")!=argv[1]) || !strstr(argv[1],":800/") )

I use

if ( argc<2 || (strstr(argv[1],"http://")!=argv[1]) )

I get

ROSkinect gravatar image ROSkinect  ( 2015-02-12 07:05:24 -0500 )edit

I don't know how it will influence the package working ! do you know what !strstr(argv[1],":800/") exactly means in the program !?

*Yes the controller in Networked Mode *for the login/password I don't really have any login or password !

ROSkinect gravatar image ROSkinect  ( 2015-02-12 07:07:47 -0500 )edit
1

no, it doesn't

If netcat can't connect to port 800 on your Windows machine, then I think that is something you should check.

Also: please update your original question with any new information. The comments don't allow for too much discussion and / or copy/pasting console text.

gvdhoorn gravatar image gvdhoorn  ( 2015-02-12 07:33:42 -0500 )edit

then I have to look for the port in my windows machine ?

ROSkinect gravatar image ROSkinect  ( 2015-02-12 07:55:49 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2015-02-11 15:06:26 -0500

Seen: 1,223 times

Last updated: Feb 12 '15