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

How can I control digital IOs for motoman?

asked 2018-12-05 03:50:12 -0500

Marco Braun gravatar image

updated 2018-12-06 04:17:47 -0500

Hi,

I need to control the IOs of the DX100 controller. I control the robot with the latest motoman driver package (kinetic-devel). I just looked into the code and saw that there are functions implemented for reading and setting digital IOs via simple message protocol but there is nothing like a service call implemented. Do I have to programm my own cpp-node to control the IOs? A code sample would be very helpful.

Thanks in advance!

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-12-06 04:27:45 -0500

gvdhoorn gravatar image

updated 2018-12-18 06:45:39 -0500

The 'final pieces' that expose a ROS service server for the code you found in motoman_driver are missing in kinetic-devel.

I have a candidate for that here (warning: that branch is quite old) but it hasn't yet made it into the mainline code.

After that, "controlling IOs" is as simple as calling a service, which is about 5 lines of Python (or C++, but you asked for Python before your latest edit) and would be similar in structure to the "writing a simple service client (Python)" tutorial.


Edit:

Is there any documentation which address belongs to which IO at the DX100?

That would be the manufacturers documentation (ie: Motoman) for the DX100 controller. The ROS services don't do anything different/special here, so just use the addresses you would normally use with MotoPlus.

I looked at the new service-files, the value is specified as int32. I think, value should be either 1 or 0, shouldn't it?

For digital IO elements: yes. But for analogue IO elements you'll want to specify a floating point/fixed integer value (as they typically connect to/gate voltage sources) so that's why there is an int32.

edit flag offensive delete link more

Comments

Thank you very much for the quick answer! That's what I was looking for.

Marco Braun gravatar image Marco Braun  ( 2018-12-06 04:55:39 -0500 )edit

I merged the pullrequest. Now everything compiles and the new services are advertised. Is there any documentation which address belongs to which IO at the DX100? I looked at the new service-files, the value is specified as int32. I think, value should be either 1 or 0, shouldn't it?

Marco Braun gravatar image Marco Braun  ( 2018-12-18 05:31:32 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2018-12-05 03:50:12 -0500

Seen: 623 times

Last updated: Dec 18 '18