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

nckswt's profile - activity

2022-07-24 16:05:40 -0500 received badge  Good Question (source)
2022-07-24 14:11:10 -0500 received badge  Nice Question (source)
2021-05-19 04:47:10 -0500 received badge  Nice Question (source)
2020-10-25 14:12:26 -0500 marked best answer Unknown CMake command "add_action_files" during ROS install

I'm installing ROS on Mountain Lion (see possible related problems here), and I've hit a wall with the following error while using cmake:

CMake Error at actionlib/CMakeLists.txt:22 (add_action_files):
Unknown CMake command "add_action_files".

In actionlib/CMakeLists.txt, the offending line is:

add_action_files(DIRECTORY action FILES Test.action TestRequest.action TwoInts.action)

This exists both in the release version of the code both on github and on mercurial.

I haven't been able to find the add_action_files command in any of the cmake documentation – I assume it's valid, but I don't know why it's not working! Any ideas?

2020-07-09 16:49:58 -0500 received badge  Great Question (source)
2020-04-28 07:50:02 -0500 received badge  Famous Question (source)
2020-04-28 07:50:02 -0500 received badge  Notable Question (source)
2020-04-20 22:22:51 -0500 received badge  Taxonomist
2019-12-30 09:53:52 -0500 received badge  Famous Question (source)
2019-12-30 02:55:13 -0500 received badge  Nice Question (source)
2019-05-20 02:29:52 -0500 marked best answer Ros and Anaconda on an OS X homebrew installI

I'm trying to get ROS to play nicely with my Anaconda python. I know the prevailing answer to this problem is. "Don't." but I need Anaconda for other elements of my workflow.

My main issue is this:

$ roswtf
Fatal Python error: PyThreadState_Get: no current thread
Abort trap: 6

which seems to be the result of the wrong python being called. What I'm not sure about is how ROS binaries know which python version to use. Does anyone have experience with this?

2019-05-20 02:12:14 -0500 marked best answer How to best call catkin_add_gtest and add_rostest_gtest separately?

I'm trying to test ROS code at two different levels (calling catkin_add_gtest and add_rostest_gtest separately), and I haven't found documentation on exactly how to do what I'm hoping to do.

Essentially, I have src/library.cpp that I'd want to run gtest tests on through test/test_library.cpp. This should test low-level functionality - just the methods and functions defined in library.cpp, without any need of having a node running or publishing/subscribing.

I'd also like to run a full-fledged node-level test, running multiple nodes through rostest (defined in a test/test_node.test file), spun up through a gtest node defined in test/test_node.cpp.

The problem I'm facing is that if I run catkin run_tests package_name, this runs both the catkin_add_gtest and add_rostest_gtest targets. I'd like to use some command to run only one or the other, not both. How might I do that?

See example CMakeLists.txt below.

# CMakeLists.txt
...
add_library(library src/library.cpp )
target_link_libraries(library ${catkin_LIBRARIES})

if(CATKIN_ENABLE_TESTING)

  if(TARGET run_library_test) # can I do this?
    find_package(catkin REQUIRED rostest)
    catkin_add_gtest(test_library test/test_library.cpp)
    target_link_libraries(test_library library ${catkin_LIBRARIES})
  endif() # run_library_test

  if(TARGET run_node_test) # can I do this?
    find_package(catkin REQUIRED rostest)
    add_rostest_gtest(test_node test/test_node.test test/test_node.cpp)
    target_link_libraries(test_node library ${catkin_LIBRARIES})
  endif() # run_node_test

endif() # CATKIN_ENABLE_TESTING
2019-02-22 11:23:42 -0500 marked best answer Roslaunch and Metapackages

I know that metapackages should not contain any files except for the package.xml and CMakeLists.txt meant to specify the metapackage, but I'm wondering how I might call a launch file tied to a collection of packages cleanly.

For example, with this package structure:

├── catkin_ws
│   └── src
│       └── robot_motion_control
│           ├── robot_motion_control  # Metapackage
│           ├── pilot
│           ├── navigator
│           └── controller

If I wanted to run a launch file that groups together the conceptually-related pilot, navigator and controller, I'd want to call something like roslaunch robot_motion_control do_a_little_dance.launch, which exists at a higher level of abstraction than any of the three packages.

The problem is that I can't put .launch files in a metapackage, and calling something like roslaunch robot_motion_control_launch do_a_little_dance.launch feels fairly hacky.

I'd love to run roslaunch robot_motion_control do_a_little_dance.launch, but is there a way to architect my metapackage and packages such that I can actually do that?

