run a ros node problem

asked 2012-07-10 05:12:08 -0600

Astronaut gravatar image

updated 2012-07-11 03:12:46 -0600

Lorenz gravatar image

Hello

I have installed and compiled correctly the ros package amcl_listener. When I tried to run the node amcl_pose_listener it happened nothing. But if I type the command rosnode list I can see the amcl_pose_listener and rosout. Please can you explain me whats going on? My opinion it should do something like simple receipt of messages over the ROS system. But how to prove that?

for the command rostopic list -v

I got this :

Published topics:
 * /robot_fixed_pose_trajectory [visualization_msgs/Marker] 1 publisher
 * /rosout [rosgraph_msgs/Log] 1 publisher
 * /rosout_agg [rosgraph_msgs/Log] 1 publisher

Subscribed topics:
 * /amcl_pose [geometry_msgs/PoseWithCovarianceStamped] 1 subscriber
 * /rosout [rosgraph_msgs/Log] 1 subscriber

Now is ok. Just the rosrun was killed. So omn the command rosnode info amcl_pose_listener got this

Publications: 
 * /robot_fixed_pose_trajectory [visualization_msgs/Marker]
 * /rosout [rosgraph_msgs/Log]

Subscriptions: 
 * /amcl_pose [unknown type]

Services: 
 * /amcl_pose_listener/set_logger_level
 * /amcl_pose_listener/get_loggers


contacting node http://bojan-laptop:60358/ ...
Pid: 9274
Connections:
 * topic: /rosout
    * to: /rosout
    * direction: outbound
    * transport: TCPROS
edit retag flag offensive close merge delete

Comments

1

Not sure what you mean with 'it happened nothing' but I guess the node is running. If you run the node and don't get a shell prompt, the node is running. What output would you expect? **Edit**: Nobody is publishing amcl_pose. Did you start amcl?

Lorenz gravatar image Lorenz  ( 2012-07-10 05:27:04 -0600 )edit

If you don't get an error message when you execute rosnode info <node name> then the node is running. If you don't get any data, something is probably mis-configured. Unfortunately you are not providing enough information to help in that case.

Lorenz gravatar image Lorenz  ( 2012-07-10 05:45:32 -0600 )edit

what more information is needed?

Astronaut gravatar image Astronaut  ( 2012-07-10 06:45:30 -0600 )edit

rostopic list -v would be a good start.

joq gravatar image joq  ( 2012-07-10 07:23:51 -0600 )edit

But I can not see any output. Should give the robot fixed position but no outcome. So how to see this?Because there are two publications: Publications: * /robot_fixed_pose_trajectory [visualization_msgs/Marker] * /rosout [rosgraph_msgs/Log]

Astronaut gravatar image Astronaut  ( 2012-07-11 03:16:09 -0600 )edit

amcl is a node that localizes your robot based on a laser scan and odometry using a particle filter. See http://ros.org/wiki/amcl It publishes amcl_pose which your node apparently needs. That means that you probably need to run it.

Lorenz gravatar image Lorenz  ( 2012-07-11 08:50:23 -0600 )edit