ros_control HW interfaces for UR5

427 views
Skip to first unread message

Antoine Rennuit

unread,
Aug 27, 2014, 9:55:58 AM8/27/14
to swri-ros...@googlegroups.com
Hello,

I am not sure I understand were the ros_control hardware_interfaces for the UR5 motor drivers are setup. My best guess is in file ur5.transmission.xacro, can anyone confirm? If this is the right location, then I have 2 questions:

  • Where are the input and output of these hardware_interfaces specified, I could not find any code for this...
  • Knowing that the UR5 is proprietary and we do not have access to the internals of the motor drivers, how could it be determines that the hardware_interface to use is EffortJointInterface, as stated in file ur5.transmission.xacro?

Thanks,

Antoine.

Shaun Edwards

unread,
Aug 27, 2014, 3:51:22 PM8/27/14
to swri-ros...@googlegroups.com
Antoine,

Are you talking about controlling a real(physical) robot or a simulated robot in gazebo?

Shaun


--
You received this message because you are subscribed to the Google Groups "swri-ros-pkg-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to swri-ros-pkg-d...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Antoine Rennuit

unread,
Aug 28, 2014, 10:26:52 AM8/28/14
to swri-ros...@googlegroups.com
Hello Shaun,

I am asking for the real life robot (I figured out from ur_gazebo/controllerarm_controller_ur5.yaml that the simulation uses effort_controllers/JointTrajectoryController).

File ur5.transmission.xacro shows that effort controllers are used as EffortJointInterface are instanciated (both in simulation and in real life), but I do not understand how you guys could figure out the real physical universal robot is using effort controllers (as the ur is a proprietary black box).

Also I could not find where the arguments for the hardware interface are configured and updated in code. From the EffortJointInterface code here, arguments const JointStateHandle& js and double* cmd should be provided to te interface and the command be updated at each time step, no?

Does anyone have a better view than me on these points?

Thanks ;)

Antoine.

G.A. vd. Hoorn - 3ME

unread,
Aug 28, 2014, 10:44:02 AM8/28/14
to swri-ros...@googlegroups.com
On 28-8-2014 16:26, Antoine Rennuit wrote:
> Hello Shaun,
>
> I am asking for the real life robot (I figured out from
> *ur_gazebo/controllerarm_controller_ur5.yaml* that the simulation uses
> *effort_controllers/JointTrajectoryController*).
>
> File *ur5.transmission.xacro *shows that effort controllers are used as
> *EffortJointInterface* are instanciated (both in simulation and in real
> life), but I do not understand how you guys could figure out the real
> physical universal robot is using effort controllers (as the ur is a
> proprietary black box).
>
> Also I could not find where the arguments for the hardware interface are
> configured and updated in code. From the *EffortJointInterface*
> <http://docs.ros.org/hydro/api/hardware_interface/html/c++/joint__command__interface_8h_source.html>
> code here
> <http://docs.ros.org/hydro/api/hardware_interface/html/c++/joint__command__interface_8h_source.html>,
> arguments *const JointStateHandle
> <http://docs.ros.org/hydro/api/hardware_interface/html/c++/classhardware__interface_1_1JointStateHandle.html>**&
> js* and *double* cmd* should be provided to te interface and the command be
> updated at each time step, no?
>
> Does anyone have a better view than me on these points?

Antoine,

the released ur_driver package [1] does not use anything from
ros_control or any of its other packages. The elements in the xacro are
for simulation only.

The interface to the UR controller is implemented in URScript, with a
custom binary protocol [2]. The ROS side is a Python script that
implements the same protocol, and actually uploads the URScript program
each time your (re)start the node [3].

There is another interface to the UR controller that is based on
ros_control and hw_interface etc, written and maintained by Kelsey
Hawkins (see [4]). This combines the C-API provided by Universal Robot
with custom C++ classes and a different binary protocol (called
simple_message, [5]) to drive the robot. See [6] for some more
information on how this interface was designed and implemented.

Hope this clears up some of your confusion.


Gijs


[1]
https://github.com/ros-industrial/universal_robot/tree/hydro-devel/ur_driver
[2]
https://github.com/ros-industrial/universal_robot/blob/hydro-devel/ur_driver/prog
[3]
https://github.com/ros-industrial/universal_robot/blob/hydro-devel/ur_driver/src/ur_driver/driver.py
[4] https://github.com/ros-industrial/universal_robot/tree/hydro-devel-c-api
[5] http://wiki.ros.org/simple_message
[6] http://www.kelseyhawkins.com/images/ur_c_api_contribution.pdf


> Thanks ;)
>
> Antoine.
>
> Le mercredi 27 août 2014 21:51:22 UTC+2, Shaun Edwards a écrit :
>> Antoine,
>>
>> Are you talking about controlling a real(physical) robot or a simulated
>> robot in gazebo?
>>
>> Shaun
>>
>>
>> On Wed, Aug 27, 2014 at 8:55 AM, Antoine Rennuit <antoine...@gmail.com
>> <javascript:>> wrote:
>>
>>> Hello,
>>>
>>> I am not sure I understand were the ros_control hardware_interfaces for
>>> the UR5 motor drivers are setup. My best guess is in file
>>> *ur5.transmission.xacro*, can anyone confirm? If this is the right
>>> location, then I have 2 questions:
>>>
>>>
>>> - Where are the input and output of these hardware_interfaces
>>> specified, I could not find any code for this...
>>> - Knowing that the UR5 is proprietary and we do not have access to
>>> the internals of the motor drivers, how could it be determines that the
>>> hardware_interface to use is EffortJointInterface, as stated in file
>>> *ur5.transmission.xacro*?
>>>
>>> Thanks,
>>>
>>> Antoine.

Antoine Rennuit

unread,
Aug 28, 2014, 11:11:05 AM8/28/14
to swri-ros...@googlegroups.com
Ha this makes sense now! Thanks.

Hence, last related question: there must be some code configuring and updating the hardware interface (this is only for simulation then), but neither grep nor me doing some hand search could find it... Is there some other trick for simulation?

Cheers ;)

G.A. vd. Hoorn - 3ME

unread,
Aug 28, 2014, 11:15:55 AM8/28/14
to swri-ros...@googlegroups.com
On 28-8-2014 17:11, Antoine Rennuit wrote:
> Ha this makes sense now! Thanks.
>
> Hence, last related question: there must be some code configuring and
> updating the hardware interface (this is only for simulation then), but
> neither grep nor me doing some hand search could find it... Is there some
> other trick for simulation?

I'm not sure I follow you: what do you mean exactly by "updating the
hardware interface"?

If you are asking how the hardware interface gets its data, that is
coming from Gazebo, through the gazebo_ros_control plugins afaik.
Reply all
Reply to author
Forward
0 new messages