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

mathiasi's profile - activity

2017-08-04 20:07:24 -0500 received badge  Famous Question (source)
2017-05-03 08:08:51 -0500 received badge  Notable Question (source)
2017-05-03 08:08:51 -0500 received badge  Popular Question (source)
2017-03-13 09:00:21 -0500 received badge  Enthusiast
2017-03-10 07:02:11 -0500 received badge  Scholar (source)
2017-03-10 07:02:04 -0500 answered a question Hector quadcopter not responding to cmd_vel messages

I stumbled upon this issue: https://github.com/tu-darmstadt-ros-p... Turns out that you have to an enable_motors action to "turn on" the quadcopter. Calling

rosservice call /enable_motors true

worked for me.

2017-03-09 07:20:08 -0500 asked a question Hector quadcopter not responding to cmd_vel messages

I've been following this tutorial to get the hector quadcopter to work: http://wiki.ros.org/hector_quadrotor/...

I'm using Kinetic and I can see that the tutorial is a bit outdated so I have used

wstool init src https://raw.github.com/tu-darmstadt-ros-pkg/hector_quadrotor/kinetic-devel/tutorials.rosinstall

instead of the URL specified in the tutorial. catkin_make completes with no errors.

I do not have access to a controller at hand so I intend to use my keyboard for the time being. I could not find the pr2_teleop package mentioned for Kinetic but I found somewhere that teleop_twist_keyboard ( http://wiki.ros.org/teleop_twist_keyb... ) should work just fine. I start the controller using

rosrun teleop_twist_keyboard teleop_twist_keyboard.py

I have monitored the cmd_vel topic that, according to the tutorial, is being used and the telop_twist_keyboard node does publish messages just fine.

Here is a graph of my nodes that verifies the connection between the gazebo node and teleop_twist_keyboard using the cmd_vel:

image description

However the drone does not move whatsoever and I can't find any error messages (besides one that says no joystick was found at /dev/input/js0) but I would not expect that to be the problem.

2016-11-19 08:16:26 -0500 commented answer Introduce intermediate node programmatically?

That is not a problem for my use-case. I'm sorry if it was not clear in my original post and has caused confusion.

2016-11-19 08:10:43 -0500 received badge  Famous Question (source)
2016-11-19 08:03:24 -0500 commented answer Introduce intermediate node programmatically?

You are totally right about that but my plan was to use remapping to get them to listen to the new topics.

2016-11-19 07:05:35 -0500 answered a question Introduce intermediate node programmatically?

It seems that I have managed to find a solution myself. I stumbled upon the get_message_class method in roslib.message that seems to do the job. Here is a code snippet if anyone is interested:

import rospy
from roslib.message import get_message_class

rospy.init_node('test_node_intermediate')

topics = rospy.get_master().getPublishedTopics("/")[2]
for topic in topics:
    msg_class = get_message_class(topic[1])
    pub = rospy.Publisher("/inter"+topic[0],msg_class,queue_size=1)
2016-11-09 17:12:20 -0500 received badge  Good Question (source)
2016-11-09 04:10:55 -0500 commented answer Introduce intermediate node programmatically?

@lucasw - Do you happen to know if there is a similar tool available for services and actions?

2016-11-08 12:15:41 -0500 commented answer Introduce intermediate node programmatically?

Thank you for your input - very much appreciated. I'll have a closer look at it.

2016-11-07 11:05:45 -0500 received badge  Notable Question (source)
2016-11-07 09:45:57 -0500 received badge  Nice Question (source)
2016-11-07 09:08:31 -0500 received badge  Popular Question (source)
2016-11-06 06:15:22 -0500 received badge  Student (source)
2016-11-05 10:29:27 -0500 commented question Introduce intermediate node programmatically?

@gvdhoorn - That's right, logging might not be the best example as a use-case. I'm more generally interested in controlling the communication between the two nodes. Lets say I want to filter out some messages based on the values in them ; the ability to entire block communication is what going for.

2016-11-05 09:59:57 -0500 asked a question Introduce intermediate node programmatically?

Hi there,

I'm fairly new to ROS and I'm exploring the possibilities and I have come up with a scenario that I have not quite figured out if it is possible.

Consider a situation where you have two nodes: a publisher (my_publisher) and a subscriber (my_subscriber). I want to be able to control the communication between those two nodes (use-cases could be for logging but also for cutting the communication all together). My solution proposal is to introduce an "intermediate" node that could relay the communication and using the remapping functionality in launch files to redirect the subscriber to the new topic.

The transformation is displayed as followed:

Example

This is not a problem if you manually create a node but lets say you have many nodes and don't want to manually add the topic to the intermediate node, then you would do this programmatically. I have looked at the getPublishedTopics method from the Master API ( http://wiki.ros.org/ROS/Master_API ) - it does return the name of the topic but the topic message type is also returned as a string however I need a reference to the class in order to publish a new topic. Is there a way to get that or can the goal be achieved in an entirely other way?

Thanks,