Using sick_scan and rviz
Hello,
I am trying to use rviz to visualize the data I am receiving from my Sick tim561 which is running from my Raspberry Pi. For this, I am using ros kinetic, sick_scan and attempting to follow the instructions on the wiki. I am however having some trouble. I am able to run the roslaunch command with my launch file (sick_scan sick_tim_5xx.launch), and it seems to be working well. From what I can tell it is publishing pointcloud2 to cloud, but I am not quite sure what that means. However I am unsure as to how to get rviz to read that data.
I would also like to add that I am quite new to ROS and this sort of project in general so feel free to add any clarifying points or let me know if you need more information and I will get that to you as soon as I can.
Thanks.
Edit: Launch file -> sick_tim_5xx.launch
<?xml version="1.0"?>
<launch>
<arg name="hostname" default="192.168.0.1" />
<arg name="cloud_topic" default="cloud" />
<arg name="frame_id" default="cloud" />
<node name="sick_tim_5xx" pkg="sick_scan" type="sick_generic_caller" respawn="false" output="screen">
<param name="scanner_type" type="string" value="sick_tim_5xx" />
<!-- -135° -->
<param name="min_ang" type="double" value="-2.35619449" />
<!-- 135° -->
<param name="max_ang" type="double" value="2.35619449" />
<param name="use_binary_protocol" type="bool" value="true" />
<param name="range_max" type="double" value="100.0" />
<param name="intensity" type="bool" value="True" />
<param name="hostname" type="string" value="$(arg hostname)" />
<param name="cloud_topic" type="string" value="$(arg cloud_topic)"/>
<param name="frame_id" type="str" value="$(arg frame_id)" />
<param name="port" type="string" value="2112" />
<param name="timelimit" type="int" value="5" />
</node>
</launch>
Here is what happens when I run this launch file:
ubuntu@ubiquityrobot:~/catkin_ws$ roslaunch sick_scan sick_tim_5xx.launch
... logging to /home/ubuntu/.ros/log/702e9050-d0dc-11e5-9013-b827eb3e657d/roslaunch-ubiquityrobot-2063.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://ubiquityrobot.local:41867/
SUMMARY
========
PARAMETERS
* /rosdistro: kinetic
* /rosversion: 1.12.14
* /sick_tim_5xx/cloud_topic: cloud
* /sick_tim_5xx/frame_id: cloud
* /sick_tim_5xx/hostname: 192.168.0.1
* /sick_tim_5xx/intensity: True
* /sick_tim_5xx/max_ang: 2.35619449
* /sick_tim_5xx/min_ang: -2.35619449
* /sick_tim_5xx/port: 2112
* /sick_tim_5xx/range_max: 100.0
* /sick_tim_5xx/scanner_type: sick_tim_5xx
* /sick_tim_5xx/timelimit: 5
* /sick_tim_5xx/use_binary_protocol: True
NODES
/
sick_tim_5xx (sick_scan/sick_generic_caller)
ROS_MASTER_URI=http://ubiquityrobot.local:11311
process[sick_tim_5xx-1]: started with pid [2081]
[ INFO] [1551880175.138692169]: sick_generic_caller V. 001.003.016
[ INFO] [1551880175.138954563]: Program arguments: /home/ubuntu/catkin_ws/install/lib/sick_scan/sick_generic_caller
[ INFO] [1551880175.139037895]: Program arguments: __name:=sick_tim_5xx
[ INFO] [1551880175.139090395]: Program arguments: __log:=/home/ubuntu/.ros/log/702e9050-d0dc-11e5-9013-b827eb3e657d/sick_tim_5xx-1.log
[ INFO] [1551880175.212545742]: Found sopas_protocol_type param overwriting default protocol:
[ INFO] [1551880175.212803813]: Binary protocol activated
[ INFO] [1551880175.212909385]: Start initialising scanner [Ip: 192.168.0.1] [Port: 2112]
[ INFO] [1551880175.409250725]: Publishing laserscan-pointcloud2 to cloud
1551880308.5115 ERROR: Tcp::open: Failed to open TCP connection to 192.168.0.1, aborting.
[ INFO] [1551880308.531176850]: Parameter setting for <active_echo: 0>
[ INFO] [1551880308.733535743 ...