Open6

ROS1 NoeticでBehaviorTree.CPPを使う

K. TakahashiK. Takahashi

現在aptでインストールできるros-noetic-behaviortree-cpp-v3(3.5.6)では、CoroAction nodeが利用できない。元リポジトリにissueが立っているが、まだ解決されていない

K. TakahashiK. Takahashi

BehaviorTree.CPPを全部書くと長いので、以下BT.CPPと表記する

K. TakahashiK. Takahashi

boostがインストールされたローカル環境README.mdでBT.CPPをビルドすると、coroutineを有効化してビルド/インストールすることはできる

 mkdir build; cd build
 cmake ..
 make
 sudo make install

が、ROS packageのCMakeLists.txtfind_package()behaviortree_cpp_v3を追加してcatkin build
するとエラーになる

CMake Error at /opt/ros/noetic/share/catkin/cmake/catkinConfig.cmake:83 (find_package):
  Could not find a package configuration file provided by
  "behaviortree_cpp_v3" with any of the following names:

    behaviortree_cpp_v3Config.cmake
    behaviortree_cpp_v3-config.cmake

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


make: *** [Makefile:854: cmake_check_build_system] Error 1
K. TakahashiK. Takahashi

結局、BT.CPPを$ROS_PACKAGE_PATH(~/catkin_ws/src等)に移動してcatkin buildすると、問題なくビルドできた