2019-01-28 06:51:01 -0500 received badge  Famous Question (source)
2018-12-19 02:07:44 -0500 received badge  Self-Learner (source)
2018-12-01 22:27:52 -0500 received badge  Popular Question (source)
2018-12-01 22:27:52 -0500 received badge  Notable Question (source)
2018-11-03 15:48:01 -0500 received badge  Nice Question (source)
2018-09-24 08:01:42 -0500 received badge  Famous Question (source)
2018-07-09 13:53:28 -0500 marked best answer Controlling system resources with nice and ionice

I'd like to run nodes with high priority for both cpu time and file i/o time. As found in roslaunch documentation, we can use a launch-prefix to run nice, like this example for rosserial:

<node name="rosserial" pkg="rosserial_python" type="serial_node.py"
    launch-prefix="nice -n -5 ionice -c2 -n0"
    respawn="true" >
    <param name="port" value="/dev/ttyS0" />
    <param name="baud" value="115200" />
</node>

This works if I run nice -n 10 (or any nice value above 0), but requires superuser privileges if I want to increase the priority of the process using a negative nice value. However, this leads into a slew of nastiness with the superuser (e.g. rospy not existing on the PYTHONPATH), even if I use passwordless sudo.

Am I missing some typical way nice is used to elevate process priorities in ROS?

2018-07-08 23:22:39 -0500 received badge  Famous Question (source)
2018-04-27 02:21:50 -0500 received badge  Good Question (source)
2018-04-20 17:33:16 -0500 answered a question How to ROS_*_THROTTLE inside objects?

For anyone else trying to find the answer to this in the future: it doesn't appear to be possible, but there's a workaro

2018-04-18 20:58:01 -0500 received badge  Famous Question (source)
2018-03-30 14:17:10 -0500 commented question rosbag reindex / fix result in empty bag file.

Seeing the same issue myself.

2018-03-06 19:08:45 -0500 commented question Bug in ros::NodeHandle::searchParam()?

From what I can tell, this isn't an issue with either RosCpp or RosPy client library, but a problem with the payload ret

2018-03-06 19:08:28 -0500 commented question Bug in ros::NodeHandle::searchParam()?

From what I can tell, this isn't an issue with either RosCpp or RosPy client library, but a problem with the payload ret

2018-03-06 19:08:12 -0500 commented question Bug in ros::NodeHandle::searchParam()?

From what I can tell, this isn't an issue with either RosCpp or RosPy client library, but a problem with the payload ret

2018-03-06 19:04:53 -0500 commented question Bug in ros::NodeHandle::searchParam()?

Just noting that I've recently come across the same problem: ros::param::search returns true and gives a result path to

2018-02-16 12:16:07 -0500 received badge  Popular Question (source)
2018-02-16 12:16:07 -0500 received badge  Notable Question (source)
2018-02-06 14:13:45 -0500 received badge  Famous Question (source)
2017-10-25 06:45:21 -0500 received badge  Nice Question (source)
2017-10-23 17:01:11 -0500 received badge  Notable Question (source)
2017-10-23 17:01:11 -0500 received badge  Famous Question (source)
2017-10-06 01:35:37 -0500 received badge  Favorite Question (source)
2017-10-04 19:58:35 -0500 marked best answer Is it possible to launch multiple nodes from one python script?

I see that rospy.init_node() can only be called once per process in the official documentation on nodes.

I'm trying to write a script that allows for two-way communication (one message publisher and one message subscriber) to interact with a single object. If I have to keep the publisher in one script and the subscriber in another, I'll have a bit of a mess on my hands if I want to interact with the single object.

Is there a simple way of spawning multiple nodes (one talker, one listener, in this case) from one single process?

2017-09-19 10:37:35 -0500 asked a question How to best call catkin_add_gtest and add_rostest_gtest separately?

How to best call catkin_add_gtest and add_rostest_gtest separately? I'm trying to test ROS code at two different levels

2017-09-08 15:56:48 -0500 received badge  Notable Question (source)
2017-09-08 11:33:04 -0500 commented answer Roslaunch and Metapackages

True. I wonder whether robot_motion_control_meta would be an appropriate name for the metapackage, then I could house th

2017-09-08 10:59:00 -0500 received badge  Popular Question (source)
2017-09-08 10:55:22 -0500 commented answer Roslaunch and Metapackages

The capabilities project is really interesting - it'd be nice to see if that gets greater use in ros 2.0

2017-09-08 10:53:05 -0500 commented answer Roslaunch and Metapackages

So the roslaunch call would end up being roslaunch robot_motion_control_bringup do_a_little_dance.launch? I'm wondering

2017-09-08 10:49:46 -0500 edited question Roslaunch and Metapackages

Roslaunch and Metapackages I know that metapackages should not contain any files except for the package.xml and CMakeLis