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

"katana_driver" connectivity with Katana Arm 6M180

asked 2014-10-22 18:06:01 -0500

tufail gravatar image

updated 2014-10-22 18:07:49 -0500

Hi all,

I am struggling with the katana_driver in ROS (hydro) for the 6M180 arm. When I try to launch the Katana node, I get the following error:

process[katana-3]: started with pid [24264] [ INFO] [1414017395.500394067]: trying to connect to katana (serial port: /dev/ttyS0) ... [ERROR] [1414017395.500853297]: Exception during initialization: 'Cannot get/set attributes on '/dev/ttyS0''

.

.

Does it mean the arm has to be connected serially? Or I will have to use a USB to serial converter because I have connected it via USB. But here is another question, isn't that USB treated as a network device?

Could anyone please help how to connect the arm to the laptop in order for katana_driver to work properly?

Any comments/suggestions are most welcome.

Thank you,

Muhammad Tufail

edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
0

answered 2014-10-24 04:27:53 -0500

updated 2014-10-25 05:53:16 -0500

Here is how to connect to the Katana via USB. These instructions are tested on our Katana 450 6M90a with an internal control board (i.e., a "base" to mount the arm). You are indeed correct that when you connect the Katana via USB, it acts as a USB network device.

  • Connect the arm via USB and switch it on.
  • Since the arm doesn't have a DHCP server, you need to configure the network manually. Open up NetworkManager and create a new connection for the USB network adapter interface:

    • IP address: 192.168.1.* , where * is anything in the range [2-255], e.g. 192.168.1.77
    • network mask: 255.255.255.0
    • no gateway (0.0.0.0)
  • The arm should now respond to ping 192.168.1.1. If it doesn't, don't continue and fix this problem first.

  • Make sure that the katana parameters are properly set: use_serial = false and ip = "192.168.1.1" (see the katana wiki page ). These are the defaults, but e.g. katana_300_6m180.launch changes these defaults.

If you still have problems, please edit your question and include the following information:

  • What Katana arm do you have, exactly? Is it e.g. a Katana 300 6M180? Does it have an internal/external control board or none?
  • What ROS version are you using?
  • What's your katana_driver branch? Did you make any local changes?
  • What launch files are you starting?

Answers to your reply:

Error when launching katana.launch: which first says "trying to connect to katana (serial port:/dev/ttyS0) and then says cannot get/set attributes on '/dev/ttyS0'.

Edit the katana_300_6m180.launch file and remove the line where it says use_serial (or set the param to false).

Error when launching katana_300_6m180.launch: says the parameter katana_type was not set!

You shouldn't launch that file directly; instead, use katana.launch, then this error doesn't occur. That file includes katana_300_6m180.launch.

fatal error: armadillo: No such file or directory

Just do the following:

sudo rosdep init
rosdep update
rosdep install katana_driver

If that doesn't work, just do the following directly:

sudo apt-get install libarmadillo-dev
edit flag offensive delete link more

Comments

Everything worked fine. Thanks.

I didn't have to set the use_serial param to false as the katana I have is 400 6M180 (not 300). So for I have been setting the KATANA_TYPE environment variable to katana_300_6m180 which was wrong.

