Category : catkin

I’m trying to use some dlib optimization functions but I’m having problems with compiling. Unfortunately, there aren’t any step-by-step tutorials on how to install and use dlib in catkin workspace. This is my workspace file structure: I installed dlib like this: cd catkin_ws/devel/lib/beginner_tutorials/dlib-19.22/dlib mkdir build cd build cmake .. make -j4 sudo make install My ..

Read more

I am trying to get GPS data from "/mavros/global_position/global" using the following codes below: This is a header file: #pragma once #include <sensor_msgs/NavSatFix.h> #include <ros/ros.h> class Localization{ public: // Functions void receiver(const sensor_msgs::NavSatFixConstPtr& data); // Constructors Localization(ros::NodeHandle); private: // Data types double latitiude; double longitude; double altitude; const std::string topic {"/mavros/global_position/global"}; }; void Localization::receiver(const sensor_msgs::NavSatFixConstPtr& ..

Read more

When i catkin_make when module_one find package module_two and module_two find package module_one, there is error like below — +++ processing catkin package: ‘module_one’ — ==> add_subdirectory(module_one) — Could NOT find module_two (missing: module_two_DIR) — Could not find the required component ‘module_two’. The following CMake error indicates that you either need to install the package ..

Read more

I created a C++ game that uses images from a folder in the same parent directory. /game_folder —-/Images ——–icon1.png ——–icon2.png —-game.cpp Program uses Allegro 5 library to include images: ALLEGRO_BITMAP* icon1 = al_load_bitmap("Images/icon1.png"); ALLEGRO_BITMAP* icon2 = al_load_bitmap("Images/icon2.png"); And this works great. However now I need to place this program into ROS/catkin package ‘beginner_tutorials’. If I ..

Read more

I’m trying to compile a code with cmake and get this error (I’m pretty new with cmake): /usr/bin/ld: cannot find -lMPC Here is my CMakeLists.txt file: cmake_minimum_required(VERSION 3.0.2) project(PX4Vision_AutonomousLanding) find_package(catkin REQUIRED COMPONENTS roscpp nav_msgs geometry_msgs mavros_msgs ) include_directories( ${catkin_INCLUDE_DIRS} ) catkin_package( CATKIN_DEPENDS roscpp nav_msgs geometry_msgs mavros_msgs ) add_executable(offboard_node src/offboard_node.cpp ) target_link_libraries(offboard_node MPC ${CMAKE_DL_LIBS} ${catkin_LIBRARIES} ) ..

Read more