0
$\begingroup$

Rosanswers logo

Hopefully someone can help, I've been trying to get this to work for quite a while now.

I have a custom node which provides services and messages called dp_ptu47 (it's a pan tilt unit). I'm trying to get access to the services of the dp_ptu47 node from another client node, which will be running on a different machine.

I get the following error when I catkin_make my client node:

-- +++ processing catkin package: 'sme_awareness'
-- ==> add_subdirectory(sme_awareness)
-- Using these message generators: gencpp;genlisp;genpy
CMake Error at /opt/ros/indigo/share/catkin/cmake/catkinConfig.cmake:75 (find_package):
  Could not find a package configuration file provided by "dp_ptu47_msgs"
  with any of the following names:

    dp_ptu47_msgsConfig.cmake
    dp_ptu47_msgs-config.cmake

  Add the installation prefix of "dp_ptu47_msgs" to CMAKE_PREFIX_PATH or set
  "dp_ptu47_msgs_DIR" to a directory containing one of the above files.  If
  "dp_ptu47_msgs" provides a separate development package or SDK, be sure it
  has been installed.
Call Stack (most recent call first):
  sme_awareness/CMakeLists.txt:7 (find_package)

I've checked that the 'dp_ptu47_msgs' package exists and it's there and ros seems happy, I've also looked for the file that the error message says it can't find 'dp_ptu47_msgsConfig.cmake' and this exists in the 'install/share/dp_ptu47_msgs/cmake' path of the node. The error message doesn't say where it it's looking for the file so I'm not sure if this is in the right place or not.

I've tried all sorts of things to find out what's going on, and I'm out of ideas. Does anyone have any ideas what could be causing this.

Thanks


Originally posted by PeteBlackerThe3rd on ROS Answers with karma: 9529 on 2016-02-17

Post score: 0


Original comments

Comment by Thomas D on 2016-02-17:
Can you put up your package.xml and CMakeLists.txt for the package that depends on dp_ptu47?

Comment by gvdhoorn on 2016-02-18:
And seeing your other question: please add some info on the order in which you build & source your workspaces, their (relative) locations, etc.

Comment by PeteBlackerThe3rd on 2016-02-18:
Thanks, guys. I've managed to get to the bottom of this now. I needed to run the devel/setup.bash script for the dp_ptu47_msgs package. Now it builds fine.

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

I've found a solution to this. Not sure if I was missing something really obvious, but this is what I did.

Executing the devel/setup.bash script for the 'depended on' package before running catkin_make on the package I'm trying to make has fixed the problem.


Originally posted by PeteBlackerThe3rd with karma: 9529 on 2016-02-18

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by gvdhoorn on 2016-02-18:\

Not sure if I was missing something really obvious [..]

Well if you are overlaying (or chaining) workspaces, then yes, you always need to source your workspaces in the correct order before trying to do anything with the next one up the stack. Isn't that described in the overlaying docs?

Comment by gvdhoorn on 2016-02-18:
And just making sure: only workspaces have setup.bash scripts, packages do not. Are you using a single-package-per-workspace layout?

Comment by PeteBlackerThe3rd on 2016-02-18:
I hadn't realised that I needed to overlay workspaces, if messages or services were being passed between nodes in different workspaces. I had been used to using the built in message types up till now.

Comment by PeteBlackerThe3rd on 2016-02-18:
To answer your other question, no there are plenty of packages in the workspaces. We have one which contains a hardware interface and tools for a pan tilt unit. The other contains our navigation system. It's a shared system so we didn't want to mix up too much code!

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.