I installed the `libarmadillo-dev' and rosmake worked too.

tufail gravatar image tufail  ( 2014-11-04 13:34:30 -0500 )edit

Hi Martin, I have exactly this problem. My computer doesn't have a serial port so I'm using a Prolific Serial to USB converter to connect to the Katana. However I didn't understand exactly how to set up the network interface for the USB port. Could you please try to explain me exactly how to do it?

João Almeida gravatar image João Almeida  ( 2015-10-08 05:39:54 -0500 )edit

I guess if you're using a serial to USB converter, it should show up as a serial port, right? So you shouldn't set up any network interface, but set use_serial = true.

Martin Günther gravatar image Martin Günther  ( 2015-10-09 03:31:16 -0500 )edit

Thank you Martin! We fixed the problem by creating a symbolic link between the '/dev/ttys0/ and the '/dev/ttyUSB0'.

João Almeida gravatar image João Almeida  ( 2015-10-13 10:17:12 -0500 )edit
0

answered 2014-10-24 16:55:25 -0500

tufail gravatar image

updated 2014-10-25 05:24:51 -0500

Hi Martin,

Thanks for the reply.

I have connected the arm via USB. The IP is configured exactly as you said and the ping command (ping 192.168.1.1) works fine.

Where to set those two parameters i.e. use_serial=false and ip="192.168.1.1"? I already see them set in katana.cpp source file.

Following here are more details that you have asked for.

"What Katana arm do you have, exactly? Is it e.g. a Katana 300 6M180?" Yes, it is Katana 300 6m180.

"Does it have an internal/external control board or none?" Internal.

"What ROS version are you using?" ROS Hydro on Linux 13.04

"What's your katana_driver branch? Did you make any local changes?" I have actually installed the uos-ros-pkg using the link given below. No local changes were made. http://wiki.ros.org/uos-ros-pkg I have set the KATANA_TYPE as given in here: http://wiki.ros.org/katana_driver

"What launch files are you starting?"

I tried two but am getting error with both of them.

Error when launching katana.launch: which first says "trying to connect to katana (serial port:/dev/ttyS0) and then says cannot get/set attributes on '/dev/ttyS0'.

[ INFO] [1414186519.459809847]: trying to connect to katana (serial port: /dev/ttyS0) ...
[ERROR] [1414186519.460287872]: Exception during initialization: 'Cannot get/set attributes on '/dev/ttyS0''
katana: /usr/include/boost/smart_ptr/shared_ptr.hpp:424: T* boost::shared_ptr<T>::operator->() const [with T = CLMBase]: Assertion `px != 0' failed.
[katana-3] process has died [pid 6947, exit code -6, cmd /home/ial/ros-hydro/dry/katana_driver/katana/bin/katana __name:=katana __log:=/home/ial/.ros/log/a63e0d8e-5bc5-11e4-aedf-8ca98271a938/katana-3.log].
log file: /home/ial/.ros/log/a63e0d8e-5bc5-11e4-aedf-8ca98271a938/katana-3*.log

Error when launching katana_300_6m180.launch: says the parameter katana_type was not set!, while I set it as: $ export KATANA_TYPE="katana_300_6m180".

[ERROR] [1414186440.273708266]: Parameter katana_type was not set!
[katana-3] process has died [pid 6840, exit code 255, cmd /home/ial/ros-hydro/dry/katana_driver/katana/bin/katana __name:=katana __log:=/home/ial/.ros/log/7709afdc-5bc5-11e4-9157-8ca98271a938/katana-3.log].
log file: /home/ial/.ros/log/7709afdc-5bc5-11e4-9157-8ca98271a938/katana-3*.log

Lastly, when I rosmake katana_driver, I get the following errors:

[ 92%] Built target katana
  In file included from /home/ial/ros-hydro/dry/katana_driver/katana/include/katana/KNIKinematics.h:42:0,
                   from /home/ial/ros-hydro/dry/katana_driver/katana/src/KNIKinematics.cpp:25:
  /home/ial/ros-hydro/dry/katana_driver/katana/include/katana/EulerTransformationMatrices.hh:34:21: fatal error: armadillo: No such file or directory
  compilation terminated.
  make[3]: *** [CMakeFiles/katana_arm_kinematics.dir/src/KNIKinematics.cpp.o] Error 1
  make[3]: Leaving directory `/home/ial/ros-hydro/dry/katana_driver/katana/build'
  make[2]: *** [CMakeFiles/katana_arm_kinematics.dir/all] Error 2
  make[2]: Leaving directory `/home/ial/ros-hydro/dry/katana_driver/katana/build'
  make[1]: *** [all] Error 2
  make[1]: Leaving directory `/home/ial/ros-hydro/dry/katana_driver/katana/build'
-------------------------------------------------------------------------------}
[ rosmake ] Output from build of package katana written to:
[ rosmake ]    /home/ial/.ros/rosmake/rosmake_output-20141024-145203/katana/build_output.log
[rosmake-2] Finished <<< katana [FAIL] [ 8.39 seconds ]                                                              
[ rosmake ] Halting due to failure ...
(more)
edit flag offensive delete link more

Comments

Hi tufail! Next time, you shouldn't post your reply as an answer (because it isn't an answer to your question). Instead, edit your original question. But for now, just leave it. I've edited my answer to reply.

Martin Günther gravatar image Martin Günther  ( 2014-10-25 05:54:32 -0500 )edit

Thank you Martin, I am sorry I am still new here.

tufail gravatar image tufail  ( 2014-10-25 09:31:20 -0500 )edit

Question Tools

4 followers

Stats

Asked: 2014-10-22 18:06:01 -0500

Seen: 461 times

Last updated: Oct 25 '14