├── .github └── workflows │ └── conda-ci.yml ├── .gitignore ├── .travis.yml ├── CMakeLists.txt ├── LICENSE ├── README.md ├── app ├── CMakeLists.txt ├── baseControl │ ├── CMakeLists.txt │ ├── conf │ │ ├── baseCtrl_cer.ini │ │ ├── baseCtrl_cer_with_oculus.ini │ │ ├── baseCtrl_ikartV1.ini │ │ ├── baseCtrl_ikartV2.ini │ │ └── joystick_configs.ini │ └── scripts │ │ ├── baseControl.xml │ │ ├── mobileBase Launch.sh │ │ ├── navigation.launch │ │ ├── transformServer.xml │ │ ├── visual_odometry.launch │ │ └── wheel_odometry.launch ├── baseControl2 │ ├── CMakeLists.txt │ └── conf │ │ ├── baseCtrl_cer.ini │ │ └── baseCtrl_cer_ros2.ini ├── baseControl2_SIM │ ├── CMakeLists.txt │ └── conf │ │ ├── cer_baseControl2.ini │ │ ├── cer_baseControl2_ros2.ini │ │ ├── robot_2wheels_baseControl2.ini │ │ └── robot_2wheels_baseControl2_ros2.ini ├── baseControl_SIM │ ├── CMakeLists.txt │ └── conf │ │ ├── baseCtrl_cer_sim.ini │ │ ├── joystick_configs.ini │ │ ├── robot_2wheels.ini │ │ └── robot_3wheels.ini ├── deprecated │ └── CMakeLists.txt ├── follower │ ├── conf │ │ ├── follower.ini │ │ ├── follower_SIM.ini │ │ └── log.txt │ └── scripts │ │ ├── demoHumanModelFollower.xml │ │ ├── demoPersonFollower.xml │ │ ├── demoRedBallFollower.xml │ │ └── navigationSetup.xml ├── freeFloorViewer │ ├── CMakeLists.txt │ ├── conf │ │ ├── freeFloorViewer_R1SN003.ini │ │ ├── freeFloorViewer_R1SN003_ROS2.ini │ │ ├── freeFloorViewer_R1_SIM.ini │ │ ├── freeFloorViewer_R1_SIM_ROS2.ini │ │ ├── freeFloorViewer_complete_R1SN003.ini │ │ ├── freeFloorViewer_sim.ini │ │ ├── freeFloorViewer_sim_tour.ini │ │ ├── gazeboLocalizer.ini │ │ ├── odomLocalizer_cer02.ini │ │ ├── robotGoto_cer02.ini │ │ ├── robotGoto_sim_cer.ini │ │ ├── robotPathPlanner_cer02.ini │ │ └── robotPathPlanner_sim_cer.ini │ └── scripts │ │ ├── freeFloorViewer_R1SN003.xml │ │ ├── freeFloorViewer_R1SN003_ROS2.xml │ │ ├── freeFloorViewer_R1_SIM.xml │ │ ├── freeFloorViewer_R1_SIM_DISTRIBUTED.xml │ │ ├── freeFloorViewer_R1_SIM_ROS2.xml │ │ ├── freeFloorViewer_complete_R1SN003.xml │ │ ├── freeFloorViewer_complete_R1SN003_ROS2.xml │ │ ├── freeFloorViewer_complete_R1_SIM.xml │ │ ├── freeFloorViewer_complete_R1_SIM_DISTRIBUTED.xml │ │ ├── freeFloorViewer_complete_R1_SIM_ROS2.xml │ │ └── freeFloorViewer_noROS_sim.xml ├── gazeboExamples │ ├── CMakeLists.txt │ ├── conf │ │ ├── gazeboLocalizer.ini │ │ ├── navigationGUI_sim_cer.ini │ │ ├── robotGoto_sim_cer.ini │ │ └── robotPathPlanner_sim_cer.ini │ └── scripts │ │ └── gazeboExample.xml ├── iKartNav │ ├── conf │ │ └── iKartNav.ini │ └── scripts │ │ └── iKartNav.xml.template ├── localizationServer │ ├── CMakeLists.txt │ ├── conf │ │ └── odomLocalizer.ini │ └── scripts │ │ └── odomLocalizer_test.xml ├── mapper2D │ ├── CMakeLists.txt │ ├── conf │ │ └── mapper2D.ini │ └── scripts │ │ └── mapper2D.xml ├── mapsExample │ ├── CMakeLists.txt │ ├── locations.ini │ ├── map_empty.map │ ├── map_empty_grid.pgm │ ├── map_empty_grid.yaml │ ├── map_empty_yarpflags.ppm │ ├── map_isaac.map │ ├── map_isaac.png │ ├── map_isaac_small.png │ ├── map_isaac_yarpflags.png │ ├── map_test.map │ ├── map_test2.map │ ├── map_test2_grid.pgm │ ├── map_test2_grid.yaml │ ├── map_test2_yarpflags.ppm │ ├── map_test_grid.pgm │ ├── map_test_grid.yaml │ ├── map_test_yarpflags.ppm │ └── maps_collection.ini ├── mapsSquirico │ ├── CMakeLists.txt │ ├── locations.ini │ ├── map_isaac.map │ ├── map_isaac_yarpflags.png │ └── maps_collection.ini ├── multipleLaserTest │ ├── CMakeLists.txt │ └── scripts │ │ ├── test1.xml │ │ ├── test2.xml │ │ ├── test3.xml │ │ ├── test4.xml │ │ ├── test5.xml │ │ └── test6.xml ├── navigationGUI │ ├── CMakeLists.txt │ ├── conf │ │ ├── navigationGUI_base.ini │ │ ├── navigationGUI_base_nws-nwc.ini │ │ ├── navigationGUI_cer.ini │ │ ├── navigationGUI_ikart.ini │ │ ├── navigationGUI_robot_2wheels.ini │ │ ├── navigationGUI_robot_2wheels_nws-nwc.ini │ │ ├── navigationGUI_robot_2wheels_sim_cer_nws-nwc.ini │ │ ├── navigationGUI_sim_cer.ini │ │ └── navigationGUI_sim_cerR1.ini │ └── scripts │ │ └── navigationGUI.xml ├── robotGoto │ ├── CMakeLists.txt │ ├── conf │ │ ├── robotGoto_cer.ini │ │ ├── robotGoto_cerSim.ini │ │ └── robotGoto_ikart.ini │ └── scripts │ │ ├── robotGoto.xml │ │ └── robotGoto_no_laser.xml ├── robotGotoExamples │ ├── CMakeLists.txt │ ├── conf │ │ ├── odomLocalizer.ini │ │ ├── robotGoto_cer.ini │ │ ├── robotGoto_ikart.ini │ │ ├── robotGoto_robot_2wheels.ini │ │ └── robotGoto_robot_3wheels.ini │ └── scripts │ │ ├── robotGotoExample1.xml │ │ └── robotGotoExample2.xml ├── robotPathPlanner │ ├── CMakeLists.txt │ ├── conf │ │ ├── robotPathPlanner_cer.ini │ │ ├── robotPathPlanner_cerSim.ini │ │ └── robotPathPlanner_ikart.ini │ └── scripts │ │ └── robotPathPlanner.xml ├── robotPathPlannerExamples │ ├── CMakeLists.txt │ ├── conf │ │ ├── amclLocalizer.ini │ │ ├── gazeboLocalizer.ini │ │ ├── localization2Dros2.ini │ │ ├── map2D_ros2.ini │ │ ├── odomLocalizer.ini │ │ ├── pozyxLocalizer.ini │ │ ├── robotGoto_cer.ini │ │ ├── robotGoto_ikart.ini │ │ ├── robotGoto_robot_2wheels.ini │ │ ├── robotGoto_robot_2wheels_with_recovery.ini │ │ ├── robotGoto_robot_3wheels.ini │ │ ├── robotGoto_sim_cer.ini │ │ ├── robotInterface │ │ │ ├── localization2Dros2.xml │ │ │ └── map2d_ros2.xml │ │ ├── robotPathPlanner_cer.ini │ │ ├── robotPathPlanner_ikart.ini │ │ ├── robotPathPlanner_robot_2wheels.ini │ │ ├── robotPathPlanner_robot_2wheels_with_recovery.ini │ │ ├── robotPathPlanner_robot_3wheels.ini │ │ └── robotPathPlanner_sim_cer.ini │ └── scripts │ │ ├── robotPathPlannerExample1.xml │ │ ├── robotPathPlannerExample2.xml │ │ ├── robotPathPlannerExample2_nws-nwc.xml │ │ ├── robotPathPlannerExample2_nws-nwc_ros2.xml │ │ ├── robotPathPlannerExample3.xml │ │ └── robotPathPlannerExample5.xml ├── ros2Examples │ └── amcl │ │ ├── README.md │ │ ├── amcl_sim.launch.py │ │ ├── amcl_sim.launch2.py │ │ └── amcl_sim_params.yml ├── rosExamples │ ├── CMakeLists.txt │ ├── conf │ │ ├── fakeMobileBaseTest.ini │ │ ├── localizationServer_ros.ini │ │ ├── localizationServer_yarp.ini │ │ ├── robotGoto_cer.ini │ │ ├── robotGoto_ikart.ini │ │ ├── robotPathPlanner_cer.ini │ │ ├── robotPathPlanner_ikart.ini │ │ └── robotinterface │ │ │ └── rangeFinder2D.xml │ ├── launch │ │ ├── amcl_map_from_ros.launch │ │ └── ros_navigation.launch │ ├── ros_config │ │ └── navigation │ │ │ ├── costmap_common_params.yaml │ │ │ ├── dwa_local_planner_params.yaml │ │ │ ├── global_costmap_params.yaml │ │ │ ├── global_planner_params.yaml │ │ │ ├── local_costmap_params.yaml │ │ │ ├── move_base_params.yaml │ │ │ └── navfn_global_planner_params.yaml │ └── scripts │ │ ├── ros2Example1.xml │ │ ├── rosExample1.xml │ │ ├── rosExample2.xml │ │ └── rosExample3.xml └── simpleVelocityNavigationExamples │ ├── CMakeLists.txt │ ├── conf │ └── localizationServer.ini │ └── scripts │ └── simpleVelocityNavigationExample1.xml ├── src ├── CMakeLists.txt ├── baseControl2 │ ├── CMakeLists.txt │ ├── baseControl.cpp │ ├── baseControl.h │ ├── cer │ │ ├── cer_motors.cpp │ │ └── cer_motors.h │ ├── controlThread.cpp │ ├── controlThread.h │ ├── filters.cpp │ ├── filters.h │ ├── ikart │ │ ├── ikart_motors.cpp │ │ └── ikart_motors.h │ ├── input.cpp │ ├── input.h │ ├── main.cpp │ ├── motors.cpp │ └── motors.h ├── common │ ├── CMakeLists.txt │ ├── areas │ │ ├── CMakeLists.txt │ │ ├── areas.cpp │ │ └── roomsSegmentation2.cpp │ ├── include │ │ └── navigation_defines.h │ ├── movable_localization_device │ │ ├── movable_localization_device.cpp │ │ └── movable_localization_device.h │ ├── odometry_estimation │ │ ├── localization_device_with_estimated_odometry.cpp │ │ └── localization_device_with_estimated_odometry.h │ ├── planner_aStar │ │ ├── aStar.cpp │ │ ├── aStar.h │ │ ├── mapUtils.cpp │ │ └── mapUtils.h │ └── recovery_behaviors │ │ ├── recovery_behaviors.cpp │ │ ├── recovery_behaviors.h │ │ ├── stuck_detection.cpp │ │ └── stuck_detection.h ├── deprecated │ └── CMakeLists.txt ├── follower │ ├── CMakeLists.txt │ └── src │ │ ├── BTMonitor.cpp │ │ ├── BTMonitor.h │ │ ├── Ball3DPointRetriever.cpp │ │ ├── Ball3DPointRetriever.h │ │ ├── Follower.cpp │ │ ├── Follower.h │ │ ├── FollowerModule.cpp │ │ ├── FollowerModule.h │ │ ├── GazeController.cpp │ │ ├── GazeController.h │ │ ├── HumanModel3DPointRetriever.cpp │ │ ├── HumanModel3DPointRetriever.h │ │ ├── NavigationController.cpp │ │ ├── NavigationController.h │ │ ├── ObstacleAvoidance.cpp │ │ ├── ObstacleAvoidance.h │ │ ├── Person3DPointRetriever.cpp │ │ ├── Person3DPointRetriever.h │ │ ├── SimFramePainter.cpp │ │ ├── SimFramePainter.h │ │ ├── TargetRetriever.cpp │ │ ├── TargetRetriever.h │ │ ├── TimedPath.cpp │ │ ├── TimedPath.h │ │ └── main.cpp ├── forceGuidance │ ├── CMakeLists.txt │ ├── ControlThread.cpp │ ├── ControlThread.h │ ├── README.md │ └── main.cpp ├── freeFloorViewer │ ├── CMakeLists.txt │ ├── freeFloorThread.cpp │ ├── freeFloorThread.h │ ├── freeFloorViewer.cpp │ ├── freeFloorViewer.h │ ├── headOrientator.cpp │ ├── headOrientator.h │ └── main.cpp ├── localizationDevices │ ├── CMakeLists.txt │ ├── amclLocalizer │ │ ├── CMakeLists.txt │ │ ├── amcl │ │ │ ├── map │ │ │ │ ├── map.c │ │ │ │ ├── map.h │ │ │ │ ├── map_cspace.cpp │ │ │ │ ├── map_draw.c │ │ │ │ ├── map_range.c │ │ │ │ └── map_store.c │ │ │ ├── pf │ │ │ │ ├── eig3.c │ │ │ │ ├── eig3.h │ │ │ │ ├── pf.c │ │ │ │ ├── pf.h │ │ │ │ ├── pf_draw.c │ │ │ │ ├── pf_kdtree.c │ │ │ │ ├── pf_kdtree.h │ │ │ │ ├── pf_pdf.c │ │ │ │ ├── pf_pdf.h │ │ │ │ ├── pf_vector.c │ │ │ │ └── pf_vector.h │ │ │ └── sensors │ │ │ │ ├── amcl_laser.cpp │ │ │ │ ├── amcl_laser.h │ │ │ │ ├── amcl_odom.cpp │ │ │ │ ├── amcl_odom.h │ │ │ │ ├── amcl_sensor.cpp │ │ │ │ └── amcl_sensor.h │ │ ├── amclLocalizer.cpp │ │ └── amclLocalizer.h │ ├── gazeboLocalizer │ │ ├── CMakeLists.txt │ │ ├── gazeboLocalizer.cpp │ │ └── gazeboLocalizer.h │ ├── odomLocalizer │ │ ├── CMakeLists.txt │ │ ├── odomLocalizer.cpp │ │ └── odomLocalizer.h │ ├── pozyxLocalizer │ │ ├── CMakeLists.txt │ │ ├── pozyxLocalizer.cpp │ │ └── pozyxLocalizer.h │ ├── ros2Localizer │ │ ├── CMakeLists.txt │ │ ├── Ros2Spinner.cpp │ │ ├── Ros2Spinner.h │ │ ├── Ros2Utils.cpp │ │ ├── Ros2Utils.h │ │ ├── ros2Localizer.cpp │ │ └── ros2Localizer.h │ ├── rosLocalizer │ │ ├── CMakeLists.txt │ │ ├── rosLocalizer.cpp │ │ └── rosLocalizer.h │ └── t265Localizer │ │ ├── CMakeLists.txt │ │ ├── localizationServer_pb_on_ros_camera3.ini │ │ ├── t265Localizer.cpp │ │ └── t265Localizer.h ├── map2Gazebo │ ├── CMakeLists.txt │ └── main.cpp ├── navigationDevices │ ├── CMakeLists.txt │ ├── navigationDeviceTemplate │ │ ├── CMakeLists.txt │ │ ├── navigationDeviceTemplate.cpp │ │ └── navigationDeviceTemplate.h │ ├── robotGotoDevice │ │ ├── CMakeLists.txt │ │ ├── obstacles.cpp │ │ ├── obstacles.h │ │ ├── robotGotoCtrl.cpp │ │ ├── robotGotoCtrl.h │ │ ├── robotGotoDev.cpp │ │ └── robotGotoDev.h │ ├── robotPathPlannerDevice │ │ ├── CMakeLists.txt │ │ ├── pathPlannerCtrl.cpp │ │ ├── pathPlannerCtrl.h │ │ ├── pathPlannerCtrlActions.cpp │ │ ├── pathPlannerCtrlGets.cpp │ │ ├── pathPlannerCtrlHelpers.cpp │ │ ├── pathPlannerCtrlHelpers.h │ │ ├── pathPlannerCtrlInit.cpp │ │ ├── robotPathPlannerDev.cpp │ │ └── robotPathPlannerDev.h │ ├── ros2Navigator │ │ ├── CMakeLists.txt │ │ ├── Ros2Spinner.cpp │ │ ├── Ros2Spinner.h │ │ ├── Ros2Utils.cpp │ │ ├── Ros2Utils.h │ │ ├── ros2Navigator.cpp │ │ └── ros2Navigator.h │ ├── rosNavigator │ │ ├── CMakeLists.txt │ │ ├── rosNavigator.cpp │ │ └── rosNavigator.h │ ├── simpleVelocityNavigation │ │ ├── CMakeLists.txt │ │ ├── simpleVelocityNavigation.cpp │ │ └── simpleVelocityNavigation.h │ └── velocityInputHandler │ │ ├── CMakeLists.txt │ │ ├── velocityInputHandler.cpp │ │ └── velocityInputHandler.h ├── navigationGUI │ ├── CMakeLists.txt │ ├── main.cpp │ ├── map.cpp │ ├── map.h │ ├── navGui.cpp │ ├── navGui.h │ ├── navGuiHelpers.cpp │ └── navGuiInit.cpp ├── portmonitors │ ├── CMakeLists.txt │ └── joystick2velocityCommand │ │ ├── CMakeLists.txt │ │ ├── joystick2velocityCommand.cpp │ │ └── joystick2velocityCommand.h ├── ros_messages │ ├── actionlib_msgs │ │ ├── GoalID.msg │ │ ├── GoalStatus.msg │ │ └── GoalStatusArray.msg │ ├── geometry_msgs │ │ ├── Point.msg │ │ ├── Point32.msg │ │ ├── Polygon.msg │ │ ├── PolygonStamped.msg │ │ ├── Pose.msg │ │ ├── PoseStamped.msg │ │ ├── PoseWithCovariance.msg │ │ ├── PoseWithCovarianceStamped.msg │ │ ├── Quaternion.msg │ │ ├── Transform.msg │ │ ├── TransformStamped.msg │ │ ├── Twist.msg │ │ ├── TwistWithCovariance.msg │ │ └── Vector3.msg │ ├── move_base_msgs │ │ ├── MoveBaseActionFeedback.msg │ │ ├── MoveBaseActionGoal.msg │ │ ├── MoveBaseActionResult.msg │ │ ├── MoveBaseFeedback.msg │ │ ├── MoveBaseGoal.msg │ │ ├── MoveBaseResult.msg │ │ └── RecoveryStatus.msg │ ├── nav_msgs │ │ ├── MapMetaData.msg │ │ ├── OccupancyGrid.msg │ │ ├── Odometry.msg │ │ └── Path.msg │ ├── std_msgs │ │ ├── ColorRGBA.msg │ │ └── Header.msg │ ├── tf │ │ └── tfMessage.msg │ ├── tf2_msgs │ │ └── TFMessage.msg │ └── visualization_msgs │ │ ├── Marker.msg │ │ └── MarkerArray.msg ├── tests │ ├── CMakeLists.txt │ ├── navigation2DClientSnippet │ │ ├── CMakeLists.txt │ │ └── main.cpp │ ├── navigation2DClientTest │ │ ├── CMakeLists.txt │ │ ├── main.cpp │ │ ├── navigation2DClientTestModule.cpp │ │ └── navigation2DClientTestModule.h │ ├── simpleVelocityNavigationTest1 │ │ ├── CMakeLists.txt │ │ └── main.cpp │ └── simpleVelocityNavigationTest2 │ │ ├── CMakeLists.txt │ │ └── main.cpp └── tutorials │ ├── CMakeLists.txt │ ├── robotGotoExample │ ├── CMakeLists.txt │ └── main.cpp │ └── robotPathPlannerExample │ ├── CMakeLists.txt │ └── main.cpp └── tests ├── CMakeLists.txt ├── YarpBuildLocation.h.in ├── harness.cpp ├── harness.h └── misc ├── CMakeLists.txt ├── check_license.pl ├── check_style.pl ├── check_style_skip.txt ├── check_tests.py └── check_tests_skip.txt /.gitignore: -------------------------------------------------------------------------------- 1 | build* 2 | *~ 3 | *.user 4 | .vscode/settings.json 5 | -------------------------------------------------------------------------------- /app/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | # add_subdirectory(deprecated) 8 | 9 | add_subdirectory(baseControl) 10 | add_subdirectory(baseControl2) 11 | add_subdirectory(baseControl_SIM) 12 | add_subdirectory(baseControl2_SIM) 13 | 14 | add_subdirectory(robotGoto) 15 | add_subdirectory(freeFloorViewer) 16 | add_subdirectory(robotPathPlanner) 17 | add_subdirectory(robotGotoExamples) 18 | add_subdirectory(robotPathPlannerExamples) 19 | add_subdirectory(gazeboExamples) 20 | add_subdirectory(rosExamples) 21 | add_subdirectory(localizationServer) 22 | add_subdirectory(mapper2D) 23 | add_subdirectory(mapsExample) 24 | add_subdirectory(mapsSquirico) 25 | add_subdirectory(navigationGUI) 26 | add_subdirectory(multipleLaserTest) 27 | add_subdirectory(simpleVelocityNavigationExamples) 28 | 29 | -------------------------------------------------------------------------------- /app/baseControl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(appname baseControl) 2 | 3 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 4 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 5 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 6 | 7 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 8 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 9 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 10 | -------------------------------------------------------------------------------- /app/baseControl/conf/baseCtrl_cer_with_oculus.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for cer base controller 2 | robot cer 3 | part mobile_base 4 | 5 | [include "joystick_configs.ini"] 6 | 7 | [BASECTRL_GENERAL] 8 | joypad1_configuration 9 | joypad2_configuration OCULUS_TOUCH_remote_joystick 10 | robot_type cer 11 | control_mode velocity_no_pid 12 | linear_angular_ratio 0.7 13 | ratio_limiter_enabled 1 14 | input_filter_enabled 0 15 | max_linear_vel 0.30 //m/s 16 | max_angular_vel 30.0 //deg/s 17 | max_linear_acc 0.30 //m/s2 18 | max_angular_acc 80.0 //deg/s2 19 | use_ROS true 20 | 21 | [MOTORS] 22 | max_motor_pwm 10000 //pwm_units 23 | max_motor_vel 100 //deg/s 24 | motors_filter_enabled 10 25 | 26 | [JOYSTICK] 27 | linear_vel_at_full_control 0.30 //m 28 | angular_vel_at_full_control 30.0 //deg/s 29 | 30 | [LINEAR_VELOCITY_PID] 31 | kp 0.0 32 | ki 0.0 33 | kd 0.0 34 | max +200 35 | min -200 36 | 37 | [ANGULAR_VELOCITY_PID] 38 | kp 0.0 39 | ki 0.0 40 | kd 0.0 41 | max +200 42 | min -200 43 | 44 | [HEADING_VELOCITY_PID] 45 | kp 0.0 46 | ki 0.0 47 | kd 0.0 48 | max +100 49 | min -100 50 | 51 | [ROS_GENERAL] 52 | node_name /baseControl 53 | 54 | [ROS_ODOMETRY] 55 | topic_name /odometry 56 | odom_frame odom 57 | base_frame mobile_base_body_link 58 | 59 | [ROS_FOOTPRINT] 60 | topic_name /footprint 61 | footprint_frame mobile_base_body_link 62 | footprint_diameter 0.510 63 | 64 | [ROS_INPUT] 65 | topic_name /cmd_vel 66 | 67 | #[ROS_OUTPUT] 68 | #topic_name /base_vel 69 | -------------------------------------------------------------------------------- /app/baseControl/conf/baseCtrl_ikartV1.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for iKart mobile base controller 2 | robot ikart 3 | part mobile_base 4 | 5 | [include "joystick_configs.ini"] 6 | 7 | [BASECTRL_GENERAL] 8 | joypad1_configuration 9 | joypad2_configuration 10 | robot_type ikart_V1 11 | control_mode velocity_no_pid 12 | linear_angular_ratio 0.7 13 | ratio_limiter_enabled 1 14 | input_filter_enabled 0 15 | lateral_movement_enabled 1 16 | max_linear_vel 0.42 //m/s 17 | max_angular_vel 24.0 //deg/s 18 | max_linear_acc 0.30 //m/s2 19 | max_angular_acc 80.0 //deg/s2 20 | use_ROS true 21 | 22 | [MOTORS] 23 | max_motor_pwm 10000 //pwm_units 24 | max_motor_vel 100 //deg/s 25 | motors_filter_enabled 10 26 | 27 | [JOYSTICK] 28 | linear_vel_at_full_control 0.42 //m 29 | angular_vel_at_full_control 20.0 //deg/s 30 | 31 | [LINEAR_VELOCITY_PID] 32 | kp 0.0 33 | ki 0.0 34 | kd 0.0 35 | max +200 36 | min -200 37 | 38 | [ANGULAR_VELOCITY_PID] 39 | kp 0.0 40 | ki 0.0 41 | kd 0.0 42 | max +200 43 | min -200 44 | 45 | [HEADING_VELOCITY_PID] 46 | kp 0.0 47 | ki 0.0 48 | kd 0.0 49 | max +100 50 | min -100 51 | 52 | [ROS_GENERAL] 53 | node_name /baseControl 54 | 55 | [ROS_ODOMETRY] 56 | topic_name /odometry 57 | odom_frame odom 58 | base_frame mobile_base_body 59 | 60 | [ROS_FOOTPRINT] 61 | topic_name /footprint 62 | footprint_frame mobile_base_body 63 | footprint_diameter 0.38 64 | 65 | [ROS_INPUT] 66 | topic_name /cmd_vel 67 | 68 | #[ROS_OUTPUT] 69 | #topic_name /base_vel 70 | -------------------------------------------------------------------------------- /app/baseControl/conf/baseCtrl_ikartV2.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for iKart mobile base controller 2 | robot ikart 3 | part mobile_base 4 | 5 | [include "joystick_configs.ini"] 6 | 7 | [BASECTRL_GENERAL] 8 | joypad1_configuration 9 | joypad2_configuration 10 | robot_type ikart_V2 11 | control_mode velocity_no_pid 12 | linear_angular_ratio 0.7 13 | ratio_limiter_enabled 1 14 | input_filter_enabled 0 15 | lateral_movement_enabled 1 16 | max_linear_vel 0.42 //m/s 17 | max_angular_vel 24.0 //deg/s 18 | max_linear_acc 0.30 //m/s2 19 | max_angular_acc 80.0 //deg/s2 20 | use_ROS true 21 | 22 | [MOTORS] 23 | max_motor_pwm 10000 //pwm_units 24 | max_motor_vel 100 //deg/s 25 | motors_filter_enabled 10 26 | 27 | [JOYSTICK] 28 | linear_vel_at_full_control 0.42 //m 29 | angular_vel_at_full_control 20.0 //deg/s 30 | 31 | [LINEAR_VELOCITY_PID] 32 | kp 0.0 33 | ki 0.0 34 | kd 0.0 35 | max +200 36 | min -200 37 | 38 | [ANGULAR_VELOCITY_PID] 39 | kp 0.0 40 | ki 0.0 41 | kd 0.0 42 | max +200 43 | min -200 44 | 45 | [HEADING_VELOCITY_PID] 46 | kp 0.0 47 | ki 0.0 48 | kd 0.0 49 | max +100 50 | min -100 51 | 52 | [ROS_GENERAL] 53 | node_name /baseControl 54 | 55 | [ROS_ODOMETRY] 56 | topic_name /odometry 57 | odom_frame odom 58 | base_frame mobile_base_body 59 | 60 | [ROS_FOOTPRINT] 61 | topic_name /footprint 62 | footprint_frame mobile_base_body 63 | footprint_diameter 0.38 64 | 65 | [ROS_INPUT] 66 | topic_name /cmd_vel 67 | 68 | #[ROS_OUTPUT] 69 | #topic_name /base_vel 70 | -------------------------------------------------------------------------------- /app/baseControl/conf/joystick_configs.ini: -------------------------------------------------------------------------------- 1 | [XBOX_local_joystick] 2 | JoypadDevice SDL_Joypad 3 | sticks 0 4 | xAxis_id 1 5 | yAxis_id 0 6 | tAxis_id 2 7 | gainAxis_id 5 8 | xAxis_factor -100.0 9 | yAxis_factor 100.0 10 | tAxis_factor -100.0 11 | gainAxis_factor 100.0 12 | 13 | [XBOX_remote_joystick] 14 | JoypadDevice JoypadControlClient 15 | local /baseControl/joyClient 16 | remote /xboxJoypad 17 | xAxis_id 1 18 | yAxis_id 0 19 | tAxis_id 2 20 | gainAxis_id 5 21 | xAxis_factor -100.0 22 | yAxis_factor 100.0 23 | tAxis_factor -100.0 24 | gainAxis_factor 100.0 25 | 26 | [OCULUS_TOUCH_remote_joystick] 27 | JoypadDevice JoypadControlClient 28 | local /baseControl/joyClient 29 | remote /oculusJoypad 30 | xAxis_id 5 31 | yAxis_id 4 32 | tAxis_id 6 33 | gainButton_id 6 34 | xAxis_factor 100.0 35 | yAxis_factor 100.0 36 | tAxis_factor -100.0 37 | gainButton_factor 100.0 -------------------------------------------------------------------------------- /app/baseControl/scripts/baseControl.xml: -------------------------------------------------------------------------------- 1 | 2 | mobile_base_test_application 3 | 4 | 5 | r1-base 6 | 7 | 8 | 9 | robotInterface 10 | --context cer --config conf/cer.ini 11 | r1-base 12 | 13 | 14 | 15 | yarpdev 16 | --device transformServer --ROS "(enable_ros_publisher 0)" "(enable_ros_subscriber 0)" 17 | r1-base 18 | 19 | 20 | 21 | baseCtrl 22 | 23 | r1-base 24 | 25 | 26 | 27 | joystickCtrl 28 | --context joystickCtrl --from cer_linux.ini 29 | r1-base 30 | 31 | 32 | 33 | yarpmotorgui 34 | --context /cer/conf 35 | r1-console-linux 36 | 37 | 38 | 39 | laserScannerGui 40 | 41 | r1-console-linux 42 | 43 | 44 | 45 | batteryDisplay 46 | 47 | r1-console-linux 48 | 49 | 50 | 51 | /cer/laser:o 52 | /laserScannerGui/laser:i 53 | udp 54 | 55 | 56 | 57 | /joystickCtrl:o 58 | /cer/joystick:i 59 | udp 60 | 61 | 62 | 63 | -------------------------------------------------------------------------------- /app/baseControl/scripts/mobileBase Launch.sh: -------------------------------------------------------------------------------- 1 | gnome-terminal 2 | ssh cer-user@192.168.100.10 -X 3 | expect "assword:" 4 | send "cerAdmin\r" 5 | interact 6 | yarpserver 7 | ####################################### OR TRY THE FOLLOWING 8 | #!/usr/bin/expect 9 | eval spawn ssh -oStrictHostKeyChecking=no -oCheckHostIP=no cer-user@192.168.100.10 -X 10 | #use correct prompt 11 | set prompt ":|#|\\\$" 12 | interact -o -nobuffer -re $prompt return 13 | send "cerAdmin\r" 14 | interact -o -nobuffer -re $prompt return 15 | send "yarpserver\r" 16 | interact 17 | 18 | gnome-terminal 19 | ssh cer-user@192.168.100.10 -X 20 | cd /usr/local/src/robot/cer/app/robots/CER01/ 21 | robotInterface 22 | 23 | gnome-terminal 24 | ssh cer-user@192.168.100.10 -X 25 | cd /usr/local/src/robot/cer/app/robots/CER01/ 26 | yarpmotorgui --openloop 27 | 28 | gnome-terminal 29 | ssh cer-user@192.168.100.10 -X 30 | cd /usr/local/src/robot/cer/app/baseControl/conf 31 | baseControl 32 | 33 | gnome-terminal 34 | ssh cer-user@192.168.100.10 -X 35 | yarpdev --device inertial --subdevice xsensmtx -d /dev/ttyusb0 36 | 37 | 38 | gnome-terminal 39 | yarp conf 192.168.100.10 10000 40 | 41 | gnome-terminal 42 | yarpdatadumper --connect /inertial 43 | 44 | gnome-terminal 45 | sudo rmmod xpad 46 | sudo xboxdrv 47 | 48 | gnome-terminal 49 | cd $ICUB_DIR 50 | joystickCtrl --from /home/luca/workspace/icub-main/app/joystickCtrl/conf/cer_linux.ini 51 | 52 | gnome-terminal 53 | yarp connect /joystickCtrl:o /cer/joystick:i 54 | -------------------------------------------------------------------------------- /app/baseControl/scripts/transformServer.xml: -------------------------------------------------------------------------------- 1 | 2 | transform_server 3 | 4 | 5 | r1-base 6 | 7 | 8 | 9 | yarpdev 10 | --device transformServer --ROS "(enable_ros_publisher 0)" "(enable_ros_subscriber 0)" 11 | r1-base 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /app/baseControl/scripts/wheel_odometry.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /app/baseControl2/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(appname baseControl2) 2 | 3 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 4 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 5 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 6 | 7 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 8 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 9 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 10 | -------------------------------------------------------------------------------- /app/baseControl2_SIM/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(appname baseControl2_SIM) 2 | 3 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 4 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 5 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 6 | 7 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 8 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 9 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 10 | 11 | -------------------------------------------------------------------------------- /app/baseControl_SIM/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(appname baseControl_SIM) 2 | 3 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 4 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 5 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 6 | 7 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 8 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 9 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 10 | 11 | -------------------------------------------------------------------------------- /app/baseControl_SIM/conf/baseCtrl_cer_sim.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for cer base controller 2 | robot SIM_CER_ROBOT 3 | part mobile_base 4 | 5 | [include "joystick_configs.ini"] 6 | 7 | [BASECTRL_GENERAL] 8 | joypad1_configuration 9 | joypad2_configuration 10 | robot_type cer 11 | control_mode velocity_no_pid 12 | linear_angular_ratio 0.7 13 | ratio_limiter_enabled 1 14 | input_filter_enabled 0 15 | max_linear_vel 0.30 //m/s 16 | max_angular_vel 30.0 //deg/s 17 | max_linear_acc 0.30 //m/s2 18 | max_angular_acc 80.0 //deg/s2 19 | use_ROS true 20 | 21 | [MOTORS] 22 | max_motor_pwm 10000 //pwm_units 23 | max_motor_vel 100 //deg/s 24 | motors_filter_enabled 10 25 | 26 | [JOYSTICK] 27 | linear_vel_at_full_control 0.30 //m 28 | angular_vel_at_full_control 30.0 //deg/s 29 | 30 | [LINEAR_VELOCITY_PID] 31 | kp 0.0 32 | ki 0.0 33 | kd 0.0 34 | max +200 35 | min -200 36 | 37 | [ANGULAR_VELOCITY_PID] 38 | kp 0.0 39 | ki 0.0 40 | kd 0.0 41 | max +200 42 | min -200 43 | 44 | [HEADING_VELOCITY_PID] 45 | kp 0.0 46 | ki 0.0 47 | kd 0.0 48 | max +100 49 | min -100 50 | 51 | [ROS_GENERAL] 52 | node_name /baseControl 53 | 54 | [ROS_ODOMETRY] 55 | topic_name /odometry 56 | odom_frame odom 57 | base_frame mobile_base_body_link 58 | 59 | [ROS_FOOTPRINT] 60 | topic_name /footprint 61 | footprint_frame mobile_base_body_link 62 | footprint_diameter 0.510 63 | 64 | [ROS_INPUT] 65 | topic_name /cmd_vel 66 | 67 | #[ROS_OUTPUT] 68 | #topic_name /base_vel 69 | -------------------------------------------------------------------------------- /app/baseControl_SIM/conf/joystick_configs.ini: -------------------------------------------------------------------------------- 1 | [XBOX_local_joystick] 2 | JoypadDevice SDL_Joypad 3 | sticks 0 4 | xAxis_id 1 5 | yAxis_id 0 6 | tAxis_id 2 7 | gainAxis_id 5 8 | xAxis_factor -100.0 9 | yAxis_factor 100.0 10 | tAxis_factor -100.0 11 | gainAxis_factor 100.0 12 | 13 | [XBOX_remote_joystick] 14 | JoypadDevice JoypadControlClient 15 | local /baseControl/joyClient 16 | remote /xboxJoypad 17 | xAxis_id 1 18 | yAxis_id 0 19 | tAxis_id 2 20 | gainAxis_id 5 21 | xAxis_factor -100.0 22 | yAxis_factor 100.0 23 | tAxis_factor -100.0 24 | gainAxis_factor 100.0 25 | 26 | [OCULUS_TOUCH_remote_joystick] 27 | JoypadDevice JoypadControlClient 28 | local /baseControl/joyClient 29 | remote /oculusJoypad 30 | xAxis_id 5 31 | yAxis_id 4 32 | tAxis_id 6 33 | gainButton_id 6 34 | xAxis_factor 100.0 35 | yAxis_factor 100.0 36 | tAxis_factor -100.0 37 | gainButton_factor 100.0 -------------------------------------------------------------------------------- /app/baseControl_SIM/conf/robot_2wheels.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for cer base controller 2 | robot robot_2wheels 3 | part mobile_base 4 | 5 | [include "joystick_configs.ini"] 6 | 7 | [BASECTRL_GENERAL] 8 | joypad1_configuration 9 | joypad2_configuration 10 | robot_type cer 11 | control_mode velocity_no_pid 12 | linear_angular_ratio 0.7 13 | ratio_limiter_enabled 1 14 | input_filter_enabled 0 15 | max_linear_vel 0.30 //m/s 16 | max_angular_vel 30.0 //deg/s 17 | max_linear_acc 0.30 //m/s2 18 | max_angular_acc 80.0 //deg/s2 19 | use_ROS true 20 | 21 | [MOTORS] 22 | max_motor_pwm 10000 //pwm_units 23 | max_motor_vel 100 //deg/s 24 | motors_filter_enabled 10 25 | 26 | [JOYSTICK] 27 | linear_vel_at_full_control 0.30 //m 28 | angular_vel_at_full_control 30.0 //deg/s 29 | 30 | [LINEAR_VELOCITY_PID] 31 | kp 0.0 32 | ki 0.0 33 | kd 0.0 34 | max +200 35 | min -200 36 | 37 | [ANGULAR_VELOCITY_PID] 38 | kp 0.0 39 | ki 0.0 40 | kd 0.0 41 | max +200 42 | min -200 43 | 44 | [HEADING_VELOCITY_PID] 45 | kp 0.0 46 | ki 0.0 47 | kd 0.0 48 | max +100 49 | min -100 50 | 51 | [ROS_GENERAL] 52 | node_name /baseControl 53 | 54 | [ROS_ODOMETRY] 55 | topic_name /odometry 56 | odom_frame odom 57 | base_frame mobile_base_body_link 58 | 59 | [ROS_FOOTPRINT] 60 | topic_name /footprint 61 | footprint_frame mobile_base_body_link 62 | footprint_diameter 0.510 63 | 64 | [ROS_INPUT] 65 | topic_name /cmd_vel 66 | 67 | #[ROS_OUTPUT] 68 | #topic_name /base_vel 69 | -------------------------------------------------------------------------------- /app/baseControl_SIM/conf/robot_3wheels.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for iKart mobile base controller 2 | robot robot_3wheels 3 | part mobile_base 4 | 5 | [include "joystick_configs.ini"] 6 | 7 | [BASECTRL_GENERAL] 8 | joypad1_configuration 9 | joypad2_configuration 10 | robot_type ikart_V2 11 | control_mode velocity_no_pid 12 | linear_angular_ratio 0.7 13 | ratio_limiter_enabled 1 14 | input_filter_enabled 0 15 | lateral_movement_enabled 1 16 | max_linear_vel 0.42 //m/s 17 | max_angular_vel 24.0 //deg/s 18 | max_linear_acc 0.30 //m/s2 19 | max_angular_acc 80.0 //deg/s2 20 | use_ROS true 21 | 22 | [MOTORS] 23 | max_motor_pwm 10000 //pwm_units 24 | max_motor_vel 100 //deg/s 25 | motors_filter_enabled 10 26 | 27 | [JOYSTICK] 28 | linear_vel_at_full_control 0.42 //m 29 | angular_vel_at_full_control 20.0 //deg/s 30 | 31 | [LINEAR_VELOCITY_PID] 32 | kp 0.0 33 | ki 0.0 34 | kd 0.0 35 | max +200 36 | min -200 37 | 38 | [ANGULAR_VELOCITY_PID] 39 | kp 0.0 40 | ki 0.0 41 | kd 0.0 42 | max +200 43 | min -200 44 | 45 | [HEADING_VELOCITY_PID] 46 | kp 0.0 47 | ki 0.0 48 | kd 0.0 49 | max +100 50 | min -100 51 | 52 | [ROS_GENERAL] 53 | node_name /baseControl 54 | 55 | [ROS_ODOMETRY] 56 | topic_name /odometry 57 | odom_frame odom 58 | base_frame mobile_base_body 59 | 60 | [ROS_FOOTPRINT] 61 | topic_name /footprint 62 | footprint_frame mobile_base_body 63 | footprint_diameter 0.38 64 | 65 | [ROS_INPUT] 66 | topic_name /cmd_vel 67 | 68 | #[ROS_OUTPUT] 69 | #topic_name /base_vel 70 | -------------------------------------------------------------------------------- /app/deprecated/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/follower/conf/follower.ini: -------------------------------------------------------------------------------- 1 | [FOLLOWER_GENERAL] 2 | inputPort targetPoints 3 | outputPort commands 4 | targetType person 5 | startWithoutCommand false 6 | autonomousNavEnabled true 7 | invalidTargetMax 21 8 | onSimulator false 9 | period 0.05 10 | 11 | [NAVIGATION] 12 | factorDist2Vel 0.2 13 | factorAng2Vel 0.4 14 | distanceThreshold 1.2 15 | angleThreshold 5 16 | angularVelLimit 5 17 | linearVelLimit 0.3 18 | angleLimitsVelReduction (10 30) 19 | 20 | [DEBUG] 21 | enable true 22 | paintGazeFrame false 23 | printPeriod 0.5 24 | durationInfoStat_count 0 25 | 26 | [OBSTACLE_AVOIDANCE] 27 | enabled true 28 | maxDistance 0.9 29 | robotRadius 0.3 30 | robotLaserPortName "/cer/laser:o" 31 | 32 | [GAZE] 33 | pixel_x_range (140 180) 34 | pixel_y_range (100 140) 35 | trajTimeInLookingup 10 36 | trajTime_timeout 15 37 | 38 | -------------------------------------------------------------------------------- /app/follower/conf/follower_SIM.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for follower module 2 | 3 | 4 | [FOLLOWER_GENERAL] 5 | inputPort targetPoints 6 | outputPort commands 7 | ///targetType redball 8 | targetType fakehumanmodel 9 | startWithoutCommand true 10 | autonomousNavEnabled false 11 | invalidTargetMax 10 12 | onSimulator true 13 | period 0.05 14 | 15 | [NAVIGATION] 16 | factorDist2Vel 0.8 17 | factorAng2Vel 0.8 18 | distanceThreshold 1.2 19 | angleThreshold 5 20 | angularVelLimit 5 21 | linearVelLimit 2 22 | angleLimitsVelReduction (10 30) 23 | 24 | [DEBUG] 25 | enable true 26 | paintGazeFrame false 27 | printPeriod 0.5 28 | durationInfoStat_count 0 29 | 30 | [OBSTACLE_AVOIDANCE] 31 | enabled true 32 | maxDistance 0.9 33 | robotRadius 0.3 34 | robotLaserPortName "/SIM_CER_ROBOT/laser:o" 35 | 36 | [GAZE] 37 | pixel_x_range (300 340) 38 | pixel_y_range (210 250) 39 | trajTimeInLookingup 15 40 | trajTime_timeout 30 41 | -------------------------------------------------------------------------------- /app/follower/scripts/navigationSetup.xml: -------------------------------------------------------------------------------- 1 | 2 | Navigation setup for follower 3 | 4 | 5 | 6 | 7 | 8 | 9 | yarpdev 10 | --device map2DServer --mapCollectionContext mapsExample 11 | console 12 | 13 | 14 | 15 | yarpdev 16 | --device localization2DServer --subdevice gazeboLocalizer --context robotPathPlannerExamples --from localizationServer_useEmptyMap.ini 17 | console 18 | 19 | 20 | 21 | 22 | yarpdev 23 | --device navigation2DServer --subdevice robotPathPlannerDev --context robotPathPlannerExamples --from robotPathPlanner_sim_cer.ini 24 | console 25 | 26 | 27 | 28 | navigationGUI 29 | --context navigationGUI --from navigationGUI_sim_cer.ini 30 | console 31 | 32 | 33 | 34 | yarpview 35 | --name /navView:i --out /mapClick:o 36 | console 37 | 38 | 39 | 40 | /robotGoto/control:o 41 | /baseControl/control:i 42 | udp 43 | 44 | 45 | 46 | /navigationGui/map:o 47 | /navView:i 48 | udp 49 | 50 | 51 | 52 | /robotPathPlanner/commands:o 53 | /robotGoto/rpc 54 | tcp 55 | 56 | 57 | 58 | 59 | 60 | /mapClick:o 61 | /navigationGui/yarpviewTarget:i 62 | tcp 63 | 64 | 65 | 66 | 67 | -------------------------------------------------------------------------------- /app/freeFloorViewer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Ettore Landini ettore.landini@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname freeFloorViewer) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | 17 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/freeFloorViewer_R1SN003.ini: -------------------------------------------------------------------------------- 1 | publish_ROS_pointcloud 2 | thread_period 0.1 3 | period 0.1 4 | rpc_port /freeFloorViewer/rpc 5 | clicked_pos_port /freeFloorViewer/clicked_pos:i 6 | target_pos_port /freeFloorViewer/target:o 7 | img_out_port /freeFloorViewer/floorEnhanced:o 8 | self_reliant 0 9 | 10 | [ROS] 11 | useROS true 12 | ROS_nodeName /cer-laserRGBD 13 | ROS_topicName /laserDepth 14 | frame_id /mobile_base_double_lidar 15 | 16 | [SENSOR] 17 | resolution 0.5 18 | 19 | [RGBD_SENSOR_CLIENT] 20 | device RGBDSensorClient 21 | localImagePort /clientRgbPort:i 22 | localDepthPort /clientDepthPort:i 23 | localRpcPort /clientRpcPort 24 | remoteImagePort /cer/realsense_repeater/rgbImage:o 25 | remoteDepthPort /cer/realsense_repeater/depthImage:o 26 | remoteRpcPort /cer/realsense_repeater/rpc:i 27 | ImageCarrier fast_tcp 28 | DepthCarrier fast_tcp 29 | 30 | [NAVIGATION_CLIENT] 31 | device navigation2D_nwc_yarp 32 | local /freeFloorViewer/navClient 33 | navigation_server /navigation2D_nws_yarp 34 | map_locations_server /map2D_nws_yarp 35 | localization_server /localization2D_nws_yarp 36 | 37 | [BASE_CONTROL] 38 | base_ctrl_port /freeFloorViewer/baseVelCmd:o 39 | max_angular_vel 20.0 40 | 41 | [POINTCLOUD_QUALITY] 42 | x_step 4 43 | y_step 4 44 | 45 | [HEAD_CONTROL_CLIENT] 46 | device remote_controlboard 47 | local /freeFloorViewer/head 48 | remote /cer/head 49 | 50 | [Z_CLIPPING_PLANES] 51 | floor_height 0.2 52 | ceiling_height 2.1 53 | column_granularity 5 54 | camera_frame_id extra_camera_tf 55 | ground_frame_id ground_link 56 | extern_ref_frame_id map 57 | 58 | 59 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/freeFloorViewer_sim_tour.ini: -------------------------------------------------------------------------------- 1 | publish_ROS_pointcloud 2 | thread_period 0.1 3 | period 1 4 | rpc_port /freeFloorViewer/rpc 5 | clicked_pos_port /freeFloorViewer/clicked_pos:i 6 | target_pos_port /freeFloorViewer/target:o 7 | img_out_port /freeFloorViewer/floorEnhanced:o 8 | self_reliant 0 9 | 10 | [ROS] 11 | useROS true 12 | ROS_nodeName /cer-laserRGBD 13 | ROS_topicName /laserDepth 14 | frame_id /mobile_base_double_lidar 15 | 16 | [SENSOR] 17 | resolution 0.5 18 | 19 | [RGBD_SENSOR_CLIENT] 20 | device RGBDSensorClient 21 | localImagePort /clientRgbPort:i 22 | localDepthPort /clientDepthPort:i 23 | localRpcPort /clientRpcPort 24 | remoteImagePort /SIM_CER_ROBOT/depthCamera/rgbImage:o 25 | remoteDepthPort /SIM_CER_ROBOT/depthCamera/depthImage:o 26 | remoteRpcPort /SIM_CER_ROBOT/depthCamera/rpc:i 27 | ImageCarrier fast_tcp 28 | DepthCarrier fast_tcp 29 | 30 | [NAVIGATION_CLIENT] 31 | device navigation2D_nwc_yarp 32 | local /freeFloorViewer/navClient 33 | navigation_server /navigation2D_nws_yarp 34 | map_locations_server /map2D_nws_yarp 35 | localization_server /localization2D_nws_yarp 36 | 37 | 38 | [POINTCLOUD_QUALITY] 39 | x_step 4 40 | y_step 4 41 | 42 | [HEAD_CONTROL_CLIENT] 43 | device remote_controlboard 44 | local /freeFloorViewer/head 45 | remote /SIM_CER_ROBOT/head 46 | 47 | [Z_CLIPPING_PLANES] 48 | floor_height 0.1 49 | ceiling_height 2.1 50 | column_granularity 5 51 | camera_frame_id depth_center 52 | ground_frame_id ground_link 53 | extern_ref_frame_id map 54 | 55 | 56 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/gazeboLocalizer.ini: -------------------------------------------------------------------------------- 1 | [GAZEBOLOCALIZER_GENERAL] 2 | name /localizationServer 3 | enable_ros 0 4 | local_name /gazeboLocalizer 5 | robot_name SIM_CER_ROBOT 6 | world_interface_port /world_input_port 7 | 8 | 9 | [LOCALIZATION] 10 | use_localization_from_odometry_port 1 11 | use_localization_from_tf 0 12 | 13 | [MAP] 14 | connect_to_yarp_mapserver 1 15 | 16 | [ROS] 17 | initialpose_topic initialpose 18 | occupancygrid_topic occupancy_map 19 | 20 | [TF] 21 | robot_frame_id mobile_base_body_link 22 | map_frame_id map 23 | 24 | [ODOMETRY] 25 | odometry_broadcast_port /baseControl/odometry:o 26 | 27 | [INITIAL_POS] 28 | initial_map emptyMap 29 | map_transform_x 0.0 30 | map_transform_y 0.0 31 | map_transform_t 0.0 32 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/odomLocalizer_cer02.ini: -------------------------------------------------------------------------------- 1 | [ODOMLOCALIZER_GENERAL] 2 | name /localizationServer 3 | enable_ros 0 4 | 5 | 6 | [LOCALIZATION] 7 | use_localization_from_odometry_port 1 8 | use_localization_from_tf 0 9 | 10 | [MAP] 11 | connect_to_yarp_mapserver 1 12 | 13 | [ROS] 14 | initialpose_topic initialpose 15 | occupancygrid_topic occupancy_map 16 | 17 | [TF] 18 | robot_frame_id mobile_base_body_link 19 | map_frame_id map 20 | 21 | [ODOMETRY] 22 | odometry_broadcast_port /baseControl/odometry:o 23 | 24 | [INITIAL_POS] 25 | initial_map emptyMap 26 | initial_x 0.0 27 | inititial_y 0.0 28 | inititial_theta 0.0 29 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/robotGoto_cer02.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body_link 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /cer/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0 14 | laser_pos_y 0 15 | laser_pos_theta 0 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 0 19 | max_gamma_angle 5.0 20 | ang_speed_gain 0.3 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 15.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 44 | 45 | [ROS] 46 | rosNodeName /robotGoto 47 | useGoalFromRosTopic true 48 | goalTopicName /move_base_simple/goal 49 | publishRosStuff true 50 | currentGoalTopicName /robotGoto/Goal 51 | localPlanTopicName /robotGoto/localplan 52 | globalPlanTopicName /robotGoto/globalplan 53 | 54 | 55 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/robotGoto_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body_link 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /SIM_CER_ROBOT/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0 14 | laser_pos_y 0 15 | laser_pos_theta 0 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 0 19 | max_gamma_angle 5.0 20 | ang_speed_gain 0.3 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 15.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 44 | 45 | [ROS] 46 | rosNodeName /robotGoto 47 | useGoalFromRosTopic true 48 | goalTopicName /move_base_simple/goal 49 | publishRosStuff true 50 | currentGoalTopicName /robotGoto/Goal 51 | localPlanTopicName /robotGoto/localplan 52 | globalPlanTopicName /robotGoto/globalplan 53 | 54 | 55 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/robotPathPlanner_cer02.ini: -------------------------------------------------------------------------------- 1 | [ROBOTPATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [INTERNAL_NAVIGATOR] 26 | plugin robotGotoDev 27 | context freeFloorViewer 28 | from robotGoto_cer02.ini 29 | 30 | [LOCALIZATION] 31 | robot_frame_id mobile_base_body_link 32 | map_frame_id map 33 | 34 | [LASER] 35 | laser_port /cer/laser:o 36 | 37 | [ROBOT_GEOMETRY] 38 | robot_radius 0.30 39 | laser_pos_x 0 40 | laser_pos_y 0 41 | laser_pos_theta 0 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /app/freeFloorViewer/conf/robotPathPlanner_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [INTERNAL_NAVIGATOR] 26 | plugin robotGotoDev 27 | context freeFloorViewer 28 | from robotGoto_sim_cer.ini 29 | 30 | [LOCALIZATION] 31 | robot_frame_id mobile_base_body_link 32 | map_frame_id map 33 | 34 | [LASER] 35 | laser_port /SIM_CER_ROBOT/laser:o 36 | 37 | [ROBOT_GEOMETRY] 38 | robot_radius 0.30 39 | laser_pos_x 0 40 | laser_pos_y 0 41 | laser_pos_theta 0 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_R1SN003.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_R1SN003 3 | 4 | 5 | 6 | 7 | 8 | freeFloorViewer 9 | --context freeFloorViewer --from freeFloorViewer_complete_R1SN003.ini 10 | YARP_PORTNUMBER_freeFloorViewer_floorEnhanced_o=21000 11 | console2 12 | 13 | 14 | 15 | yarpview 16 | --name /view/floorView:i --out /view/floorClick:o --rightout /view/headClick:o 17 | console2 18 | 19 | 20 | 21 | /freeFloorViewer/floorEnhanced:o 22 | /view/floorView:i 23 | fast_tcp 24 | 25 | 26 | 27 | /view/floorClick:o 28 | /freeFloorViewer/clicked_pos:i 29 | fast_tcp 30 | 31 | 32 | 33 | /view/headClick:o 34 | /freeFloorViewer/clicked_head:i 35 | fast_tcp 36 | 37 | 38 | 39 | /freeFloorViewer/baseVelCmd:o 40 | /baseControl/input/aux:i 41 | fast_tcp 42 | 43 | 44 | 45 | /baseControl/filtered_commands:o 46 | /freeFloorViewer/baseCtrlCmd:i 47 | fast_tcp 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_R1SN003_ROS2.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_R1SN003_ROS2 3 | 4 | 5 | 6 | 7 | 8 | freeFloorViewer 9 | --context freeFloorViewer --from freeFloorViewer_R1SN003_ROS2.ini 10 | YARP_PORTNUMBER_freeFloorViewer_floorEnhanced_o=21000 11 | console 12 | 13 | 14 | 15 | yarpview 16 | --name /view/floorView:i --out /view/floorClick:o --rightout /view/headClick:o 17 | console 18 | 19 | 20 | 21 | /freeFloorViewer/floorEnhanced:o 22 | /view/floorView:i 23 | mjpeg 24 | 25 | 26 | 27 | /view/floorClick:o 28 | /freeFloorViewer/clicked_pos:i 29 | fast_tcp 30 | 31 | 32 | 33 | /view/headClick:o 34 | /freeFloorViewer/clicked_head:i 35 | fast_tcp 36 | 37 | 38 | 39 | /freeFloorViewer/baseVelCmd:o 40 | /baseControl/input/aux/data:i 41 | fast_tcp 42 | 43 | 44 | 45 | /baseControl/filtered_commands:o 46 | /freeFloorViewer/baseCtrlCmd:i 47 | fast_tcp 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_R1_SIM.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_R1_SIM 3 | 4 | 5 | 6 | 7 | 8 | freeFloorViewer 9 | --context freeFloorViewer --from freeFloorViewer_R1_SIM.ini 10 | YARP_PORTNUMBER_freeFloorViewer_floorEnhanced_o=21000 11 | console 12 | 13 | 14 | 15 | yarpview 16 | --name /view/floorView:i --out /view/floorClick:o --rightout /view/headClick:o 17 | console 18 | 19 | 20 | 21 | /freeFloorViewer/floorEnhanced:o 22 | /view/floorView:i 23 | fast_tcp 24 | 25 | 26 | 27 | /view/floorClick:o 28 | /freeFloorViewer/clicked_pos:i 29 | fast_tcp 30 | 31 | 32 | 33 | /view/headClick:o 34 | /freeFloorViewer/clicked_head:i 35 | fast_tcp 36 | 37 | 38 | 39 | /freeFloorViewer/baseVelCmd:o 40 | /baseControl/input/aux:i 41 | fast_tcp 42 | 43 | 44 | 45 | /baseControl/filtered_commands:o 46 | /freeFloorViewer/baseCtrlCmd:i 47 | fast_tcp 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_R1_SIM_DISTRIBUTED.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_R1_SIM_DISTRIBUTED 3 | 4 | 5 | 6 | 7 | 8 | freeFloorViewer 9 | --context freeFloorViewer --from freeFloorViewer_R1_SIM.ini 10 | YARP_PORTNUMBER_freeFloorViewer_floorEnhanced_o=21000 11 | console2 12 | 13 | 14 | 15 | yarpview 16 | --name /view/floorView:i --out /view/floorClick:o --rightout /view/headClick:o 17 | console2 18 | 19 | 20 | 21 | /freeFloorViewer/floorEnhanced:o 22 | /view/floorView:i 23 | fast_tcp 24 | 25 | 26 | 27 | /view/floorClick:o 28 | /freeFloorViewer/clicked_pos:i 29 | fast_tcp 30 | 31 | 32 | 33 | /view/headClick:o 34 | /freeFloorViewer/clicked_head:i 35 | fast_tcp 36 | 37 | 38 | 39 | /freeFloorViewer/baseVelCmd:o 40 | /baseControl/input/aux:i 41 | fast_tcp 42 | 43 | 44 | 45 | /baseControl/filtered_commands:o 46 | /freeFloorViewer/baseCtrlCmd:i 47 | fast_tcp 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_R1_SIM_ROS2.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_R1_SIM_ROS2 3 | 4 | 5 | 6 | 7 | 8 | freeFloorViewer 9 | --context freeFloorViewer --from freeFloorViewer_R1_SIM_ROS2.ini 10 | YARP_PORTNUMBER_freeFloorViewer_floorEnhanced_o=21000 11 | console 12 | 13 | 14 | 15 | yarpview 16 | --name /view/floorView:i --out /view/floorClick:o --rightout /view/headClick:o 17 | console 18 | 19 | 20 | 21 | /freeFloorViewer/floorEnhanced:o 22 | /view/floorView:i 23 | fast_tcp 24 | 25 | 26 | 27 | /view/floorClick:o 28 | /freeFloorViewer/clicked_pos:i 29 | fast_tcp 30 | 31 | 32 | 33 | /view/headClick:o 34 | /freeFloorViewer/clicked_head:i 35 | fast_tcp 36 | 37 | 38 | 39 | /freeFloorViewer/baseVelCmd:o 40 | /baseControl/input/aux/data:i 41 | fast_tcp 42 | 43 | 44 | 45 | /baseControl/filtered_commands:o 46 | /freeFloorViewer/baseCtrlCmd:i 47 | fast_tcp 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_complete_R1SN003.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_complete_R1SN003 3 | 4 | 5 | 6 | 7 | 8 | Navigation_ROS_R1SN003 9 | 10 | 11 | 12 | 13 | open_pose_stuff 14 | 15 | 16 | 17 | 18 | freeFloorViewer_R1SN003 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_complete_R1SN003_ROS2.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_complete_R1SN003_ROS2 3 | 4 | 5 | 6 | 7 | 8 | Navigation_ROS2_R1SN003 9 | 10 | 11 | 12 | 13 | freeFloorViewer_R1SN003_ROS2 14 | 15 | 16 | 17 | 18 | navigationGUI 19 | --context navigationGUI --from navigationGUI_base_nws-nwc.ini --LASER::remote_laser /cer/laser:o --LASER::laser_client rangefinder2D_nwc_yarp --NAVIGATIONGUI_GENERAL::draw_and_publish_period 1.0 --UPDATE_DATA::period_laser_data 0.5 20 | console 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_complete_R1_SIM.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_complete_R1_SIM 3 | 4 | 5 | 6 | 7 | 8 | Navigation_ROS_R1_SIM 9 | 10 | 11 | 12 | 13 | freeFloorViewer_R1_SIM 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_complete_R1_SIM_DISTRIBUTED.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_complete_R1_SIM_DISTRIBUTED 3 | 4 | 5 | 6 | 7 | 8 | Navigation_ROS_R1_SIM_DISTRIBUTED 9 | 10 | 11 | 12 | 13 | freeFloorViewer_R1_SIM_DISTRIBUTED 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /app/freeFloorViewer/scripts/freeFloorViewer_complete_R1_SIM_ROS2.xml: -------------------------------------------------------------------------------- 1 | 2 | freeFloorViewer_complete_R1_SIM_ROS2 3 | 4 | 5 | 6 | 7 | 8 | Navigation_ROS2_R1_SIM 9 | 10 | 11 | 12 | 13 | freeFloorViewer_R1_SIM_ROS2 14 | 15 | 16 | 17 | 18 | navigationGUI 19 | --context navigationGUI --from navigationGUI_base_nws-nwc.ini --LASER::remote_laser /SIM_CER_ROBOT/laser:o --LASER::laser_client rangefinder2D_nwc_yarp --NAVIGATIONGUI_GENERAL::draw_and_publish_period 1.0 --UPDATE_DATA::period_laser_data 0.5 20 | console 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /app/gazeboExamples/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname gazeboExamples) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | -------------------------------------------------------------------------------- /app/gazeboExamples/conf/gazeboLocalizer.ini: -------------------------------------------------------------------------------- 1 | [GAZEBOLOCALIZER_GENERAL] 2 | enable_ros 0 3 | name /gazeboLocalizer 4 | robot_name SIM_CER_ROBOT 5 | world_interface_port /world_input_port 6 | 7 | 8 | [LOCALIZATION] 9 | use_localization_from_odometry_port 1 10 | use_localization_from_tf 0 11 | 12 | [MAP] 13 | connect_to_yarp_mapserver 1 14 | 15 | [ROS] 16 | initialpose_topic initialpose 17 | occupancygrid_topic occupancy_map 18 | 19 | [TF] 20 | robot_frame_id mobile_base_body_link 21 | map_frame_id map 22 | 23 | [ODOMETRY] 24 | odometry_broadcast_port /baseControl/odometry:o 25 | 26 | [INITIAL_POS] 27 | initial_map emptyMap 28 | map_transform_x 0.0 29 | map_transform_y 0.0 30 | map_transform_t 0.0 31 | -------------------------------------------------------------------------------- /app/gazeboExamples/conf/navigationGUI_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [NAVIGATIONGUI_GENERAL] 2 | publish_map_image_Hz 15 3 | publish_estimated_poses_Hz 1 4 | 5 | [LOCALIZATION] 6 | robot_frame_id mobile_base_body_link 7 | map_frame_id map 8 | 9 | [LASER] 10 | remote_laser /SIM_CER_ROBOT/laser:o 11 | 12 | [ROBOT_GEOMETRY] 13 | robot_radius 0.30 14 | laser_pos_x 0 15 | laser_pos_y 0 16 | laser_pos_theta 0 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/gazeboExamples/conf/robotGoto_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body_link 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /SIM_CER_ROBOT/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0 14 | laser_pos_y 0 15 | laser_pos_theta 0 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 0 19 | max_gamma_angle 5.0 20 | ang_speed_gain 0.3 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 15.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 44 | 45 | [ROS] 46 | rosNodeName /robotGoto 47 | useGoalFromRosTopic true 48 | goalTopicName /move_base_simple/goal 49 | publishRosStuff true 50 | currentGoalTopicName /robotGoto/Goal 51 | localPlanTopicName /robotGoto/localplan 52 | globalPlanTopicName /robotGoto/globalplan 53 | 54 | 55 | -------------------------------------------------------------------------------- /app/gazeboExamples/conf/robotPathPlanner_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [INTERNAL_NAVIGATOR] 26 | plugin robotGotoDev 27 | context gazeboExamples 28 | from robotGoto_sim_cer.ini 29 | 30 | [LOCALIZATION] 31 | robot_frame_id mobile_base_body_link 32 | map_frame_id map 33 | 34 | [LASER] 35 | laser_port /SIM_CER_ROBOT/laser:o 36 | 37 | [ROBOT_GEOMETRY] 38 | robot_radius 0.30 39 | laser_pos_x 0 40 | laser_pos_y 0 41 | laser_pos_theta 0 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /app/iKartNav/conf/iKartNav.ini: -------------------------------------------------------------------------------- 1 | local /ikartnav 2 | remote /ikart 3 | radius 0.3575 4 | laser_pos 0.245 5 | max_speed 0.125 6 | max_ang_speed 9.0 7 | linear_acc 0.25 8 | rot_acc 18.0 9 | num_range_samples 1081 10 | range_max_dist 9.5 11 | range_ang_res 0.25 12 | -------------------------------------------------------------------------------- /app/iKartNav/scripts/iKartNav.xml.template: -------------------------------------------------------------------------------- 1 | 2 | iKart Navigation Application 3 | 4 | 5 | ikart 6 | 7 | 8 | 9 | iKartNav 10 | --context ikart --config conf/iKartNav.ini 11 | ikart 12 | iKartNavigation 13 | 14 | 15 | 16 | iKartUtils 17 | icub14 18 | iKartUtils 19 | 20 | 21 | 22 | /ikart/laser:o 23 | /ikartnav/laser:i 24 | tcp 25 | 26 | 27 | 28 | /ikart/odometry:o 29 | /ikartnav/odometry:i 30 | tcp 31 | 32 | 33 | 34 | /ikartnav/control:o 35 | /ikart/control:i 36 | tcp 37 | 38 | 39 | 40 | /ikartnav/resetodometry:o 41 | /ikart/rpc 42 | tcp 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /app/localizationServer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname localizationServer) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | 17 | -------------------------------------------------------------------------------- /app/localizationServer/conf/odomLocalizer.ini: -------------------------------------------------------------------------------- 1 | [ODOMLOCALIZER_GENERAL] 2 | name /odomLocalizer 3 | enable_ros 1 4 | 5 | [LOCALIZATION] 6 | use_localization_from_odometry_port 0 7 | use_localization_from_tf 1 8 | 9 | [MAP] 10 | connect_to_yarp_mapserver 1 11 | 12 | [ROS] 13 | initialpose_topic initialpose 14 | occupancygrid_topic occupancy_map 15 | 16 | [TF] 17 | robot_frame_id mobile_base_body_link 18 | map_frame_id map 19 | 20 | [ODOMETRY] 21 | odometry_broadcast_port /baseControl/odometry:o 22 | 23 | [INITIAL_POS] 24 | initial_map emptyMap 25 | initial_x 0.0 26 | initial_y 0.0 27 | initial_theta 0.0 28 | 29 | -------------------------------------------------------------------------------- /app/localizationServer/scripts/odomLocalizer_test.xml: -------------------------------------------------------------------------------- 1 | 2 | odomLocalizer_test 3 | 4 | 5 | 6 | 7 | 8 | yarpdev 9 | ---device localization2DServer --subdevice odomLocalizer --context localizationServer --from odomLocalizer.ini 10 | console 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /app/mapper2D/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2017 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname mapper2D) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | 17 | -------------------------------------------------------------------------------- /app/mapper2D/conf/mapper2D.ini: -------------------------------------------------------------------------------- 1 | [GENERAL] 2 | module_name mapper2D 3 | enable_ros 1 4 | use_laser 1 5 | use_localization 1 6 | 7 | [LOCALIZATION] 8 | use_localization_from_odometry_port 0 9 | use_localization_from_tf 1 10 | 11 | [MAP] 12 | map_name giorgio_complete 13 | map_width 10 14 | map_height 10 15 | map_resolution 0.05 16 | 17 | [ROS] 18 | map_publish_period 1.0 19 | initialpose_topic initialpose 20 | occupancygrid_topic occupancy_map 21 | 22 | [TF] 23 | robot_frame_id mobile_base_body_link 24 | map_frame_id map 25 | 26 | [ODOMETRY] 27 | odometry_broadcast_port /baseControl/odometry:o 28 | 29 | [LASER] 30 | laser_port /cer/laser:o 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0 35 | laser_pos_y 0 36 | laser_pos_theta 0 37 | 38 | -------------------------------------------------------------------------------- /app/mapper2D/scripts/mapper2D.xml: -------------------------------------------------------------------------------- 1 | 2 | mapper2D 3 | 4 | 5 | 6 | 7 | 8 | mapper2D 9 | --context mapper2D --from mapper2D.ini 10 | console 11 | 12 | 13 | 14 | yarpview 15 | --name /mapperView:i --out /mapperClick:o 16 | console 17 | 18 | 19 | 20 | /mapperClick:o 21 | /mapper2D/yarpviewTarget:i 22 | tcp 23 | 24 | 25 | 26 | /mapper2D/map:o 27 | /mapperView:i 28 | udp 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /app/mapsExample/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | file(GLOB maps ${CMAKE_CURRENT_SOURCE_DIR}/*.*) 8 | 9 | yarp_install(FILES ${maps} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/mapsExample) 10 | -------------------------------------------------------------------------------- /app/mapsExample/locations.ini: -------------------------------------------------------------------------------- 1 | Version: 2 | 1 3 | Locations: 4 | office testMap 0.0 0.0 0.0 5 | living_room testMap 2.0 0.0 0.0 6 | Areas: 7 | area1 testMap 3 1.0 1.0 2.0 1.0 2.0 2.0 8 | area2 testMap 4 -1.0 -1.0 -2.0 -1.0 -2.0 -2.0 -3.0 -3.0 9 | -------------------------------------------------------------------------------- /app/mapsExample/map_empty.map: -------------------------------------------------------------------------------- 1 | #The YARP root map description file. 2 | #it points to yarp flag maps 3 | #it points to ROS occupancy grid (optional) 4 | 5 | MapName emptyMap 6 | YarpMapData map_empty_yarpflags.ppm 7 | RosMapData map_empty_grid.yaml 8 | -------------------------------------------------------------------------------- /app/mapsExample/map_empty_grid.pgm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_empty_grid.pgm -------------------------------------------------------------------------------- /app/mapsExample/map_empty_grid.yaml: -------------------------------------------------------------------------------- 1 | image: map_empty_grid.pgm 2 | resolution: 0.050000 3 | origin: [-10.00000, -10.00000, 0.000000] 4 | negate: 0 5 | occupied_thresh: 0.65 6 | free_thresh: 0.196 7 | -------------------------------------------------------------------------------- /app/mapsExample/map_empty_yarpflags.ppm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_empty_yarpflags.ppm -------------------------------------------------------------------------------- /app/mapsExample/map_isaac.map: -------------------------------------------------------------------------------- 1 | #The YARP root map description file. 2 | #it points to yarp flag maps 3 | #it points to ROS occupancy grid (optional) 4 | 5 | MapName isaacMap 6 | YarpMapData map_isaac_yarpflags.png 7 | 8 | resolution 0.02 9 | origin (0 -10.56 -90) 10 | 11 | -------------------------------------------------------------------------------- /app/mapsExample/map_isaac.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_isaac.png -------------------------------------------------------------------------------- /app/mapsExample/map_isaac_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_isaac_small.png -------------------------------------------------------------------------------- /app/mapsExample/map_isaac_yarpflags.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_isaac_yarpflags.png -------------------------------------------------------------------------------- /app/mapsExample/map_test.map: -------------------------------------------------------------------------------- 1 | #The YARP root map description file. 2 | #it points to yarp flag maps 3 | #it points to ROS occupancy grid (optional) 4 | 5 | MapName testMap 6 | YarpMapData map_test_yarpflags.ppm 7 | RosMapData map_test_grid.yaml -------------------------------------------------------------------------------- /app/mapsExample/map_test2.map: -------------------------------------------------------------------------------- 1 | #The YARP root map description file. 2 | #it points to yarp flag maps 3 | #it points to ROS occupancy grid (optional) 4 | 5 | MapName testMap2 6 | YarpMapData map_test2_yarpflags.ppm 7 | RosMapData map_test2_grid.yaml -------------------------------------------------------------------------------- /app/mapsExample/map_test2_grid.pgm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_test2_grid.pgm -------------------------------------------------------------------------------- /app/mapsExample/map_test2_grid.yaml: -------------------------------------------------------------------------------- 1 | image: map_test2_grid.pgm 2 | resolution: 0.050000 3 | origin: [-10.00000, -10.00000, 0.000000] 4 | negate: 0 5 | occupied_thresh: 0.65 6 | free_thresh: 0.196 7 | -------------------------------------------------------------------------------- /app/mapsExample/map_test2_yarpflags.ppm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_test2_yarpflags.ppm -------------------------------------------------------------------------------- /app/mapsExample/map_test_grid.pgm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_test_grid.pgm -------------------------------------------------------------------------------- /app/mapsExample/map_test_grid.yaml: -------------------------------------------------------------------------------- 1 | image: map_test_grid.pgm 2 | resolution: 0.050000 3 | origin: [-10.00000, -10.00000, 0.000000] 4 | negate: 0 5 | occupied_thresh: 0.65 6 | free_thresh: 0.196 7 | -------------------------------------------------------------------------------- /app/mapsExample/map_test_yarpflags.ppm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsExample/map_test_yarpflags.ppm -------------------------------------------------------------------------------- /app/mapsExample/maps_collection.ini: -------------------------------------------------------------------------------- 1 | mapfile: map_empty.map 2 | mapfile: map_test.map 3 | mapfile: map_test2.map 4 | mapfile: map_isaac.map 5 | -------------------------------------------------------------------------------- /app/mapsSquirico/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | file(GLOB maps ${CMAKE_CURRENT_SOURCE_DIR}/*.*) 8 | 9 | yarp_install(FILES ${maps} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/mapsSquirico) 10 | -------------------------------------------------------------------------------- /app/mapsSquirico/locations.ini: -------------------------------------------------------------------------------- 1 | Version: 2 | 1 3 | Locations: 4 | 5 | Areas: 6 | -------------------------------------------------------------------------------- /app/mapsSquirico/map_isaac.map: -------------------------------------------------------------------------------- 1 | #The YARP root map description file. 2 | #it points to yarp flag maps 3 | #it points to ROS occupancy grid (optional) 4 | 5 | MapName isaacMap 6 | YarpMapData map_isaac_yarpflags.png 7 | 8 | resolution 0.05 9 | origin (0 -30 -90) 10 | 11 | -------------------------------------------------------------------------------- /app/mapsSquirico/map_isaac_yarpflags.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/app/mapsSquirico/map_isaac_yarpflags.png -------------------------------------------------------------------------------- /app/mapsSquirico/maps_collection.ini: -------------------------------------------------------------------------------- 1 | mapfile: map_empty.map 2 | mapfile: map_test.map 3 | mapfile: map_test2.map 4 | mapfile: map_isaac.map 5 | -------------------------------------------------------------------------------- /app/multipleLaserTest/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(appname multipleLaserTest) 2 | 3 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 4 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 5 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 6 | 7 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 8 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 9 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 10 | -------------------------------------------------------------------------------- /app/multipleLaserTest/scripts/test1.xml: -------------------------------------------------------------------------------- 1 | 2 | multiple_laser_test1 3 | 4 | 5 | console 6 | 7 | 8 | 9 | yarpdev 10 | --device Rangefinder2DWrapper --subdevice fakeLaser --period 10 --name /fakeLaser1:o --test use_constant --const_distance 0.5 --SENSOR::resolution 0.5 --SKIP::min 0 --SKIP::max 45 11 | console 12 | 13 | 14 | 15 | yarpdev 16 | --device Rangefinder2DWrapper --subdevice fakeLaser --period 10 --name /fakeLaser2:o --test use_constant --const_distance 1.0 --SENSOR::resolution 0.5 --SKIP::min 90 --SKIP::max 135 17 | console 18 | 19 | 20 | 21 | yarplaserscannergui 22 | --sens_port /fakeLaser1:o --lidar_debug --local /lasergui1 23 | console 24 | 25 | 26 | 27 | yarplaserscannergui 28 | --sens_port /fakeLaser2:o --lidar_debug --local /lasergui2 29 | console 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /app/multipleLaserTest/scripts/test2.xml: -------------------------------------------------------------------------------- 1 | 2 | multiple_laser_test2 3 | 4 | 5 | console 6 | 7 | 8 | 9 | yarpdev 10 | --device Rangefinder2DWrapper --subdevice fakeLaser --period 10 --name /fakeLaser1:o --test use_constant --const_distance 0.5 --SENSOR::resolution 0.5 --SKIP::min 0 --SKIP::max 45 11 | console 12 | 13 | 14 | 15 | yarpdev 16 | --device transformServer --ROS::enable_ros_publisher 0 --ROS::enable_ros_subscriber 0 --USER_TF "( 0.0 0.0 0.0 0.0 0.0 0.0 /output_frame /frame1 )" 17 | console 18 | 19 | 20 | 21 | yarpdev 22 | --device Rangefinder2DWrapper --subdevice laserFromExternalPort --SENSOR::min_angle 0 --SENSOR::max_angle 360 --SENSOR::resolution 0.5 --SENSOR::input_ports_name "(/laserFromPort/las1:i)" --TRANSFORM_CLIENT::local /LaserFromExternalPort/tfClient --TRANSFORM_CLIENT::remote /transformServer --TRANSFORMS::src_frames "(/frame1)" --TRANSFORMS::dst_frame /output_frame --period 10 --name /outLaser:o --override 23 | console 24 | 25 | 26 | 27 | 28 | yarplaserscannergui 29 | --sens_port /fakeLaser1:o --lidar_debug --local /lasergui1 30 | console 31 | 32 | 33 | 34 | yarplaserscannergui 35 | --sens_port /outLaser:o --lidar_debug --local /lasergui3 36 | console 37 | 38 | 39 | 40 | /fakeLaser1:o 41 | /laserFromPort/las1:i 42 | udp 43 | 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /app/navigationGUI/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname navigationGUI) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | 17 | -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_base.ini: -------------------------------------------------------------------------------- 1 | [NAVIGATIONGUI_GENERAL] 2 | local /navigationGui 3 | remote_localization /localizationServer 4 | remote_map /mapServer 5 | remote_navigation /navigationServer 6 | localization_client localization2DClient 7 | map_client map2DClient 8 | navigation_client navigation2DClient 9 | thread_period 0.020 10 | draw_and_publish_period 0.033 11 | las_carrier tcp 12 | map_carrier tcp 13 | nav_carrier tcp 14 | loc_carrier tcp 15 | 16 | [LOCALIZATION] 17 | robot_frame_id mobile_base_body_link 18 | map_frame_id map 19 | 20 | //The remote_laser parameter is specific to your robot 21 | //[LASER] 22 | //remote_laser /laser:o 23 | 24 | [ROBOT_GEOMETRY] 25 | robot_radius 0.30 26 | laser_pos_x 0 27 | laser_pos_y 0 28 | laser_pos_theta 0 29 | 30 | [UPDATE_DATA] 31 | period_laser_data 0.3 32 | period_enalarged_obstacles 1.0 33 | period_estimated_poses 1.0 34 | period_map_locations 5.0 35 | period_global_map inf 36 | 37 | [DRAWING] 38 | enable_draw_all_locations 1 39 | enable_draw_enlarged_scans 1 40 | enable_draw_laser_scans 1 41 | enable_draw_infos 1 42 | enable_draw_global_path 1 43 | enable_draw_local_path 1 44 | enable_draw_particles_number 50 -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_base_nws-nwc.ini: -------------------------------------------------------------------------------- 1 | [NAVIGATIONGUI_GENERAL] 2 | local /navigationGui 3 | remote_localization /localization2D_nws_yarp 4 | remote_map /map2D_nws_yarp 5 | remote_navigation /navigation2D_nws_yarp 6 | localization_client localization2D_nwc_yarp 7 | map_client map2D_nwc_yarp 8 | navigation_client navigation2D_nwc_yarp 9 | thread_period 0.020 10 | draw_and_publish_period 0.033 11 | las_carrier tcp 12 | map_carrier tcp 13 | nav_carrier tcp 14 | loc_carrier tcp 15 | 16 | [LOCALIZATION] 17 | robot_frame_id mobile_base_body_link 18 | map_frame_id map 19 | 20 | //The remote_laser parameter is specific to your robot 21 | //[LASER] 22 | //remote_laser /laser:o 23 | 24 | [ROBOT_GEOMETRY] 25 | robot_radius 0.30 26 | laser_pos_x 0 27 | laser_pos_y 0 28 | laser_pos_theta 0 29 | 30 | [UPDATE_DATA] 31 | period_laser_data 0.3 32 | period_enalarged_obstacles 1.0 33 | period_estimated_poses 1.0 34 | period_map_locations 5.0 35 | period_global_map inf 36 | 37 | [DRAWING] 38 | enable_draw_all_locations 1 39 | enable_draw_enlarged_scans 1 40 | enable_draw_laser_scans 1 41 | enable_draw_infos 1 42 | enable_draw_global_path 1 43 | enable_draw_local_path 1 44 | enable_draw_particles_number 50 45 | -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_cer.ini: -------------------------------------------------------------------------------- 1 | [import navigationGUI navigationGUI_base.ini] 2 | 3 | [LASER] 4 | remote_laser /cer/laser:o 5 | laser_client Rangefinder2DClient 6 | -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_ikart.ini: -------------------------------------------------------------------------------- 1 | [import navigationGUI navigationGUI_base.ini] 2 | 3 | [LASER] 4 | remote_laser /ikart/laser:o 5 | laser_client Rangefinder2DClient -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_robot_2wheels.ini: -------------------------------------------------------------------------------- 1 | [import navigationGUI navigationGUI_base.ini] 2 | 3 | [LASER] 4 | remote_laser /robot_2wheels/laser:o 5 | laser_client Rangefinder2DClient -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_robot_2wheels_nws-nwc.ini: -------------------------------------------------------------------------------- 1 | [import navigationGUI navigationGUI_base_nws-nwc.ini] 2 | 3 | [LASER] 4 | remote_laser /robot_2wheels/laser:o 5 | laser_client Rangefinder2DClient -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_robot_2wheels_sim_cer_nws-nwc.ini: -------------------------------------------------------------------------------- 1 | [import navigationGUI navigationGUI_base_nws-nwc.ini] 2 | 3 | [LASER] 4 | remote_laser /SIM_CER_ROBOT/laser:o 5 | laser_client Rangefinder2DClient -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [import navigationGUI navigationGUI_base.ini] 2 | 3 | [LASER] 4 | remote_laser /SIM_CER_ROBOT/laser:o 5 | laser_client Rangefinder2DClient -------------------------------------------------------------------------------- /app/navigationGUI/conf/navigationGUI_sim_cerR1.ini: -------------------------------------------------------------------------------- 1 | [import navigationGUI navigationGUI_base.ini] 2 | 3 | [LASER] 4 | remote_laser /R1/laser:o 5 | laser_client Rangefinder2DClient -------------------------------------------------------------------------------- /app/navigationGUI/scripts/navigationGUI.xml: -------------------------------------------------------------------------------- 1 | 2 | navigationGui 3 | 4 | 5 | 6 | 7 | 8 | navigationGUI 9 | 10 | console 11 | 12 | 13 | 14 | yarpview 15 | --name /navView:i --out /mapClick:o 16 | console 17 | 18 | 19 | 20 | /navigationGui/map:o 21 | /navView:i 22 | udp 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/robotGoto/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname robotGoto) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | -------------------------------------------------------------------------------- /app/robotGoto/conf/robotGoto_cer.ini: -------------------------------------------------------------------------------- 1 | 2 | [LOCALIZATION] 3 | robot_frame_id mobile_base_body_link 4 | map_frame_id map 5 | 6 | [LASER] 7 | laser_port /cer/laser:o 8 | 9 | [ROBOT_GEOMETRY] 10 | robot_radius 0.30 11 | laser_pos_x 0 12 | laser_pos_y 0 13 | laser_pos_theta 0 14 | 15 | [ROBOT_TRAJECTORY] 16 | robot_is_holonomic 0 17 | max_beta_angle 5.0 18 | ang_speed_gain 0.3 19 | lin_speed_gain 0.1 20 | max_lin_speed 0.3 21 | max_ang_speed 15.0 22 | min_lin_speed 0.0 23 | min_ang_speed 0.0 24 | goal_tolerance_lin 0.05 25 | goal_tolerance_ang 0.6 26 | 27 | [RETREAT_OPTION] 28 | enable_retreat 0 29 | retreat_duration 300 30 | 31 | [OBSTACLES_EMERGENCY_STOP] 32 | enable_emergency_stop 1 33 | max_waiting_time 60.0 34 | enable_dynamic_max_distance 0 35 | max_detection_distance 1.2 36 | min_detection_distance 0.35 37 | 38 | [OBSTACLES_AVOIDANCE] 39 | enable_obstacles_avoidance 0 40 | frontal_blind_angle 25.0 41 | speed_reduction_factor 0.70 42 | 43 | [ROS] 44 | rosNodeName /robotGoto 45 | useGoalFromRosTopic true 46 | goalTopicName /move_base_simple/goal 47 | publishRosStuff true 48 | currentGoalTopicName /robotGoto/Goal 49 | localPlanTopicName /robotGoto/localplan 50 | globalPlanTopicName /robotGoto/globalplan 51 | 52 | 53 | -------------------------------------------------------------------------------- /app/robotGoto/conf/robotGoto_cerSim.ini: -------------------------------------------------------------------------------- 1 | 2 | [LOCALIZATION] 3 | robot_frame_id mobile_base_body_link 4 | map_frame_id map 5 | 6 | [LASER] 7 | laser_port /SIM_CER_ROBOT/laser 8 | 9 | [ROBOT_GEOMETRY] 10 | robot_radius 0.30 11 | laser_pos_x 0 12 | laser_pos_y 0 13 | laser_pos_theta 0 14 | 15 | [ROBOT_TRAJECTORY] 16 | robot_is_holonomic 0 17 | max_beta_angle 5.0 18 | ang_speed_gain 0.3 19 | lin_speed_gain 0.1 20 | max_lin_speed 0.3 21 | max_ang_speed 15.0 22 | min_lin_speed 0.0 23 | min_ang_speed 0.0 24 | goal_tolerance_lin 0.05 25 | goal_tolerance_ang 0.6 26 | 27 | [RETREAT_OPTION] 28 | enable_retreat 0 29 | retreat_duration 300 30 | 31 | [OBSTACLES_EMERGENCY_STOP] 32 | enable_obstacles_emergency_stop 1 33 | max_waiting_time 60.0 34 | enable_dynamic_max_distance 0 35 | max_detection_distance 0.7 36 | min_detection_distance 0.4 37 | 38 | [OBSTACLES_AVOIDANCE] 39 | enable_obstacles_avoidance 0 40 | frontal_blind_angle 25.0 41 | speed_reduction_factor 0.70 42 | 43 | [ROS] 44 | rosNodeName /robotGoto 45 | useGoalFromRosTopic true 46 | goalTopicName /move_base_simple/goal 47 | publishRosStuff true 48 | currentGoalTopicName /robotGoto/Goal 49 | localPlanTopicName /robotGoto/localplan 50 | globalPlanTopicName /robotGoto/globalplan 51 | 52 | 53 | -------------------------------------------------------------------------------- /app/robotGoto/conf/robotGoto_ikart.ini: -------------------------------------------------------------------------------- 1 | [LOCALIZATION] 2 | robot_frame_id mobile_base_body 3 | map_frame_id map 4 | 5 | [LASER] 6 | laser_port /ikart/laser:o 7 | 8 | [ROBOT_GEOMETRY] 9 | robot_radius 0.30 10 | laser_pos_x 0.245 11 | laser_pos_y 0 12 | laser_pos_theta -135 13 | 14 | [ROBOT_TRAJECTORY] 15 | robot_is_holonomic 1 16 | max_beta_angle 25.0 17 | ang_speed_gain 0.05 18 | lin_speed_gain 0.1 19 | max_lin_speed 0.3 20 | max_ang_speed 5.0 21 | min_lin_speed 0.0 22 | min_ang_speed 0.0 23 | goal_tolerance_lin 0.05 24 | goal_tolerance_ang 0.6 25 | 26 | [RETREAT_OPTION] 27 | enable_retreat 0 28 | retreat_duration 300 29 | 30 | [OBSTACLES_EMERGENCY_STOP] 31 | enable_obstacles_emergency_stop 0 32 | max_waiting_time 60.0 33 | enable_dynamic_max_distance 0 34 | max_detection_distance 1.5 35 | min_detection_distance 0.4 36 | 37 | [OBSTACLES_AVOIDANCE] 38 | enable_obstacles_avoidance 0 39 | frontal_blind_angle 25.0 40 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotGoto/scripts/robotGoto.xml: -------------------------------------------------------------------------------- 1 | 2 | robotGoto 3 | 4 | 5 | 6 | 7 | 8 | yarpdev 9 | --device navigation2DServer --subdevice robotGotoDev --context robotGoto --from robotGoto_ikart.ini 10 | console 11 | 12 | 13 | 14 | /robotGoto/control:o 15 | /baseControl/control:i 16 | udp 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/robotGoto/scripts/robotGoto_no_laser.xml: -------------------------------------------------------------------------------- 1 | 2 | robotGoto_no_laser 3 | 4 | 5 | 6 | 7 | 8 | yarpdev 9 | --device navigation2DServer --subdevice robotGotoDev --context robotGoto --from robotGoto_ikart.ini --no_stop_on_obstacles 10 | console 11 | 12 | 13 | 14 | /robotGoto/control:o 15 | /baseControl/control:i 16 | udp 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/robotGotoExamples/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname robotGotoExamples) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | 17 | -------------------------------------------------------------------------------- /app/robotGotoExamples/conf/odomLocalizer.ini: -------------------------------------------------------------------------------- 1 | [ODOMLOCALIZER_GENERAL] 2 | name /odomLocalizer 3 | 4 | [LOCALIZATION] 5 | use_localization_from_odometry_port 1 6 | use_localization_from_tf 0 7 | 8 | [MAP] 9 | connect_to_yarp_mapserver 1 10 | 11 | [ROS] 12 | initialpose_topic initialpose 13 | occupancygrid_topic occupancy_map 14 | 15 | [TF] 16 | robot_frame_id mobile_base_body_link 17 | map_frame_id map 18 | 19 | [ODOMETRY] 20 | odometry_broadcast_port /baseControl/odometry:o 21 | 22 | [INITIAL_POS] 23 | initial_map testMap 24 | initial_x 0.0 25 | initial_y 0.0 26 | initial_theta 0.0 27 | 28 | -------------------------------------------------------------------------------- /app/robotGotoExamples/conf/robotGoto_cer.ini: -------------------------------------------------------------------------------- 1 | 2 | [LOCALIZATION] 3 | robot_frame_id mobile_base_body_link 4 | map_frame_id map 5 | 6 | [LASER] 7 | laser_port /cer/laser:o 8 | 9 | [ROBOT_GEOMETRY] 10 | robot_radius 0.30 11 | laser_pos_x 0 12 | laser_pos_y 0 13 | laser_pos_theta 0 14 | 15 | [ROBOT_TRAJECTORY] 16 | robot_is_holonomic 0 17 | max_gamma_angle 5.0 18 | ang_speed_gain 0.3 19 | lin_speed_gain 0.1 20 | max_lin_speed 0.3 21 | max_ang_speed 15.0 22 | min_lin_speed 0.0 23 | min_ang_speed 0.0 24 | goal_tolerance_lin 0.05 25 | goal_tolerance_ang 0.6 26 | 27 | [RETREAT_OPTION] 28 | enable_retreat 0 29 | retreat_duration 300 30 | 31 | [OBSTACLES_EMERGENCY_STOP] 32 | enable_obstacles_emergency_stop 0 33 | max_waiting_time 60.0 34 | enable_dynamic_max_distance 0 35 | max_detection_distance 1.5 36 | min_detection_distance 0.4 37 | 38 | [OBSTACLES_AVOIDANCE] 39 | enable_obstacles_avoidance 0 40 | frontal_blind_angle 25.0 41 | speed_reduction_factor 0.70 42 | 43 | [ROS] 44 | rosNodeName /robotGoto 45 | useGoalFromRosTopic true 46 | goalTopicName /move_base_simple/goal 47 | publishRosStuff true 48 | currentGoalTopicName /robotGoto/Goal 49 | localPlanTopicName /robotGoto/localplan 50 | globalPlanTopicName /robotGoto/globalplan 51 | 52 | 53 | -------------------------------------------------------------------------------- /app/robotGotoExamples/conf/robotGoto_ikart.ini: -------------------------------------------------------------------------------- 1 | [LOCALIZATION] 2 | robot_frame_id mobile_base_body 3 | map_frame_id map 4 | 5 | [LASER] 6 | laser_port /ikart/laser:o 7 | 8 | [ROBOT_GEOMETRY] 9 | robot_radius 0.30 10 | laser_pos_x 0.245 11 | laser_pos_y 0 12 | laser_pos_theta -135 13 | 14 | [ROBOT_TRAJECTORY] 15 | robot_is_holonomic 1 16 | max_gamma_angle 25.0 17 | ang_speed_gain 0.1 18 | lin_speed_gain 0.1 19 | max_lin_speed 0.3 20 | max_ang_speed 5.0 21 | min_lin_speed 0.0 22 | min_ang_speed 0.0 23 | goal_tolerance_lin 0.05 24 | goal_tolerance_ang 0.6 25 | 26 | [RETREAT_OPTION] 27 | enable_retreat 0 28 | retreat_duration 300 29 | 30 | [OBSTACLES_EMERGENCY_STOP] 31 | enable_obstacles_emergency_stop 0 32 | max_waiting_time 60.0 33 | enable_dynamic_max_distance 0 34 | max_detection_distance 1.5 35 | min_detection_distance 0.4 36 | 37 | [OBSTACLES_AVOIDANCE] 38 | enable_obstacles_avoidance 0 39 | frontal_blind_angle 25.0 40 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotGotoExamples/conf/robotGoto_robot_2wheels.ini: -------------------------------------------------------------------------------- 1 | [LOCALIZATION] 2 | robot_frame_id mobile_base_body 3 | map_frame_id map 4 | 5 | [LASER] 6 | laser_port /robot_2wheels/laser:o 7 | 8 | [ROBOT_GEOMETRY] 9 | robot_radius 0.30 10 | laser_pos_x 0.245 11 | laser_pos_y 0 12 | laser_pos_theta -135 13 | 14 | [ROBOT_TRAJECTORY] 15 | robot_is_holonomic 0 16 | max_gamma_angle 25.0 17 | ang_speed_gain 0.1 18 | lin_speed_gain 0.1 19 | max_lin_speed 0.3 20 | max_ang_speed 5.0 21 | min_lin_speed 0.0 22 | min_ang_speed 0.0 23 | goal_tolerance_lin 0.05 24 | goal_tolerance_ang 0.6 25 | 26 | [RETREAT_OPTION] 27 | enable_retreat 0 28 | retreat_duration 300 29 | 30 | [OBSTACLES_EMERGENCY_STOP] 31 | enable_obstacles_emergency_stop 0 32 | max_waiting_time 60.0 33 | enable_dynamic_max_distance 0 34 | max_detection_distance 1.5 35 | min_detection_distance 0.4 36 | 37 | [OBSTACLES_AVOIDANCE] 38 | enable_obstacles_avoidance 0 39 | frontal_blind_angle 25.0 40 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotGotoExamples/conf/robotGoto_robot_3wheels.ini: -------------------------------------------------------------------------------- 1 | [LOCALIZATION] 2 | robot_frame_id mobile_base_body 3 | map_frame_id map 4 | 5 | [LASER] 6 | laser_port /robot_3wheels/laser:o 7 | 8 | [ROBOT_GEOMETRY] 9 | robot_radius 0.30 10 | laser_pos_x 0.245 11 | laser_pos_y 0 12 | laser_pos_theta -135 13 | 14 | [ROBOT_TRAJECTORY] 15 | robot_is_holonomic 1 16 | max_gamma_angle 25.0 17 | ang_speed_gain 0.1 18 | lin_speed_gain 0.1 19 | max_lin_speed 0.3 20 | max_ang_speed 5.0 21 | min_lin_speed 0.0 22 | min_ang_speed 0.0 23 | goal_tolerance_lin 0.05 24 | goal_tolerance_ang 0.6 25 | 26 | [RETREAT_OPTION] 27 | enable_retreat 0 28 | retreat_duration 300 29 | 30 | [OBSTACLES_EMERGENCY_STOP] 31 | enable_obstacles_emergency_stop 0 32 | max_waiting_time 60.0 33 | enable_dynamic_max_distance 0 34 | max_detection_distance 1.5 35 | min_detection_distance 0.4 36 | 37 | [OBSTACLES_AVOIDANCE] 38 | enable_obstacles_avoidance 0 39 | frontal_blind_angle 25.0 40 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotPathPlanner/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname robotPathPlanner) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | 17 | -------------------------------------------------------------------------------- /app/robotPathPlanner/conf/robotPathPlanner_cer.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [LOCALIZATION] 26 | robot_frame_id mobile_base_body_link 27 | map_frame_id map 28 | 29 | [LASER] 30 | laser_port /cer/laser:o 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0 35 | laser_pos_y 0 36 | laser_pos_theta 0 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /app/robotPathPlanner/conf/robotPathPlanner_cerSim.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [LOCALIZATION] 26 | robot_frame_id mobile_base_body_link 27 | map_frame_id map 28 | 29 | [LASER] 30 | laser_port /SIM_CER_ROBOT/laser 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0 35 | laser_pos_y 0 36 | laser_pos_theta 0 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /app/robotPathPlanner/conf/robotPathPlanner_ikart.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.25 11 | goal_max_ang_speed 4.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.0 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.25 19 | waypoint_max_ang_speed 4.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.0 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [LOCALIZATION] 26 | robot_frame_id mobile_base_body 27 | map_frame_id map 28 | 29 | [LASER] 30 | laser_port /ikart/laser:o 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0.245 35 | laser_pos_y 0 36 | laser_pos_theta -135 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /app/robotPathPlanner/scripts/robotPathPlanner.xml: -------------------------------------------------------------------------------- 1 | 2 | robotPathPlanner 3 | 4 | 5 | 6 | 7 | 8 | yarpdev 9 | --device navigation2DServer --subdevice robotPathPlannerDev --context robotPathPlanner --from robotPathPlanner_ikart.ini 10 | console 11 | 12 | 13 | 14 | yarpview 15 | --name /plannerView:i --out /mapClick:o 16 | console 17 | 18 | 19 | 20 | /robotGoto/control:o 21 | /baseControl/control:i 22 | udp 23 | 24 | 25 | 26 | /robotPathPlanner/map:o 27 | /plannerView:i 28 | udp 29 | 30 | 31 | 32 | /robotPathPlanner/commands:o 33 | /robotGoto/rpc:i 34 | tcp 35 | 36 | 37 | 38 | /robotGoto/status:o 39 | /robotPathPlanner/navigationStatus:i 40 | tcp 41 | 42 | 43 | 44 | /robotGoto/speak:o 45 | /iSpeak 46 | tcp 47 | 48 | 49 | 50 | /mapClick:o 51 | /robotPathPlanner/yarpviewTarget:i 52 | tcp 53 | 54 | 55 | 56 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname robotPathPlannerExamples) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | file(GLOB robotInterface ${CMAKE_CURRENT_SOURCE_DIR}/conf/robotInterface/*.xml) 13 | 14 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 15 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 16 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 17 | yarp_install(FILES ${robotInterface} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}/robotInterface) 18 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/amclLocalizer.ini: -------------------------------------------------------------------------------- 1 | [AMCLLOCALIZER_GENERAL] 2 | name /localizationServer 3 | enable_ros 0 4 | 5 | [LOCALIZATION] 6 | use_localization_from_odometry_port 1 7 | use_localization_from_tf 0 8 | 9 | [MAP] 10 | connect_to_yarp_mapserver 1 11 | 12 | [ROS] 13 | initialpose_topic initialpose 14 | occupancygrid_topic occupancy_map 15 | 16 | [TF] 17 | robot_frame_id mobile_base_body_link 18 | map_frame_id map 19 | 20 | [ODOMETRY] 21 | odometry_broadcast_port /baseControl/odometry:o 22 | 23 | [INITIAL_POS] 24 | initial_map testMap 25 | initial_x 0.0 26 | initial_y 0.0 27 | initial_theta 0.0 28 | 29 | [LASER] 30 | laser_broadcast_port /robot_2wheels/laser:o 31 | 32 | [AMCL] 33 | min_particles 500 34 | max_particles 2000 35 | kld_err 0.05 36 | kld_z 0.95 37 | 38 | odom_model_type diff 39 | odom_alpha1 2.0 40 | odom_alpha2 2.0 41 | odom_alpha3 0.2 42 | odom_alpha4 0.2 43 | 44 | laser_max_beams 50 45 | laser_max_range 5.0 46 | laser_min_range 0.4 47 | laser_z_hit 0.95 48 | laser_z_short 0.01 49 | laser_z_max 0.05 50 | laser_z_rand 0.2 51 | laser_sigma_hit 0.2 52 | laser_lambda_short 0.1 53 | laser_model_type likelihood_field 54 | laser_likelihood_max_dist 2.0 55 | 56 | update_min_d 0.1 57 | update_min_a 0.1 58 | resample_interval 1 59 | recovery_alpha_slow 0.0 60 | recovery_alpha_fast 0.0 61 | 62 | 63 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/gazeboLocalizer.ini: -------------------------------------------------------------------------------- 1 | [GAZEBOLOCALIZER_GENERAL] 2 | name /localizationServer 3 | enable_ros 0 4 | local_name /gazeboLocalizer 5 | robot_name SIM_CER_ROBOT 6 | world_interface_port /world_input_port 7 | 8 | 9 | [LOCALIZATION] 10 | use_localization_from_odometry_port 1 11 | use_localization_from_tf 0 12 | 13 | [MAP] 14 | connect_to_yarp_mapserver 1 15 | 16 | [ROS] 17 | initialpose_topic initialpose 18 | occupancygrid_topic occupancy_map 19 | 20 | [TF] 21 | robot_frame_id mobile_base_body_link 22 | map_frame_id map 23 | 24 | [ODOMETRY] 25 | odometry_broadcast_port /baseControl/odometry:o 26 | 27 | [INITIAL_POS] 28 | initial_map testMap 29 | map_transform_x 0.0 30 | map_transform_y 0.0 31 | map_transform_t 0.0 32 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/localization2Dros2.ini: -------------------------------------------------------------------------------- 1 | config robotInterface/localization2Dros2.xml 2 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/map2D_ros2.ini: -------------------------------------------------------------------------------- 1 | config robotInterface/map2d_ros2.xml 2 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/odomLocalizer.ini: -------------------------------------------------------------------------------- 1 | [ODOMLOCALIZER_GENERAL] 2 | name /odomLocalizer 3 | 4 | [LOCALIZATION] 5 | use_localization_from_odometry_port 1 6 | use_localization_from_tf 0 7 | 8 | [MAP] 9 | connect_to_yarp_mapserver 1 10 | 11 | [ROS] 12 | initialpose_topic initialpose 13 | occupancygrid_topic occupancy_map 14 | 15 | [TF] 16 | robot_frame_id mobile_base_body_link 17 | map_frame_id map 18 | 19 | [ODOMETRY] 20 | odometry_broadcast_port /baseControl/odometry:o 21 | 22 | [INITIAL_POS] 23 | initial_map testMap 24 | initial_x 0.0 25 | initial_y 0.0 26 | initial_theta 0.0 27 | 28 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/pozyxLocalizer.ini: -------------------------------------------------------------------------------- 1 | [POZYXLOCALIZER_GENERAL] 2 | name /localizationServer 3 | 4 | [LOCALIZATION] 5 | use_localization_from_odometry_port 1 6 | use_localization_from_tf 0 7 | 8 | [MAP] 9 | connect_to_yarp_mapserver 1 10 | 11 | [ROS] 12 | initialpose_topic initialpose 13 | occupancygrid_topic occupancy_map 14 | 15 | [TF] 16 | robot_frame_id mobile_base_body_link 17 | map_frame_id map 18 | 19 | [ODOMETRY] 20 | odometry_broadcast_port /baseControl/odometry:o 21 | 22 | [INITIAL_POS] 23 | initial_map testMap 24 | initial_x 0.0 25 | initial_y 0.0 26 | initial_theta 0.0 27 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotGoto_cer.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body_link 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /cer/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0 14 | laser_pos_y 0 15 | laser_pos_theta 0 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 0 19 | max_gamma_angle 5.0 20 | ang_speed_gain 0.3 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 15.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 44 | 45 | [ROS] 46 | rosNodeName /robotGoto 47 | useGoalFromRosTopic true 48 | goalTopicName /move_base_simple/goal 49 | publishRosStuff true 50 | currentGoalTopicName /robotGoto/Goal 51 | localPlanTopicName /robotGoto/localplan 52 | globalPlanTopicName /robotGoto/globalplan 53 | 54 | 55 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotGoto_ikart.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /ikart/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0.245 14 | laser_pos_y 0 15 | laser_pos_theta -135 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 1 19 | max_gamma_angle 25.0 20 | ang_speed_gain 0.1 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 5.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotGoto_robot_2wheels.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /robot_2wheels/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0.245 14 | laser_pos_y 0 15 | laser_pos_theta -135 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 0 19 | max_gamma_angle 25.0 20 | ang_speed_gain 0.1 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 5.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotGoto_robot_2wheels_with_recovery.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /robot_2wheels/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0.245 14 | laser_pos_y 0 15 | laser_pos_theta -135 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 0 19 | max_gamma_angle 25.0 20 | ang_speed_gain 0.1 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 5.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 1 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotGoto_robot_3wheels.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /robot_3wheels/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0.245 14 | laser_pos_y 0 15 | laser_pos_theta -135 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 1 19 | max_gamma_angle 25.0 20 | ang_speed_gain 0.1 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 5.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotGoto_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [ROBOTGOTO_GENERAL] 2 | name /robotGoto 3 | 4 | [LOCALIZATION] 5 | robot_frame_id mobile_base_body_link 6 | map_frame_id map 7 | 8 | [LASER] 9 | laser_port /SIM_CER_ROBOT/laser:o 10 | 11 | [ROBOT_GEOMETRY] 12 | robot_radius 0.30 13 | laser_pos_x 0 14 | laser_pos_y 0 15 | laser_pos_theta 0 16 | 17 | [ROBOT_TRAJECTORY] 18 | robot_is_holonomic 0 19 | max_gamma_angle 5.0 20 | ang_speed_gain 0.3 21 | lin_speed_gain 0.1 22 | max_lin_speed 0.3 23 | max_ang_speed 15.0 24 | min_lin_speed 0.0 25 | min_ang_speed 0.0 26 | goal_tolerance_lin 0.05 27 | goal_tolerance_ang 0.6 28 | 29 | [RETREAT_OPTION] 30 | enable_retreat 0 31 | retreat_duration 300 32 | 33 | [OBSTACLES_EMERGENCY_STOP] 34 | enable_obstacles_emergency_stop 0 35 | max_waiting_time 60.0 36 | enable_dynamic_max_distance 0 37 | max_detection_distance 1.5 38 | min_detection_distance 0.4 39 | 40 | [OBSTACLES_AVOIDANCE] 41 | enable_obstacles_avoidance 0 42 | frontal_blind_angle 25.0 43 | speed_reduction_factor 0.70 44 | 45 | [ROS] 46 | rosNodeName /robotGoto 47 | useGoalFromRosTopic true 48 | goalTopicName /move_base_simple/goal 49 | publishRosStuff true 50 | currentGoalTopicName /robotGoto/Goal 51 | localPlanTopicName /robotGoto/localplan 52 | globalPlanTopicName /robotGoto/globalplan 53 | 54 | 55 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotPathPlanner_cer.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [LOCALIZATION] 26 | robot_frame_id mobile_base_body_link 27 | map_frame_id map 28 | 29 | [LASER] 30 | laser_port /cer/laser:o 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0 35 | laser_pos_y 0 36 | laser_pos_theta 0 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotPathPlanner_ikart.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.0 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.0 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [LOCALIZATION] 26 | robot_frame_id mobile_base_body 27 | map_frame_id map 28 | 29 | [LASER] 30 | laser_port /ikart/laser:o 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0.245 35 | laser_pos_y 0 36 | laser_pos_theta -135 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotPathPlanner_robot_2wheels.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.0 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.0 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [INTERNAL_NAVIGATOR] 26 | plugin robotGotoDev 27 | context robotPathPlannerExamples 28 | from robotGoto_robot_2wheels.ini 29 | 30 | [LOCALIZATION] 31 | robot_frame_id mobile_base_body_link 32 | map_frame_id map 33 | localizationServer_name /localization2D_nws_yarp 34 | mapServer_name /map2D_nws_yarp 35 | 36 | [LASER] 37 | laser_port /robot_2wheels/laser:o 38 | 39 | [ROBOT_GEOMETRY] 40 | robot_radius 0.30 41 | laser_pos_x 0.245 42 | laser_pos_y 0 43 | laser_pos_theta -135 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotPathPlanner_robot_2wheels_with_recovery.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 1 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.0 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.0 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [INTERNAL_NAVIGATOR] 26 | plugin robotGotoDev 27 | context robotPathPlannerExamples 28 | from robotGoto_robot_2wheels.ini 29 | 30 | [LOCALIZATION] 31 | robot_frame_id mobile_base_body 32 | map_frame_id map 33 | 34 | [LASER] 35 | laser_port /robot_2wheels/laser:o 36 | 37 | [ROBOT_GEOMETRY] 38 | robot_radius 0.30 39 | laser_pos_x 0.245 40 | laser_pos_y 0 41 | laser_pos_theta -135 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotPathPlanner_robot_3wheels.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.0 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.0 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [INTERNAL_NAVIGATOR] 26 | plugin robotGotoDev 27 | context robotPathPlannerExamples 28 | from robotGoto_robot_3wheels.ini 29 | 30 | [LOCALIZATION] 31 | robot_frame_id mobile_base_body 32 | map_frame_id map 33 | 34 | [LASER] 35 | laser_port /robot_3wheels/laser:o 36 | 37 | [ROBOT_GEOMETRY] 38 | robot_radius 0.30 39 | laser_pos_x 0.245 40 | laser_pos_y 0 41 | laser_pos_theta -135 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /app/robotPathPlannerExamples/conf/robotPathPlanner_sim_cer.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [INTERNAL_NAVIGATOR] 26 | plugin robotGotoDev 27 | context robotPathPlannerExamples 28 | from robotGoto_sim_cer.ini 29 | 30 | [LOCALIZATION] 31 | robot_frame_id mobile_base_body_link 32 | map_frame_id map 33 | localizationServer_name /localization2D_nws_yarp 34 | mapServer_name /map2D_nws_yarp 35 | 36 | [LASER] 37 | laser_port /SIM_CER_ROBOT/laser:o 38 | 39 | [ROBOT_GEOMETRY] 40 | robot_radius 0.30 41 | laser_pos_x 0.245 42 | laser_pos_y 0 43 | laser_pos_theta -135 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /app/ros2Examples/amcl/README.md: -------------------------------------------------------------------------------- 1 | the working example is amcl_sim.launch.py 2 | amcl_sim_launch2.py is a try to put configuration parameters into a separate file (amcl_sim_params.py) 3 | 4 | -------------------------------------------------------------------------------- /app/ros2Examples/amcl/amcl_sim.launch2.py: -------------------------------------------------------------------------------- 1 | import os 2 | 3 | import launch.actions 4 | import launch_ros.actions 5 | from ament_index_python.packages import get_package_share_directory 6 | from launch import LaunchDescription 7 | from launch_ros.actions import Node 8 | 9 | def generate_launch_description(): 10 | nav2_yaml = os.path.join(os.getcwd(), 'amcl_sim_params.yaml') 11 | par2 = [{'use_sim_time': True}, 12 | {'autostart': True}, 13 | {'node_names': ['amcl']}] 14 | ld = LaunchDescription([ 15 | Node( 16 | package='nav2_amcl', 17 | executable='amcl', 18 | name='amcl', 19 | output='screen', 20 | on_exit=launch.actions.Shutdown(), 21 | parameters=nav2_yaml 22 | ), 23 | Node( 24 | package='nav2_lifecycle_manager', 25 | executable='lifecycle_manager', 26 | name='lifecycle_manager_localization', 27 | output='screen', 28 | parameters= par2 29 | ) 30 | ]) 31 | return ld 32 | 33 | 34 | if __name__ == '__main__': 35 | generate_launch_description() 36 | -------------------------------------------------------------------------------- /app/ros2Examples/amcl/amcl_sim_params.yml: -------------------------------------------------------------------------------- 1 | amcl: 2 | ros__parameters: 3 | use_sim_time: true 4 | alpha1: 0.2 5 | alpha2: 0.2 6 | alpha3: 0.2 7 | alpha4: 0.2 8 | alpha5: 0.2 9 | base_frame_id: "mobile_base_body_link" 10 | beam_skip_distance: 0.5 11 | beam_skip_error_threshold: 0.9 12 | beam_skip_threshold: 0.3 13 | do_beamskip: false 14 | global_frame_id: "map" 15 | lambda_short: 0.1 16 | laser_likelihood_max_dist: 2.0 17 | laser_max_range: 100.0 18 | laser_min_range: -1.0 19 | laser_model_type: "likelihood_field" 20 | max_beams: 60 21 | max_particles: 8000 22 | min_particles: 200 23 | odom_frame_id: "odom" 24 | pf_err: 0.05 25 | pf_z: 0.99 26 | recovery_alpha_fast: 0.0 27 | recovery_alpha_slow: 0.0 28 | resample_interval: 1 29 | robot_model_type: "nav2_amcl::DifferentialMotionModel" 30 | save_pose_rate: 0.5 31 | set_initial_pose: False 32 | initial_pose: {x: -1.98938310, y: -0.49025386, theta: 0.0} 33 | sigma_hit: 0.2 34 | tf_broadcast: true 35 | transform_tolerance: 1.0 36 | update_min_a: 0.2 37 | update_min_d: 0.25 38 | z_hit: 0.5 39 | z_max: 0.05 40 | z_rand: 0.5 41 | z_short: 0.05 42 | map_topic: "map" 43 | scan_topic: "double_lidar" 44 | 45 | amcl_rclcpp_node: 46 | ros__parameters: 47 | use_sim_time: true 48 | 49 | 50 | -------------------------------------------------------------------------------- /app/rosExamples/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname rosExamples) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | 17 | -------------------------------------------------------------------------------- /app/rosExamples/conf/fakeMobileBaseTest.ini: -------------------------------------------------------------------------------- 1 | /// Initialization file for cer base controller 2 | robot cer 3 | part mobile_base 4 | 5 | [include "joystick_configs.ini"] 6 | 7 | [BASECTRL_GENERAL] 8 | joypad1_configuration 9 | joypad2_configuration 10 | robot_type cer 11 | control_mode velocity_no_pid 12 | linear_angular_ratio 0.7 13 | ratio_limiter_enabled 1 14 | input_filter_enabled 0 15 | max_linear_vel 0.30 //m/s 16 | max_angular_vel 30.0 //deg/s 17 | max_linear_acc 0.30 //m/s2 18 | max_angular_acc 80.0 //deg/s2 19 | use_ROS true 20 | 21 | [ODOMETRY_ERROR] 22 | x_gain 0.9 23 | y_gain 0.9 24 | t_gain 0.9 25 | 26 | [MOTORS] 27 | max_motor_pwm 10000 //pwm_units 28 | max_motor_vel 100 //deg/s 29 | motors_filter_enabled 10 30 | 31 | [JOYSTICK] 32 | linear_vel_at_full_control 0.30 //m 33 | angular_vel_at_full_control 30.0 //deg/s 34 | 35 | [ROS_GENERAL] 36 | node_name /baseControl 37 | 38 | [ROS_ODOMETRY] 39 | topic_name /odometry 40 | odom_frame odom 41 | base_frame mobile_base_body_link 42 | 43 | [ROS_FOOTPRINT] 44 | topic_name /footprint 45 | footprint_frame mobile_base_body_link 46 | footprint_diameter 0.510 47 | 48 | [ROS_INPUT] 49 | topic_name /cmd_vel 50 | 51 | #[ROS_OUTPUT] 52 | #topic_name /base_vel 53 | -------------------------------------------------------------------------------- /app/rosExamples/conf/localizationServer_ros.ini: -------------------------------------------------------------------------------- 1 | [ROSLOCALIZER_GENERAL] 2 | name /rosLocalizer 3 | enable_ros 1 4 | 5 | [LOCALIZATION] 6 | use_localization_from_odometry_port 0 7 | use_localization_from_tf 1 8 | 9 | [MAP] 10 | connect_to_yarp_mapserver 1 11 | 12 | [ROS] 13 | initialpose_topic /initialpose 14 | occupancygrid_topic /occupancy_map 15 | 16 | [TF] 17 | robot_frame_id mobile_base_body_link 18 | map_frame_id map 19 | 20 | [ODOMETRY] 21 | odometry_broadcast_port /baseControl/odometry:o 22 | 23 | [INITIAL_POS] 24 | initial_map ros_map 25 | initial_x 0.0 26 | initial_y 0.0 27 | initial_theta 0.0 28 | 29 | -------------------------------------------------------------------------------- /app/rosExamples/conf/localizationServer_yarp.ini: -------------------------------------------------------------------------------- 1 | [ROSLOCALIZER_GENERAL] 2 | name /rosLocalizer 3 | enable_ros 1 4 | 5 | [LOCALIZATION] 6 | use_localization_from_odometry_port 0 7 | use_localization_from_tf 1 8 | 9 | [MAP] 10 | connect_to_yarp_mapserver 1 11 | 12 | [ROS] 13 | initialpose_topic /initialpose 14 | occupancygrid_topic /occupancy_map 15 | 16 | [TF] 17 | robot_frame_id mobile_base_body_link 18 | map_frame_id map 19 | 20 | [ODOMETRY] 21 | odometry_broadcast_port /baseControl/odometry:o 22 | 23 | [INITIAL_POS] 24 | initial_map testMap 25 | initial_x 0.0 26 | initial_y 0.0 27 | initial_theta 0.0 28 | 29 | -------------------------------------------------------------------------------- /app/rosExamples/conf/robotGoto_cer.ini: -------------------------------------------------------------------------------- 1 | [LOCALIZATION] 2 | robot_frame_id mobile_base_body_link 3 | map_frame_id map 4 | 5 | [LASER] 6 | laser_port /cer/laser:o 7 | 8 | [ROBOT_GEOMETRY] 9 | robot_radius 0.30 10 | laser_pos_x 0 11 | laser_pos_y 0 12 | laser_pos_theta 0 13 | 14 | [ROBOT_TRAJECTORY] 15 | robot_is_holonomic 0 16 | max_gamma_angle 5.0 17 | ang_speed_gain 0.3 18 | lin_speed_gain 0.1 19 | max_lin_speed 0.3 20 | max_ang_speed 15.0 21 | min_lin_speed 0.0 22 | min_ang_speed 0.0 23 | goal_tolerance_lin 0.05 24 | goal_tolerance_ang 0.6 25 | 26 | [RETREAT_OPTION] 27 | enable_retreat 0 28 | retreat_duration 300 29 | 30 | [OBSTACLES_EMERGENCY_STOP] 31 | enable_obstacles_emergency_stop 0 32 | max_waiting_time 60.0 33 | enable_dynamic_max_distance 0 34 | max_detection_distance 1.5 35 | min_detection_distance 0.4 36 | 37 | [OBSTACLES_AVOIDANCE] 38 | enable_obstacles_avoidance 0 39 | frontal_blind_angle 25.0 40 | speed_reduction_factor 0.70 41 | 42 | [ROS] 43 | rosNodeName /robotGoto 44 | useGoalFromRosTopic true 45 | goalTopicName /move_base_simple/goal 46 | publishRosStuff true 47 | currentGoalTopicName /robotGoto/Goal 48 | localPlanTopicName /robotGoto/localplan 49 | globalPlanTopicName /robotGoto/globalplan 50 | 51 | 52 | -------------------------------------------------------------------------------- /app/rosExamples/conf/robotGoto_ikart.ini: -------------------------------------------------------------------------------- 1 | [LOCALIZATION] 2 | robot_frame_id mobile_base_body 3 | map_frame_id map 4 | 5 | [LASER] 6 | laser_port /ikart/laser:o 7 | 8 | [ROBOT_GEOMETRY] 9 | robot_radius 0.30 10 | laser_pos_x 0.245 11 | laser_pos_y 0 12 | laser_pos_theta -135 13 | 14 | [ROBOT_TRAJECTORY] 15 | robot_is_holonomic 1 16 | max_gamma_angle 25.0 17 | ang_speed_gain 0.1 18 | lin_speed_gain 0.1 19 | max_lin_speed 0.3 20 | max_ang_speed 5.0 21 | min_lin_speed 0.0 22 | min_ang_speed 0.0 23 | goal_tolerance_lin 0.05 24 | goal_tolerance_ang 0.6 25 | 26 | [RETREAT_OPTION] 27 | enable_retreat 0 28 | retreat_duration 300 29 | 30 | [OBSTACLES_EMERGENCY_STOP] 31 | enable_obstacles_emergency_stop 0 32 | max_waiting_time 60.0 33 | enable_dynamic_max_distance 0 34 | max_detection_distance 1.5 35 | min_detection_distance 0.4 36 | 37 | [OBSTACLES_AVOIDANCE] 38 | enable_obstacles_avoidance 0 39 | frontal_blind_angle 25.0 40 | speed_reduction_factor 0.70 -------------------------------------------------------------------------------- /app/rosExamples/conf/robotPathPlanner_cer.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.1 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.1 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [LOCALIZATION] 26 | robot_frame_id mobile_base_body_link 27 | map_frame_id map 28 | 29 | [LASER] 30 | laser_port /cer/laser:o 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0 35 | laser_pos_y 0 36 | laser_pos_theta 0 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /app/rosExamples/conf/robotPathPlanner_ikart.ini: -------------------------------------------------------------------------------- 1 | [PATHPLANNER_GENERAL] 2 | publish_map_image_Hz 15 3 | 4 | [NAVIGATION] 5 | min_waypoint_distance 0 6 | use_optimized_path 1 7 | enable_try_recovery 0 8 | goal_tolerance_lin 0.05 9 | goal_tolerance_ang 0.6 10 | goal_max_lin_speed 0.45 11 | goal_max_ang_speed 5.0 12 | goal_min_lin_speed 0.1 13 | goal_min_ang_speed 0.0 14 | goal_ang_speed_gain 0.3 15 | goal_lin_speed_gain 0.1 16 | waypoint_tolerance_lin 0.1 17 | waypoint_tolerance_ang 5 18 | waypoint_max_lin_speed 0.45 19 | waypoint_max_ang_speed 5.0 20 | waypoint_min_lin_speed 0.1 21 | waypoint_min_ang_speed 0.0 22 | waypoint_ang_speed_gain 0.3 23 | waypoint_lin_speed_gain 0.1 24 | 25 | [LOCALIZATION] 26 | robot_frame_id mobile_base_body 27 | map_frame_id map 28 | 29 | [LASER] 30 | laser_port /ikart/laser:o 31 | 32 | [ROBOT_GEOMETRY] 33 | robot_radius 0.30 34 | laser_pos_x 0.245 35 | laser_pos_y 0 36 | laser_pos_theta -135 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /app/rosExamples/conf/robotinterface/rangeFinder2D.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | "" 7 | 8 | 9 | ftc_storage 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /app/rosExamples/launch/ros_navigation.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /app/rosExamples/ros_config/navigation/costmap_common_params.yaml: -------------------------------------------------------------------------------- 1 | max_obstacle_height: 0.60 2 | robot_radius: 0.20 3 | 4 | map_type: voxel 5 | 6 | obstacle_layer: 7 | enabled: true 8 | max_obstacle_height: 0.6 9 | origin_z: 0.0 10 | z_resolution: 0.2 11 | z_voxels: 2 12 | unknown_threshold: 15 13 | mark_threshold: 0 14 | combination_method: 1 15 | track_unknown_space: true #true needed for disabling global path planning through unknown space 16 | obstacle_range: 2.5 17 | raytrace_range: 3.0 18 | origin_z: 0.0 19 | z_resolution: 0.2 20 | z_voxels: 2 21 | publish_voxel_map: false 22 | observation_sources: scan 23 | scan: 24 | data_type: LaserScan 25 | topic: /laser 26 | marking: true 27 | clearing: true 28 | min_obstacle_height: 0.25 29 | max_obstacle_height: 0.35 30 | 31 | inflation_layer: 32 | enabled: true 33 | cost_scaling_factor: 9.0 # exponential rate at which the obstacle cost drops off (default: 10) 34 | inflation_radius: 0.5 # max. distance from an obstacle at which costs are incurred for planning paths. 35 | 36 | static_layer: 37 | enabled: true 38 | 39 | -------------------------------------------------------------------------------- /app/rosExamples/ros_config/navigation/global_costmap_params.yaml: -------------------------------------------------------------------------------- 1 | global_costmap: 2 | global_frame: /map 3 | robot_base_frame: /base_link 4 | update_frequency: 1.0 5 | publish_frequency: 0.5 6 | static_map: true 7 | transform_tolerance: 0.5 8 | plugins: 9 | - {name: static_layer, type: "costmap_2d::StaticLayer"} 10 | - {name: obstacle_layer, type: "costmap_2d::VoxelLayer"} 11 | - {name: inflation_layer, type: "costmap_2d::InflationLayer"} 12 | -------------------------------------------------------------------------------- /app/rosExamples/ros_config/navigation/local_costmap_params.yaml: -------------------------------------------------------------------------------- 1 | local_costmap: 2 | global_frame: odom 3 | robot_base_frame: /base_link 4 | update_frequency: 5.0 5 | publish_frequency: 2.0 6 | static_map: false 7 | rolling_window: true 8 | width: 4.0 9 | height: 4.0 10 | resolution: 0.05 11 | transform_tolerance: 0.5 12 | plugins: 13 | - {name: obstacle_layer, type: "costmap_2d::VoxelLayer"} 14 | - {name: inflation_layer, type: "costmap_2d::InflationLayer"} 15 | 16 | 17 | -------------------------------------------------------------------------------- /app/rosExamples/ros_config/navigation/navfn_global_planner_params.yaml: -------------------------------------------------------------------------------- 1 | 2 | NavfnROS: 3 | visualize_potential: false #Publish potential for rviz as pointcloud2, not really helpful, default false 4 | allow_unknown: false #Specifies whether or not to allow navfn to create plans that traverse unknown space, default true 5 | #Needs to have track_unknown_space: true in the obstacle / voxel layer (in costmap_commons_param) to work 6 | planner_window_x: 0.0 #Specifies the x size of an optional window to restrict the planner to, default 0.0 7 | planner_window_y: 0.0 #Specifies the y size of an optional window to restrict the planner to, default 0.0 8 | 9 | default_tolerance: 0.0 #If the goal is in an obstacle, the planer will plan to the nearest point in the radius of default_tolerance, default 0.0 10 | #The area is always searched, so could be slow for big values 11 | -------------------------------------------------------------------------------- /app/simpleVelocityNavigationExamples/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(appname simpleVelocityNavigationExamples) 8 | 9 | file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini) 10 | file(GLOB templates ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.template) 11 | file(GLOB apps ${CMAKE_CURRENT_SOURCE_DIR}/scripts/*.xml) 12 | 13 | yarp_install(FILES ${conf} DESTINATION ${NAVIGATION_CONTEXTS_INSTALL_DIR}/${appname}) 14 | yarp_install(FILES ${apps} DESTINATION ${NAVIGATION_APPLICATIONS_INSTALL_DIR}) 15 | yarp_install(FILES ${scripts} DESTINATION ${NAVIGATION_APPLICATIONS_TEMPLATES_INSTALL_DIR}) 16 | -------------------------------------------------------------------------------- /app/simpleVelocityNavigationExamples/conf/localizationServer.ini: -------------------------------------------------------------------------------- 1 | [GENERAL] 2 | name /localizationServer 3 | enable_ros 0 4 | 5 | [LOCALIZATION] 6 | use_localization_from_odometry_port 1 7 | use_localization_from_tf 0 8 | 9 | [MAP] 10 | connect_to_yarp_mapserver 1 11 | 12 | [ROS] 13 | initialpose_topic initialpose 14 | occupancygrid_topic occupancy_map 15 | 16 | [TF] 17 | robot_frame_id mobile_base_body_link 18 | map_frame_id map 19 | 20 | [ODOMETRY] 21 | odometry_broadcast_port /baseControl/odometry:o 22 | 23 | [INITIAL_POS] 24 | initial_map testMap 25 | initial_x 0.0 26 | initial_y 0.0 27 | initial_theta 0.0 28 | 29 | -------------------------------------------------------------------------------- /src/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | add_subdirectory(common) 8 | 9 | # add_subdirectory(deprecated) 10 | 11 | add_subdirectory(baseControl2) 12 | 13 | add_subdirectory(forceGuidance) 14 | add_subdirectory(navigationGUI) 15 | 16 | yarp_begin_plugin_library(navmod OPTION NAV_COMPILE_DEVICE_PLUGINS 17 | DEFAULT ON 18 | DOC "devices plugins") 19 | add_subdirectory(localizationDevices) 20 | add_subdirectory(navigationDevices) 21 | add_subdirectory(portmonitors) 22 | yarp_end_plugin_library(navmod) 23 | 24 | add_subdirectory(map2Gazebo) 25 | #add_subdirectory(mapper2D) 26 | 27 | add_subdirectory(follower) 28 | 29 | add_subdirectory(tests) 30 | add_subdirectory(tutorials) 31 | add_subdirectory(freeFloorViewer) 32 | 33 | #add_subdirectory(extendedRangefinder2DWrapper) da mettere??? 34 | 35 | -------------------------------------------------------------------------------- /src/baseControl2/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | 2 | # SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | # SPDX-License-Identifier: BSD-3-Clause 4 | 5 | 6 | set(PROJECTNAME baseControl2) 7 | project(${PROJECTNAME}) 8 | 9 | file(GLOB folder_source *.cpp cer/*.cpp ikart/*.cpp) 10 | file(GLOB folder_header *.h cer/*.h ikart/*.h) 11 | 12 | source_group("Source Files" FILES ${folder_source}) 13 | source_group("Header Files" FILES ${folder_header}) 14 | 15 | include_directories(${GSL_INCLUDE_DIRS} 16 | ${ICUB_INCLUDE_DIRS}) 17 | 18 | add_executable(${PROJECTNAME} ${folder_source} ${folder_header}) 19 | 20 | target_link_libraries(${PROJECTNAME} ctrlLib ${GSL_LIBRARIES} ${YARP_LIBRARIES} navigation_lib) 21 | 22 | set_property(TARGET ${PROJECTNAME} PROPERTY FOLDER "Modules") 23 | 24 | install(TARGETS ${PROJECTNAME} DESTINATION bin) 25 | 26 | -------------------------------------------------------------------------------- /src/baseControl2/baseControl.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | 18 | #include 19 | #include 20 | #include 21 | 22 | #include "controlThread.h" 23 | 24 | using namespace std; 25 | using namespace yarp::os; 26 | using namespace yarp::dev; 27 | using namespace yarp::math; 28 | 29 | class CtrlModule: public RFModule 30 | { 31 | protected: 32 | ControlThread *control_thr=nullptr; 33 | Port rpcPort; 34 | bool verbose_print=true; 35 | 36 | public: 37 | CtrlModule() {}; 38 | bool configure(ResourceFinder &rf) override; 39 | bool respond(const Bottle& command, Bottle& reply); 40 | bool close(); 41 | double getPeriod(); 42 | bool updateModule(); 43 | }; 44 | -------------------------------------------------------------------------------- /src/baseControl2/filters.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef FILTERS_H 7 | #define FILTERS_H 8 | 9 | #include 10 | 11 | namespace control_filters 12 | { 13 | /** 14 | * These functions implement a butterworth low pass first order, with a cut off frequency of 0.5-8Hz. 15 | * Coefficients have been computed in order to be used with a sampling frequency of 50Hz (20ms) 16 | * @param input the value to be filtered 17 | * @param i the joint number (0-9) 18 | * @return the filtered value 19 | */ 20 | double lp_filter_8Hz (double input, int i); 21 | double lp_filter_4Hz (double input, int i); 22 | double lp_filter_2Hz (double input, int i); 23 | double lp_filter_1Hz (double input, int i); 24 | double lp_filter_0_5Hz (double input, int i); 25 | 26 | /** 27 | * This function implements a rate limiter filter. 28 | * @param input the value to be filtered 29 | * @param i the joint number 30 | * @param rate the maximum change rate 31 | * @return the filtered value 32 | */ 33 | double ratelim_filter_0 (double input, int i, double rate_pos, double rate_neg, double max_val, double min_val); 34 | } 35 | #endif 36 | -------------------------------------------------------------------------------- /src/common/areas/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | project(areas) 8 | 9 | #file(GLOB folder_source areas.cpp) 10 | file(GLOB folder_source roomsSegmentation2.cpp) 11 | 12 | file(GLOB folder_header *.h) 13 | 14 | find_package(YARP 3.9 COMPONENTS os sig dev math gsl idl_tools REQUIRED) 15 | find_package(OpenCV) 16 | 17 | source_group("Source Files" FILES ${folder_source}) 18 | source_group("Header Files" FILES ${folder_header}) 19 | 20 | include_directories(${OpenCV_INCLUDE_DIRS} ${ICUB_INCLUDE_DIRS}) 21 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 22 | target_link_libraries(${PROJECT_NAME} ${OpenCV_LIBRARIES} ${YARP_LIBRARIES} ${ICUB_LIBRARIES}) 23 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 24 | -------------------------------------------------------------------------------- /src/common/movable_localization_device/movable_localization_device.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | #include "navigation_defines.h" 19 | 20 | using namespace yarp::os; 21 | 22 | class movable_localization_device 23 | { 24 | private: 25 | 26 | //device position 27 | enum 28 | { 29 | DEVICE_POS_IS_NONE = 0, 30 | DEVICE_POS_IS_FIXED = 1, 31 | DEVICE_FROM_TF_FIXED = 2, 32 | DEVICE_FROM_TF_VARIABLE = 3, 33 | } m_device_position; 34 | 35 | //configuration options 36 | 37 | 38 | //tf data 39 | yarp::dev::PolyDriver m_ptf; 40 | yarp::dev::IFrameTransform* m_iTf; 41 | double m_tf_data_received; 42 | std::string m_frame_robot_id; 43 | std::string m_frame_device_id; 44 | 45 | //fixed position 46 | yarp::dev::Nav2D::Map2DLocation m_device_to_robot_transform; 47 | 48 | 49 | 50 | public: 51 | movable_localization_device(); 52 | bool init(const yarp::os::Searchable& cfg, yarp::dev::IFrameTransform* iTf=nullptr); 53 | void relocate_data(yarp::dev::Nav2D::Map2DLocation& device_location); 54 | 55 | private: 56 | bool init_tf(); 57 | 58 | }; 59 | -------------------------------------------------------------------------------- /src/common/odometry_estimation/localization_device_with_estimated_odometry.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | 21 | using namespace yarp::os; 22 | 23 | class localization_device_with_estimated_odometry 24 | { 25 | private: 26 | //velocity estimation 27 | yarp::sig::Vector m_odom_vel; 28 | yarp::sig::Vector m_robot_vel; 29 | iCub::ctrl::AWLinEstimator* m_estimator; 30 | yarp::dev::OdometryData m_current_odom; 31 | std::mutex m_current_odom_mutex; 32 | 33 | public: 34 | localization_device_with_estimated_odometry(); 35 | virtual ~localization_device_with_estimated_odometry(); 36 | yarp::dev::OdometryData estimateOdometry(const yarp::dev::Nav2D::Map2DLocation& m_localization_data); 37 | yarp::dev::OdometryData getOdometry(); 38 | }; 39 | -------------------------------------------------------------------------------- /src/common/planner_aStar/aStar.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef A_STAR_H 7 | #define A_STAR_H 8 | 9 | #include 10 | 11 | #include 12 | #include 13 | 14 | //! namespace containing a complete implementation of the classic A* algorithm 15 | namespace aStar_algorithm 16 | { 17 | /** 18 | * This method computes (if exists) the path required to go from a start cell to a goal cell 19 | * @param map the gridmap containing the obstacles 20 | * @param start the start cell(x,y) 21 | * @param goal the arrival cell(x,y) 22 | * @param path the computed sequence of cells required to go from start cell to goal cell 23 | * @return true if the path exists, false if no valid path has been found 24 | */ 25 | bool find_astar_path(yarp::dev::Nav2D::MapGrid2D& map, yarp::dev::Nav2D::XYCell start, yarp::dev::Nav2D::XYCell goal, std::deque& path); 26 | }; 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /src/common/planner_aStar/mapUtils.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef MAP_H 7 | #define MAP_H 8 | 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | 19 | using namespace std; 20 | using namespace yarp::os; 21 | 22 | #ifndef M_PI 23 | #define M_PI 3.14159265 24 | #endif 25 | 26 | //! Helper functions which operates on a map grid, computing a path, drawing an image etc. 27 | namespace map_utilites 28 | { 29 | //return true if the straight line that connects src with dst does not contain any obstacles 30 | bool checkStraightLine(yarp::dev::Nav2D::MapGrid2D& map, yarp::dev::Nav2D::XYCell src, yarp::dev::Nav2D::XYCell dst); 31 | 32 | //simplify the path 33 | bool simplifyPath(yarp::dev::Nav2D::MapGrid2D& map, yarp::dev::Nav2D::Map2DPath input_path, yarp::dev::Nav2D::Map2DPath& output_path); 34 | 35 | //compute a path, given a start cell, a goal cell and a map grid. 36 | bool findPath(yarp::dev::Nav2D::MapGrid2D& map, yarp::dev::Nav2D::XYCell start, yarp::dev::Nav2D::XYCell goal, yarp::dev::Nav2D::Map2DPath& path); 37 | 38 | // register new obstacles into a map 39 | void update_obstacles_map(yarp::dev::Nav2D::MapGrid2D& map_to_be_updated, const yarp::dev::Nav2D::MapGrid2D& obstacles_map); 40 | 41 | // computes a list of areas crossed by given path 42 | std::vector compute_areas_to_cross(const yarp::dev::Nav2D::Map2DPath& path, const std::vector& Areas); 43 | }; 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /src/common/recovery_behaviors/stuck_detection.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | 16 | #ifndef NAVIGATION_STUCK_DETECTION_H 17 | #define NAVIGATION_STUCK_DETECTION_H 18 | 19 | class navigation_with_stuck_detection 20 | { 21 | protected: 22 | bool m_stuck_recovery_enable = false; 23 | double m_stuck_linear_tolerance = 0.01; 24 | double m_stuck_angular_tolerance = 1.0; 25 | double m_stuck_time_tolerance = 30.0; 26 | std::string m_recovery_algorithm_name; 27 | generic_recovery_behaviour* m_recovery_behavior = nullptr; 28 | double m_time_suspected_stuck; 29 | yarp::dev::Nav2D::Map2DLocation m_last_position; 30 | 31 | virtual ~navigation_with_stuck_detection() 32 | { 33 | if (m_recovery_behavior != nullptr) 34 | { 35 | delete m_recovery_behavior; 36 | m_recovery_behavior = nullptr; 37 | } 38 | } 39 | 40 | bool initialize_recovery(yarp::os::Searchable& config); 41 | bool we_are_stuck(const yarp::dev::Nav2D::Map2DLocation& current_position); 42 | }; 43 | 44 | #endif 45 | -------------------------------------------------------------------------------- /src/deprecated/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2018 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | -------------------------------------------------------------------------------- /src/follower/src/BTMonitor.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | /** 7 | * @file BTMonitor.h 8 | * @authors: Valentina Gaggero 9 | */ 10 | #include 11 | 12 | namespace FollowerTarget 13 | { 14 | namespace BTMonitor 15 | { 16 | enum class Event 17 | { 18 | e_from_bt, 19 | e_req_first_target, 20 | e_reply_first_target_invalid, 21 | e_req_target, 22 | e_reply_N_target_invalid, 23 | e_req_lookUp, 24 | e_reply_lookup_failed, 25 | e_reply_lookup_succeed, 26 | e_req_navig, 27 | e_reply_human_lost, 28 | e_reply_target_found, 29 | e_req_help, 30 | e_timeout, 31 | e_req_update_target, 32 | e_reply_update_failed, 33 | e_req 34 | 35 | }; 36 | 37 | 38 | 39 | class Monitor 40 | { 41 | 42 | public: 43 | 44 | bool init(void); 45 | 46 | void sendEvent(Event e); 47 | private: 48 | 49 | std::map mapEvt2Str; 50 | bool m_isRunning; 51 | yarp::os::Port m_toMonitorPort; 52 | 53 | }; 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /src/follower/src/Ball3DPointRetriever.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | /** 7 | * @file Ball3DPointRetriever.h 8 | * @authors: Valentina Gaggero 9 | */ 10 | 11 | #ifndef BALL3DPOINTRETRIVER_H 12 | #define BALL3DPOINTRETRIVER_H 13 | 14 | 15 | #include "TargetRetriever.h" 16 | 17 | namespace FollowerTarget 18 | { 19 | class Ball3DPointRetriever : public TargetRetriever 20 | { 21 | public: 22 | Target_t getTarget(void); 23 | bool init(yarp::os::ResourceFinder &rf); 24 | bool deinit(void); 25 | 26 | }; 27 | } 28 | #endif 29 | -------------------------------------------------------------------------------- /src/follower/src/HumanModel3DPointRetriever.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | /** 7 | * @file HumanModel3DPointRetriever.h 8 | * @authors: Valentina Gaggero 9 | */ 10 | #ifndef HUMANMODEL3DPOINTRESTRIVER_H 11 | #define HUMANMODEL3DPOINTRESTRIVER_H 12 | 13 | #include "TargetRetriever.h" 14 | 15 | #include 16 | 17 | namespace FollowerTarget 18 | { 19 | class HumanModel3DPointRetriever : public TargetRetriever 20 | { 21 | public: 22 | Target_t getTarget(void); 23 | bool init(yarp::os::ResourceFinder &rf); 24 | bool deinit(void); 25 | private: 26 | yarp::os::RpcClient m_worldInterfacePort; 27 | 28 | }; 29 | } 30 | 31 | #endif 32 | 33 | -------------------------------------------------------------------------------- /src/follower/src/NavigationController.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | /** 7 | * @file NavigationController.h 8 | * @authors: Valentina Gaggero 9 | */ 10 | #include 11 | #include 12 | #include 13 | 14 | namespace FollowerTarget 15 | { 16 | class NavigationController 17 | { 18 | public: 19 | NavigationController():m_iNav(nullptr), m_debugOn(true), m_navStarted(false){;} 20 | 21 | bool configure(yarp::os::ResourceFinder &rf); 22 | bool startAutonomousNav(double x, double y, double theta); 23 | bool AbortAutonomousNav(void); //if navigation is started abort it 24 | yarp::dev::Nav2D::NavigationStatusEnum getNavigationStatus(void); 25 | bool isConfigured(void); 26 | void setDebug(bool on) {m_debugOn=on;} 27 | private: 28 | //device drivers and interfaces 29 | yarp::dev::PolyDriver m_navClient_driver; 30 | yarp::dev::PolyDriver m_locServer_driver; 31 | yarp::dev::Nav2D::INavigation2D* m_iNav; //ATTENTION: this pointer can be null if AutoNav is not configured because .ini file disables it 32 | 33 | bool m_debugOn; 34 | bool m_navStarted; 35 | }; 36 | 37 | } 38 | -------------------------------------------------------------------------------- /src/follower/src/Person3DPointRetriever.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | /** 7 | * @file Person3DPointRetriver.h 8 | * @authors: Valentina Gaggero 9 | */ 10 | #ifndef PERSON3DPOINTRESTRIVER_H 11 | #define PERSON3DPOINTRESTRIVER_H 12 | 13 | #include "TargetRetriever.h" 14 | 15 | #include "AssistiveRehab/skeleton.h" 16 | 17 | namespace FollowerTarget 18 | { 19 | class Person3DPointRetriever : public TargetRetriever 20 | { 21 | public: 22 | Target_t getTarget(void); 23 | bool init(yarp::os::ResourceFinder &rf); 24 | bool deinit(void); 25 | private: 26 | assistive_rehab::SkeletonStd m_sk_target; 27 | }; 28 | } 29 | 30 | #endif 31 | 32 | -------------------------------------------------------------------------------- /src/follower/src/TargetRetriever.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | 7 | /** 8 | * @file TargetRetriever.cpp 9 | * @authors: Valentina Gaggero 10 | */ 11 | 12 | #include "TargetRetriever.h" 13 | 14 | #include 15 | #include 16 | 17 | using namespace yarp::os; 18 | using namespace FollowerTarget; 19 | 20 | YARP_LOG_COMPONENT(FOLLOWER_TARGETRET, "navigation.follower.targerRetriever") 21 | 22 | TargetRetriever::TargetRetriever(): m_debugOn(false){;} 23 | 24 | bool TargetRetriever::initInputPort(std::string inputPortName) 25 | { 26 | if(! m_inputPort.open(inputPortName)) 27 | { 28 | yCError(FOLLOWER_TARGETRET) << "TargetPointRetriever:Error opening input port"; 29 | return false; 30 | } 31 | return true; 32 | } 33 | 34 | bool TargetRetriever::deinitInputPort(void) 35 | { 36 | m_inputPort.interrupt(); 37 | m_inputPort.close(); 38 | return true; 39 | } 40 | 41 | std::string Target_tBIS::toString(void) 42 | { 43 | std::string str="Target"; 44 | 45 | if(isValid) 46 | { 47 | str+= " VALID point3d=(" + std::to_string(point3D[0]) + " " + std::to_string(point3D[1]) + " " + std::to_string(point3D[2]) + ")"; 48 | if(hasValidPixel()) 49 | { 50 | str+= " pixel=(" + std::to_string(pixel[0]) + ", " + std::to_string(pixel[1]) +")"; 51 | } 52 | else 53 | { 54 | str+= " pixel NOT valid"; 55 | } 56 | str+= " ref_frame=" + ReferenceFrameOfTarget2String(refFrame); 57 | } 58 | else 59 | { 60 | str+=" NOT VALID"; 61 | } 62 | return str; 63 | } 64 | 65 | 66 | 67 | 68 | -------------------------------------------------------------------------------- /src/follower/src/TimedPath.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | 7 | /** 8 | * @file TimedPath.h 9 | * @authors: Marco Randazzo , Valentina Gaggero 10 | */ 11 | 12 | #ifndef TIMEDPATH_H 13 | #define TIMEDPATH_H 14 | 15 | #include 16 | 17 | #include 18 | 19 | namespace FollowerTarget 20 | { 21 | 22 | class TimedPath 23 | { 24 | struct TimedWaypoint_t 25 | { 26 | double time; 27 | yarp::dev::Map2DLocation loc; 28 | }; 29 | 30 | std::list path; 31 | 32 | public: 33 | double sampling_time; 34 | double max_queue_lenght; 35 | 36 | TimedPath(); 37 | 38 | yarp::dev::Map2DLocation getPrediction(void); 39 | 40 | void update(yarp::dev::Map2DLocation cur_loc); 41 | }; 42 | 43 | } 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /src/follower/src/main.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | /** 7 | * @file main.cpp 8 | * @authors: Valentina Gaggero 9 | */ 10 | 11 | #include "FollowerModule.h" 12 | #include 13 | #include 14 | 15 | #include 16 | #include 17 | 18 | 19 | 20 | using namespace yarp::os; 21 | 22 | int main(int argc, char * argv[]) 23 | { 24 | /* initialize yarp network */ 25 | yarp::os::Network yarp; 26 | if (!yarp.checkNetwork()) 27 | { 28 | yError("check Yarp network.\n"); 29 | return -1; 30 | } 31 | 32 | /* create your module */ 33 | FollowerTarget::FollowerModule module; 34 | /* prepare and configure the resource finder */ 35 | ResourceFinder rf; 36 | rf.configure(argc, argv); 37 | rf.setVerbose(true); 38 | yDebug() << "Configuring and starting module. \n"; 39 | module.runModule(rf); // This calls configure(rf) and, upon success, the module execution begins with a call to updateModule() 40 | yDebug()<<"Main returning..."; 41 | return 0; 42 | } 43 | -------------------------------------------------------------------------------- /src/forceGuidance/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2010 RobotCub Consortium 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | set(PROJECTNAME forceGuidance) 8 | project(${PROJECTNAME}) 9 | 10 | file(GLOB folder_source *.cpp) 11 | file(GLOB folder_header *.h) 12 | 13 | source_group("Source Files" FILES ${folder_source}) 14 | source_group("Header Files" FILES ${folder_header}) 15 | 16 | include_directories(${GSL_INCLUDE_DIRS}) 17 | 18 | add_executable(${PROJECTNAME} ${folder_source}) 19 | 20 | target_link_libraries(${PROJECTNAME} ${GSL_LIBRARIES} ${YARP_LIBRARIES} navigation_lib) 21 | 22 | set_property(TARGET ${PROJECTNAME} PROPERTY FOLDER "Modules") 23 | 24 | install(TARGETS ${PROJECTNAME} DESTINATION bin) 25 | -------------------------------------------------------------------------------- /src/forceGuidance/README.md: -------------------------------------------------------------------------------- 1 | ## forceGuidance 2 | 3 | This module is currently under development/testing and should be not used in a user application. -------------------------------------------------------------------------------- /src/freeFloorViewer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Ettore Landini ettore.landini@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | project(freeFloorViewer) 8 | 9 | file(GLOB folder_source *.cpp) 10 | file(GLOB folder_header *.h) 11 | 12 | source_group("Source Files" FILES ${folder_source}) 13 | source_group("Header Files" FILES ${folder_header}) 14 | 15 | find_package(YARP REQUIRED COMPONENTS sig cv dev os math) 16 | 17 | include_directories(${OpenCV_INCLUDE_DIRS} ${ICUB_INCLUDE_DIRS}) 18 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 19 | target_link_libraries(${PROJECT_NAME} ${OpenCV_LIBRARIES} ${YARP_LIBRARIES} navigation_lib) 20 | set_property(TARGET freeFloorViewer PROPERTY FOLDER "Modules") 21 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 22 | -------------------------------------------------------------------------------- /src/freeFloorViewer/freeFloorViewer.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef FREE_FLOOR_VIEWER_H 7 | #define FREE_FLOOR_VIEWER_H 8 | 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | #include 19 | 20 | #include 21 | #include "freeFloorThread.h" 22 | #include "headOrientator.h" 23 | 24 | class FreeFloorViewer : public yarp::os::RFModule 25 | { 26 | protected: 27 | yarp::os::BufferedPort m_posInputPort; 28 | yarp::os::BufferedPort m_headInputPort; 29 | FreeFloorThread* m_innerThread; 30 | double m_period; 31 | HeadOrientator* m_headOrientator; 32 | 33 | public: 34 | FreeFloorViewer(); 35 | virtual bool configure(yarp::os::ResourceFinder &rf); 36 | virtual bool close(); 37 | virtual double getPeriod(); 38 | virtual bool updateModule(); 39 | }; 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /src/freeFloorViewer/headOrientator.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef HEAD_ORIENTATOR_H 7 | #define HEAD_ORIENTATOR_H 8 | 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | 19 | class HeadOrientator : public yarp::os::TypedReaderCallback 20 | { 21 | private: 22 | //Polydriver 23 | yarp::dev::PolyDriver m_neck; 24 | yarp::dev::IPositionControl* m_iNeckPos{nullptr}; 25 | yarp::dev::IControlLimits* m_iNeckLimits{nullptr}; 26 | yarp::dev::IEncoders* m_iNeckEncoders{nullptr}; 27 | 28 | //Parameters 29 | int m_imgWidth{0}; 30 | int m_imgHeight{0}; 31 | double m_horFOV{0.0}; 32 | double m_verFOV{0.0}; 33 | double m_vToPitch{0.0}; 34 | double m_uToYaw{0.0}; 35 | double m_pitchSafeMargin{5.0}; 36 | double m_yawSafeMargin{5.0}; 37 | double m_yawMax{0.0}; 38 | double m_pitchMax{0.0}; 39 | double m_yawMin{0.0}; 40 | double m_pitchMin{0.0}; 41 | 42 | public: 43 | //Constructor/Distructor 44 | HeadOrientator(){} 45 | ~HeadOrientator(){} 46 | 47 | //Internal methods 48 | bool configure(yarp::os::Property rf); 49 | void rotateHead(yarp::os::Bottle& b); 50 | void backToZero(); 51 | void close(); 52 | 53 | //Port callback 54 | using TypedReaderCallback::onRead; 55 | void onRead(yarp::os::Bottle& b) override; 56 | }; 57 | 58 | #endif //HEAD_ORIENTATOR_H 59 | -------------------------------------------------------------------------------- /src/freeFloorViewer/main.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | 14 | #include 15 | #include 16 | #include 17 | #include 18 | 19 | #include "freeFloorViewer.h" 20 | 21 | int main(int argc, char *argv[]) 22 | { 23 | yarp::os::Network yarp; 24 | if (!yarp.checkNetwork()) 25 | { 26 | yError("check Yarp network.\n"); 27 | return -1; 28 | } 29 | 30 | yarp::os::ResourceFinder rf; 31 | rf.setVerbose(true); 32 | rf.setDefaultConfigFile("freeFloorViewer_sim.ini"); //overridden by --from parameter 33 | rf.setDefaultContext("freeFloorViewer"); //overridden by --context parameter 34 | rf.configure(argc,argv); 35 | //std::string debug_rf = rf.toString(); 36 | FreeFloorViewer currViewer; 37 | 38 | return currViewer.runModule(rf); 39 | } 40 | -------------------------------------------------------------------------------- /src/localizationDevices/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2019 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | if(NAVIGATION_USE_ROS) 8 | add_subdirectory(rosLocalizer) 9 | endif() 10 | if(NAVIGATION_USE_ROS2) 11 | add_subdirectory(ros2Localizer) 12 | endif() 13 | add_subdirectory(odomLocalizer) 14 | add_subdirectory(gazeboLocalizer) 15 | add_subdirectory(pozyxLocalizer) 16 | add_subdirectory(t265Localizer) 17 | add_subdirectory(amclLocalizer) 18 | 19 | -------------------------------------------------------------------------------- /src/localizationDevices/amclLocalizer/amcl/pf/eig3.h: -------------------------------------------------------------------------------- 1 | 2 | /* Eigen-decomposition for symmetric 3x3 real matrices. 3 | Public domain, copied from the public domain Java library JAMA. */ 4 | 5 | #ifndef _eig_h 6 | 7 | /* Symmetric matrix A => eigenvectors in columns of V, corresponding 8 | eigenvalues in d. */ 9 | void eigen_decomposition(double A[3][3], double V[3][3], double d[3]); 10 | 11 | #endif 12 | -------------------------------------------------------------------------------- /src/localizationDevices/amclLocalizer/amclLocalizer.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/src/localizationDevices/amclLocalizer/amclLocalizer.cpp -------------------------------------------------------------------------------- /src/localizationDevices/gazeboLocalizer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2019 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | yarp_prepare_plugin(gazeboLocalizer 7 | CATEGORY device 8 | TYPE gazeboLocalizer 9 | INCLUDE gazeboLocalizer.h 10 | DEFAULT ON) 11 | 12 | if(SKIP_gazeboLocalizer) 13 | return() 14 | endif() 15 | 16 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 17 | 18 | yarp_add_plugin(gazeboLocalizer gazeboLocalizer.h gazeboLocalizer.cpp) 19 | 20 | include_directories (include) 21 | 22 | target_link_libraries(gazeboLocalizer YARP::YARP_os 23 | YARP::YARP_sig 24 | YARP::YARP_dev 25 | YARP::YARP_math 26 | navigation_lib) 27 | 28 | 29 | yarp_install(TARGETS gazeboLocalizer 30 | EXPORT YARP_${YARP_PLUGIN_MASTER} 31 | COMPONENT ${YARP_PLUGIN_MASTER} 32 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 33 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 34 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 35 | 36 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 37 | 38 | set_property(TARGET gazeboLocalizer PROPERTY FOLDER "Plugins/Localization Devices") 39 | 40 | -------------------------------------------------------------------------------- /src/localizationDevices/odomLocalizer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | yarp_prepare_plugin(odomLocalizer 7 | CATEGORY device 8 | TYPE odomLocalizer 9 | INCLUDE odomLocalizer.h 10 | DEFAULT ON) 11 | 12 | if(SKIP_odomLocalizer) 13 | return() 14 | endif() 15 | 16 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 17 | 18 | yarp_add_plugin(odomLocalizer odomLocalizer.h odomLocalizer.cpp) 19 | 20 | include_directories (include) 21 | 22 | target_link_libraries(odomLocalizer YARP::YARP_os 23 | YARP::YARP_sig 24 | YARP::YARP_dev 25 | YARP::YARP_math 26 | navigation_lib) 27 | 28 | 29 | yarp_install(TARGETS odomLocalizer 30 | EXPORT YARP_${YARP_PLUGIN_MASTER} 31 | COMPONENT ${YARP_PLUGIN_MASTER} 32 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 33 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 34 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 35 | 36 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 37 | 38 | set_property(TARGET odomLocalizer PROPERTY FOLDER "Plugins/Localization Devices") 39 | 40 | -------------------------------------------------------------------------------- /src/localizationDevices/pozyxLocalizer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2018 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | yarp_prepare_plugin(pozyxLocalizer 7 | CATEGORY device 8 | TYPE pozyxLocalizer 9 | INCLUDE pozyxLocalizer.h 10 | DEFAULT ON) 11 | 12 | if(SKIP_pozyxLocalizer) 13 | return() 14 | endif() 15 | 16 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 17 | 18 | yarp_add_plugin(pozyxLocalizer pozyxLocalizer.h pozyxLocalizer.cpp) 19 | 20 | include_directories (include) 21 | 22 | target_link_libraries(pozyxLocalizer YARP::YARP_os 23 | YARP::YARP_sig 24 | YARP::YARP_dev 25 | YARP::YARP_math 26 | navigation_lib) 27 | 28 | 29 | yarp_install(TARGETS pozyxLocalizer 30 | EXPORT YARP_${YARP_PLUGIN_MASTER} 31 | COMPONENT ${YARP_PLUGIN_MASTER} 32 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 33 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 34 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 35 | 36 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 37 | 38 | set_property(TARGET pozyxLocalizer PROPERTY FOLDER "Plugins/Localization Devices") 39 | 40 | -------------------------------------------------------------------------------- /src/localizationDevices/ros2Localizer/Ros2Spinner.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include "Ros2Spinner.h" 7 | 8 | #include 9 | #include 10 | #include 11 | 12 | namespace { 13 | YARP_LOG_COMPONENT(ROS2SPINNER, "yarp.ros2.Ros2Spinner") 14 | } 15 | 16 | Ros2Spinner::Ros2Spinner(std::shared_ptr input_node) : 17 | m_node(input_node) 18 | {} 19 | 20 | void Ros2Spinner::run() 21 | { 22 | if(!m_spun) //This is just a temporary solution. 23 | { 24 | rclcpp::spin(m_node); 25 | m_spun = true; 26 | } 27 | } 28 | 29 | void Ros2Spinner::threadRelease() 30 | { 31 | if(m_spun) 32 | { 33 | rclcpp::shutdown(); 34 | m_spun = false; 35 | } 36 | } -------------------------------------------------------------------------------- /src/localizationDevices/ros2Localizer/Ros2Spinner.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | class Ros2Spinner : public yarp::os::Thread 12 | { 13 | private: 14 | bool m_spun{false}; 15 | std::shared_ptr m_node; 16 | public: 17 | Ros2Spinner(std::shared_ptr input_node); 18 | ~Ros2Spinner()=default; 19 | 20 | void run(); 21 | void threadRelease() override; 22 | }; 23 | -------------------------------------------------------------------------------- /src/localizationDevices/ros2Localizer/Ros2Utils.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include "Ros2Utils.h" 7 | 8 | 9 | rclcpp::Node::SharedPtr NodeCreator::createNode(std::string name) 10 | { 11 | if(!rclcpp::ok()) 12 | { 13 | rclcpp::init(/*argc*/ 0, /*argv*/ nullptr); 14 | } 15 | return std::make_shared(name); 16 | 17 | } 18 | -------------------------------------------------------------------------------- /src/localizationDevices/ros2Localizer/Ros2Utils.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef YARP_ROS2_ROS2UTILS_H 7 | #define YARP_ROS2_ROS2UTILS_H 8 | 9 | #include 10 | class NodeCreator 11 | { 12 | public: 13 | static rclcpp::Node::SharedPtr createNode(std::string name); 14 | }; 15 | 16 | 17 | #endif // YARP_ROS2_ROS2UTILS_H 18 | -------------------------------------------------------------------------------- /src/localizationDevices/rosLocalizer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | yarp_prepare_plugin(rosLocalizer 7 | CATEGORY device 8 | TYPE rosLocalizer 9 | INCLUDE rosLocalizer.h 10 | DEFAULT OFF) 11 | 12 | if(SKIP_rosLocalizer) 13 | return() 14 | endif() 15 | 16 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 17 | 18 | yarp_add_plugin(rosLocalizer rosLocalizer.h rosLocalizer.cpp) 19 | 20 | target_link_libraries(rosLocalizer YARP::YARP_os 21 | YARP::YARP_sig 22 | YARP::YARP_dev 23 | YARP::YARP_math 24 | YARP::YARP_rosmsg 25 | navigation_lib) 26 | 27 | 28 | yarp_install(TARGETS rosLocalizer 29 | EXPORT YARP_${YARP_PLUGIN_MASTER} 30 | COMPONENT ${YARP_PLUGIN_MASTER} 31 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 32 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 33 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 34 | 35 | 36 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 37 | 38 | set_property(TARGET rosLocalizer PROPERTY FOLDER "Plugins/Localization Devices") 39 | 40 | -------------------------------------------------------------------------------- /src/localizationDevices/t265Localizer/localizationServer_pb_on_ros_camera3.ini: -------------------------------------------------------------------------------- 1 | [GENERAL] 2 | local_name /localizationServer_camera3 3 | name /localizationServer_camera3 4 | enable_ros 0 5 | 6 | [LOCALIZATION] 7 | use_odometry_from_odometry_port 1 8 | use_odometry_from_tf 0 9 | 10 | [DEVICE_POS] 11 | device_position fixed 12 | #device_position from_tf_fixed 13 | #device_position from_tf_variable 14 | device_position_x 0 15 | device_position_y 0 16 | device_position_t 0 17 | 18 | 19 | [MAP] 20 | connect_to_yarp_mapserver 1 21 | 22 | [ROS] 23 | initialpose_topic initialpose 24 | occupancygrid_topic occupancy_map 25 | parent_frame_id /t265odom_camera3 26 | child_frame_id /mobile_base_body_link_camera3 27 | 28 | [TF] 29 | robot_frame_id mobile_base_body_link 30 | map_frame_id map 31 | device_frame_id t265_camera3_link 32 | 33 | [TF_CLIENT] 34 | refFrame head_link 35 | baseFrame mobile_base_body_link 36 | localTC /camera3/transformClient 37 | remoteTC /transformServer 38 | period 10 39 | 40 | [ODOMETRY] 41 | odometry_broadcast_port /baseControl/odometry:o 42 | 43 | [INITIAL_POS] 44 | initial_map sanquirico 45 | map_transform_x 0.0 46 | map_transform_y 0.0 47 | map_transform_t 0.0 48 | 49 | -------------------------------------------------------------------------------- /src/map2Gazebo/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2018 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | project(map2Gazebo) 8 | 9 | file(GLOB folder_source *.cpp) 10 | file(GLOB folder_header *.h) 11 | 12 | source_group("Source Files" FILES ${folder_source}) 13 | source_group("Header Files" FILES ${folder_header}) 14 | 15 | include_directories(${OpenCV_INCLUDE_DIRS} ${ICUB_INCLUDE_DIRS}) 16 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 17 | target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} navigation_lib) 18 | set_property(TARGET map2Gazebo PROPERTY FOLDER "Tools") 19 | install(TARGETS map2Gazebo DESTINATION bin) 20 | 21 | -------------------------------------------------------------------------------- /src/navigationDevices/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2019 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | add_subdirectory(navigationDeviceTemplate) 8 | add_subdirectory(robotGotoDevice) 9 | add_subdirectory(robotPathPlannerDevice) 10 | if(NAVIGATION_USE_ROS) 11 | add_subdirectory(rosNavigator) 12 | endif() 13 | if(NAVIGATION_USE_ROS2) 14 | add_subdirectory(ros2Navigator) 15 | endif() 16 | add_subdirectory(simpleVelocityNavigation) 17 | add_subdirectory(velocityInputHandler) 18 | -------------------------------------------------------------------------------- /src/navigationDevices/navigationDeviceTemplate/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | yarp_prepare_plugin(navigationDeviceTemplate 2 | CATEGORY device 3 | TYPE navigationDeviceTemplate 4 | INCLUDE navigationDeviceTemplate.h 5 | DEFAULT ON) 6 | 7 | if(SKIP_navigationDeviceTemplate) 8 | return() 9 | endif() 10 | 11 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 12 | 13 | yarp_add_plugin(navigationDeviceTemplate navigationDeviceTemplate.h 14 | navigationDeviceTemplate.cpp) 15 | 16 | target_link_libraries(navigationDeviceTemplate YARP::YARP_os 17 | YARP::YARP_sig 18 | YARP::YARP_dev 19 | YARP::YARP_math 20 | navigation_lib) 21 | 22 | yarp_install(TARGETS navigationDeviceTemplate 23 | EXPORT YARP_${YARP_PLUGIN_MASTER} 24 | COMPONENT ${YARP_PLUGIN_MASTER} 25 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 26 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 27 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 28 | 29 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 30 | 31 | set_property(TARGET navigationDeviceTemplate PROPERTY FOLDER "Plugins/Navigation Devices") 32 | -------------------------------------------------------------------------------- /src/navigationDevices/robotGotoDevice/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | yarp_prepare_plugin(robotGotoDev 7 | CATEGORY device 8 | TYPE robotGotoDev 9 | INCLUDE robotGotoDev.h 10 | DEFAULT ON) 11 | 12 | if(SKIP_robotGotoDev) 13 | return() 14 | endif() 15 | 16 | 17 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 18 | 19 | yarp_add_plugin(robotGotoDev robotGotoDev.h robotGotoDev.cpp robotGotoCtrl.h robotGotoCtrl.cpp obstacles.h obstacles.cpp ) 20 | 21 | target_link_libraries(robotGotoDev YARP::YARP_os 22 | YARP::YARP_sig 23 | YARP::YARP_dev 24 | YARP::YARP_math 25 | navigation_lib) 26 | 27 | 28 | yarp_install(TARGETS robotGotoDev 29 | EXPORT YARP_${YARP_PLUGIN_MASTER} 30 | COMPONENT ${YARP_PLUGIN_MASTER} 31 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 32 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 33 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 34 | 35 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 36 | 37 | set_property(TARGET robotGotoDev PROPERTY FOLDER "Plugins/Navigation Devices") 38 | 39 | -------------------------------------------------------------------------------- /src/navigationDevices/robotPathPlannerDevice/pathPlannerCtrlHelpers.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include "pathPlannerCtrlHelpers.h" 7 | 8 | using namespace std; 9 | using namespace yarp::os; 10 | using namespace yarp::dev; 11 | 12 | //reserved for future use! -------------------------------------------------------------------------------- /src/navigationDevices/robotPathPlannerDevice/pathPlannerCtrlHelpers.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | 9 | #ifndef PATH_PLANNER_HELPERS 10 | #define PATH_PLANNER_HELPERS 11 | 12 | namespace pathPlannerHelpers 13 | { 14 | //reserved for future use! 15 | } 16 | 17 | #endif -------------------------------------------------------------------------------- /src/navigationDevices/ros2Navigator/Ros2Spinner.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include "Ros2Spinner.h" 7 | 8 | #include 9 | #include 10 | #include 11 | 12 | namespace { 13 | YARP_LOG_COMPONENT(ROS2SPINNER, "yarp.ros2.Ros2Spinner") 14 | } 15 | 16 | Ros2Spinner::Ros2Spinner(std::shared_ptr input_node) : 17 | m_node(input_node) 18 | {} 19 | 20 | void Ros2Spinner::run() 21 | { 22 | if(!m_spun) //This is just a temporary solution. 23 | { 24 | rclcpp::spin(m_node); 25 | m_spun = true; 26 | } 27 | } 28 | 29 | void Ros2Spinner::threadRelease() 30 | { 31 | if(m_spun) 32 | { 33 | rclcpp::shutdown(); 34 | m_spun = false; 35 | } 36 | } -------------------------------------------------------------------------------- /src/navigationDevices/ros2Navigator/Ros2Spinner.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | class Ros2Spinner : public yarp::os::Thread 12 | { 13 | private: 14 | bool m_spun{false}; 15 | std::shared_ptr m_node; 16 | public: 17 | Ros2Spinner(std::shared_ptr input_node); 18 | ~Ros2Spinner()=default; 19 | 20 | void run(); 21 | void threadRelease() override; 22 | }; 23 | -------------------------------------------------------------------------------- /src/navigationDevices/ros2Navigator/Ros2Utils.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include "Ros2Utils.h" 7 | 8 | 9 | rclcpp::Node::SharedPtr NodeCreator::createNode(std::string name) 10 | { 11 | if(!rclcpp::ok()) 12 | { 13 | rclcpp::init(/*argc*/ 0, /*argv*/ nullptr); 14 | } 15 | return std::make_shared(name); 16 | 17 | } 18 | -------------------------------------------------------------------------------- /src/navigationDevices/ros2Navigator/Ros2Utils.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef YARP_ROS2_ROS2UTILS_H 7 | #define YARP_ROS2_ROS2UTILS_H 8 | 9 | #include 10 | class NodeCreator 11 | { 12 | public: 13 | static rclcpp::Node::SharedPtr createNode(std::string name); 14 | }; 15 | 16 | 17 | #endif // YARP_ROS2_ROS2UTILS_H 18 | -------------------------------------------------------------------------------- /src/navigationDevices/simpleVelocityNavigation/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | yarp_prepare_plugin(simpleVelocityNavigation 2 | CATEGORY device 3 | TYPE simpleVelocityNavigation 4 | INCLUDE simpleVelocityNavigation.h 5 | DEFAULT ON) 6 | 7 | if(SKIP_simpleVelocityNavigation) 8 | return() 9 | endif() 10 | 11 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 12 | 13 | yarp_add_plugin(simpleVelocityNavigation simpleVelocityNavigation.h 14 | simpleVelocityNavigation.cpp) 15 | 16 | target_link_libraries(simpleVelocityNavigation YARP::YARP_os 17 | YARP::YARP_sig 18 | YARP::YARP_dev 19 | YARP::YARP_math 20 | navigation_lib) 21 | 22 | yarp_install(TARGETS simpleVelocityNavigation 23 | EXPORT YARP_${YARP_PLUGIN_MASTER} 24 | COMPONENT ${YARP_PLUGIN_MASTER} 25 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 26 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 27 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 28 | 29 | 30 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 31 | 32 | set_property(TARGET simpleVelocityNavigation PROPERTY FOLDER "Plugins/Navigation Devices") 33 | -------------------------------------------------------------------------------- /src/navigationDevices/velocityInputHandler/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | yarp_prepare_plugin(velocityInputHandler 2 | CATEGORY device 3 | TYPE VelocityInputHandler 4 | INCLUDE velocityInputHandler.h 5 | DEFAULT ON) 6 | 7 | if(SKIP_velocityInputHandler) 8 | return() 9 | endif() 10 | 11 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 12 | 13 | yarp_add_plugin(velocityInputHandler velocityInputHandler.h 14 | velocityInputHandler.cpp) 15 | 16 | target_link_libraries(velocityInputHandler YARP::YARP_os 17 | YARP::YARP_sig 18 | YARP::YARP_dev 19 | YARP::YARP_math 20 | navigation_lib) 21 | 22 | yarp_install(TARGETS velocityInputHandler 23 | EXPORT YARP_${YARP_PLUGIN_MASTER} 24 | COMPONENT ${YARP_PLUGIN_MASTER} 25 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 26 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 27 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 28 | 29 | 30 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 31 | 32 | set_property(TARGET velocityInputHandler PROPERTY FOLDER "Plugins/Navigation Devices") 33 | -------------------------------------------------------------------------------- /src/navigationDevices/velocityInputHandler/velocityInputHandler.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: LGPL-2.1-or-later 4 | */ 5 | 6 | #include 7 | #include 8 | 9 | #ifndef NAV_VEL_INPUT_HANDLER_H 10 | #define NAV_VEL_INPUT_HANDLER_H 11 | 12 | class VelocityInputHandler : public yarp::dev::Nav2D::INavigation2DVelocityActions, 13 | public yarp::dev::DeviceDriver 14 | { 15 | protected: 16 | std::string m_localName; 17 | std::mutex m_mutex; 18 | 19 | //internal type definition to store control output 20 | struct control_type 21 | { 22 | double linear_xvel = 0; 23 | double linear_yvel = 0; 24 | double angular_vel = 0; 25 | double timeout = 0; 26 | double reception_time =0; 27 | } 28 | m_control_out; 29 | double m_max_timeout = 0.1; 30 | bool timeout_printable = false; 31 | 32 | public: 33 | VelocityInputHandler(); 34 | 35 | public: 36 | virtual bool open(yarp::os::Searchable& config) override; 37 | virtual bool close() override; 38 | 39 | public: 40 | //INavigation2D methods 41 | yarp::dev::ReturnValue applyVelocityCommand(double x_vel, double y_vel, double theta_vel, double timeout = 0.1) override; 42 | yarp::dev::ReturnValue getLastVelocityCommand(double& x_vel, double& y_vel, double& theta_vel) override; 43 | }; 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /src/navigationGUI/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2016 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | project(navigationGUI) 8 | 9 | file(GLOB folder_source *.cpp) 10 | file(GLOB folder_header *.h) 11 | 12 | source_group("Source Files" FILES ${folder_source}) 13 | source_group("Header Files" FILES ${folder_header}) 14 | 15 | find_package(YARP REQUIRED COMPONENTS sig cv dev os math) 16 | include_directories(${OpenCV_INCLUDE_DIRS} ${ICUB_INCLUDE_DIRS}) 17 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 18 | target_link_libraries(${PROJECT_NAME} ${OpenCV_LIBRARIES} ${YARP_LIBRARIES} navigation_lib) 19 | set_property(TARGET navigationGUI PROPERTY FOLDER "Modules") 20 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 21 | 22 | -------------------------------------------------------------------------------- /src/navigationGUI/navGuiHelpers.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2024 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #include "navGui.h" 7 | 8 | using namespace std; 9 | using namespace yarp::os; 10 | using namespace yarp::dev; 11 | using namespace yarp::dev::Nav2D; 12 | 13 | void NavGuiThread::getTimeouts(int& localiz, int& laser, int& nav_status) 14 | { 15 | localiz = m_loc_timeout_counter; 16 | laser = m_laser_timeout_counter; 17 | nav_status = m_nav_status_timeout_counter; 18 | } 19 | 20 | void NavGuiThread::printStats() 21 | { 22 | //To be implemented 23 | } 24 | 25 | NavigationStatusEnum NavGuiThread::getNavigationStatusAsInt() 26 | { 27 | return m_navigation_status; 28 | } 29 | 30 | string NavGuiThread::getNavigationStatusAsString() 31 | { 32 | string s = INavigation2DHelpers::statusToString(m_navigation_status); 33 | return s; 34 | } 35 | -------------------------------------------------------------------------------- /src/portmonitors/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2019 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | add_subdirectory(joystick2velocityCommand) 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/portmonitors/joystick2velocityCommand/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Copyright (C) 2016 iCub Facility, Istituto Italiano di Tecnologia 2 | # Authors: Daniele E. Domenichelli 3 | # CopyPolicy: LGPLv2.1+ 4 | 5 | set(CMAKE_INCLUDE_CURRENT_DIR TRUE) 6 | 7 | yarp_prepare_plugin(joy2vel 8 | CATEGORY portmonitor 9 | TYPE Joy2vel 10 | INCLUDE joystick2velocityCommand.h 11 | INTERNAL) 12 | 13 | if(SKIP_joy2vel) 14 | return() 15 | endif() 16 | 17 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 18 | 19 | yarp_add_plugin(joy2vel 20 | joystick2velocityCommand.cpp 21 | joystick2velocityCommand.h) 22 | 23 | include_directories (include) 24 | 25 | target_link_libraries(joy2vel YARP::YARP_os 26 | YARP::YARP_dev 27 | YARP::YARP_init 28 | YARP::YARP_sig) 29 | 30 | yarp_install(TARGETS joy2vel 31 | EXPORT YARP_${YARP_PLUGIN_MASTER} 32 | COMPONENT ${YARP_PLUGIN_MASTER} 33 | LIBRARY DESTINATION ${NAVIGATION_DYNAMIC_PLUGINS_INSTALL_DIR} 34 | ARCHIVE DESTINATION ${NAVIGATION_STATIC_PLUGINS_INSTALL_DIR} 35 | YARP_INI DESTINATION ${NAVIGATION_PLUGIN_MANIFESTS_INSTALL_DIR}) 36 | 37 | set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE) 38 | 39 | set_property(TARGET joy2vel PROPERTY FOLDER "Plugins/Localization Devices") 40 | -------------------------------------------------------------------------------- /src/portmonitors/joystick2velocityCommand/joystick2velocityCommand.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2020 Istituto Italiano di Tecnologia (IIT) 3 | * All rights reserved. 4 | * 5 | * This software may be modified and distributed under the terms of the 6 | * BSD-3-Clause license. See the accompanying LICENSE file for details. 7 | */ 8 | 9 | #ifndef JOYSTICK2VELOCITYCOMMAND_H 10 | #define JOYSTICK2VELOCITYCOMMAND_H 11 | 12 | #include 13 | #include 14 | #include 15 | 16 | class Joy2vel : public yarp::os::MonitorObject 17 | { 18 | public: 19 | Joy2vel(); 20 | virtual bool accept(yarp::os::Things& thing); 21 | virtual yarp::os::Things& update(yarp::os::Things& thing); 22 | private: 23 | yarp::os::Things m_things; 24 | yarp::dev::MobileBaseVelocity m_command; 25 | 26 | bool validate_bot(const yarp::os::Bottle* bot); 27 | }; 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /src/ros_messages/actionlib_msgs/GoalID.msg: -------------------------------------------------------------------------------- 1 | time stamp 2 | string id -------------------------------------------------------------------------------- /src/ros_messages/actionlib_msgs/GoalStatus.msg: -------------------------------------------------------------------------------- 1 | GoalID goal_id 2 | uint8 status 3 | uint8 PENDING = 0 # The goal has yet to be processed by the action server 4 | uint8 ACTIVE = 1 # The goal is currently being processed by the action server 5 | uint8 PREEMPTED = 2 # The goal received a cancel request after it started executing 6 | # and has since completed its execution (Terminal State) 7 | uint8 SUCCEEDED = 3 # The goal was achieved successfully by the action server (Terminal State) 8 | uint8 ABORTED = 4 # The goal was aborted during execution by the action server due 9 | # to some failure (Terminal State) 10 | uint8 REJECTED = 5 # The goal was rejected by the action server without being processed, 11 | # because the goal was unattainable or invalid (Terminal State) 12 | uint8 PREEMPTING = 6 # The goal received a cancel request after it started executing 13 | # and has not yet completed execution 14 | uint8 RECALLING = 7 # The goal received a cancel request before it started executing, 15 | # but the action server has not yet confirmed that the goal is canceled 16 | uint8 RECALLED = 8 # The goal received a cancel request before it started executing 17 | # and was successfully cancelled (Terminal State) 18 | uint8 LOST = 9 # An action client can determine that a goal is LOST. This should not be 19 | # sent over the wire by an action server 20 | 21 | #Allow for the user to associate a string with GoalStatus for debugging 22 | string text -------------------------------------------------------------------------------- /src/ros_messages/actionlib_msgs/GoalStatusArray.msg: -------------------------------------------------------------------------------- 1 | std_msgs/Header header 2 | actionlib_msgs/GoalStatus[] status_list -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Point.msg: -------------------------------------------------------------------------------- 1 | float64 x 2 | float64 y 3 | float64 z 4 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Point32.msg: -------------------------------------------------------------------------------- 1 | # This contains the position of a point in free space(with 32 bits of precision). 2 | # It is recommeded to use Point wherever possible instead of Point32. 3 | # 4 | # This recommendation is to promote interoperability. 5 | # 6 | # This message is designed to take up less space when sending 7 | # lots of points at once, as in the case of a PointCloud. 8 | 9 | float32 x 10 | float32 y 11 | float32 z -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Polygon.msg: -------------------------------------------------------------------------------- 1 | #A specification of a polygon where the first and last points are assumed to be connected 2 | Point32[] points 3 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/PolygonStamped.msg: -------------------------------------------------------------------------------- 1 | # This represents a Polygon with reference coordinate frame and timestamp 2 | Header header 3 | Polygon polygon 4 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Pose.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/Point position 2 | geometry_msgs/Quaternion orientation 3 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/PoseStamped.msg: -------------------------------------------------------------------------------- 1 | # A Pose with reference coordinate frame and timestamp 2 | Header header 3 | Pose pose 4 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/PoseWithCovariance.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/Pose pose 2 | float64[36] covariance 3 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/PoseWithCovarianceStamped.msg: -------------------------------------------------------------------------------- 1 | std_msgs/Header header 2 | geometry_msgs/PoseWithCovariance pose 3 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Quaternion.msg: -------------------------------------------------------------------------------- 1 | float64 x 2 | float64 y 3 | float64 z 4 | float64 w 5 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Transform.msg: -------------------------------------------------------------------------------- 1 | # This represents the transform between two coordinate frames in free space. 2 | 3 | Vector3 translation 4 | Quaternion rotation 5 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/TransformStamped.msg: -------------------------------------------------------------------------------- 1 | # This expresses a transform from coordinate frame header.frame_id 2 | # to the coordinate frame child_frame_id 3 | # 4 | # This message is mostly used by the 5 | # tf package. 6 | # See its documentation for more information. 7 | 8 | Header header 9 | string child_frame_id # the frame id of the child frame 10 | Transform transform -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Twist.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/Vector3 linear 2 | geometry_msgs/Vector3 angular 3 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/TwistWithCovariance.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/Twist twist 2 | float64[36] covariance 3 | -------------------------------------------------------------------------------- /src/ros_messages/geometry_msgs/Vector3.msg: -------------------------------------------------------------------------------- 1 | float64 x 2 | float64 y 3 | float64 z 4 | -------------------------------------------------------------------------------- /src/ros_messages/move_base_msgs/MoveBaseActionFeedback.msg: -------------------------------------------------------------------------------- 1 | std_msgs/Header header 2 | actionlib_msgs/GoalStatus status 3 | move_base_msgs/MoveBaseFeedback feedback -------------------------------------------------------------------------------- /src/ros_messages/move_base_msgs/MoveBaseActionGoal.msg: -------------------------------------------------------------------------------- 1 | Header header 2 | actionlib_msgs/GoalID goal_id 3 | MoveBaseGoal goal -------------------------------------------------------------------------------- /src/ros_messages/move_base_msgs/MoveBaseActionResult.msg: -------------------------------------------------------------------------------- 1 | std_msgs/Header header 2 | actionlib_msgs/GoalStatus status 3 | move_base_msgs/MoveBaseResult result -------------------------------------------------------------------------------- /src/ros_messages/move_base_msgs/MoveBaseFeedback.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/PoseStamped base_position -------------------------------------------------------------------------------- /src/ros_messages/move_base_msgs/MoveBaseGoal.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/PoseStamped target_pose -------------------------------------------------------------------------------- /src/ros_messages/move_base_msgs/MoveBaseResult.msg: -------------------------------------------------------------------------------- 1 | # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== -------------------------------------------------------------------------------- /src/ros_messages/move_base_msgs/RecoveryStatus.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/PoseStamped pose_stamped 2 | uint16 current_recovery_number 3 | uint16 total_number_of_recoveries 4 | string recovery_behavior_name -------------------------------------------------------------------------------- /src/ros_messages/nav_msgs/MapMetaData.msg: -------------------------------------------------------------------------------- 1 | # This hold basic information about the characterists of the OccupancyGrid 2 | 3 | # The time at which the map was loaded 4 | time map_load_time 5 | # The map resolution [m/cell] 6 | float32 resolution 7 | # Map width [cells] 8 | uint32 width 9 | # Map height [cells] 10 | uint32 height 11 | # The origin of the map [m, m, rad]. This is the real-world pose of the 12 | # cell (0,0) in the map. 13 | geometry_msgs/Pose origin -------------------------------------------------------------------------------- /src/ros_messages/nav_msgs/OccupancyGrid.msg: -------------------------------------------------------------------------------- 1 | # This represents a 2-D grid map, in which each cell represents the probability of 2 | # occupancy. 3 | 4 | Header header 5 | 6 | #MetaData for the map 7 | MapMetaData info 8 | 9 | # The map data, in row-major order, starting with (0,0). Occupancy 10 | # probabilities are in the range [0,100]. Unknown is -1. 11 | int8[] data 12 | -------------------------------------------------------------------------------- /src/ros_messages/nav_msgs/Odometry.msg: -------------------------------------------------------------------------------- 1 | # This represents an estimate of a position and velocity in free space. 2 | # The pose in this message should be specified in the coordinate frame given by header.frame_id. 3 | # The twist in this message should be specified in the coordinate frame given by the child_frame_id 4 | Header header 5 | string child_frame_id 6 | geometry_msgs/PoseWithCovariance pose 7 | geometry_msgs/TwistWithCovariance twist -------------------------------------------------------------------------------- /src/ros_messages/nav_msgs/Path.msg: -------------------------------------------------------------------------------- 1 | #An array of poses that represents a Path for a robot to follow 2 | Header header 3 | geometry_msgs/PoseStamped[] poses 4 | -------------------------------------------------------------------------------- /src/ros_messages/std_msgs/ColorRGBA.msg: -------------------------------------------------------------------------------- 1 | float32 r 2 | float32 g 3 | float32 b 4 | float32 a 5 | -------------------------------------------------------------------------------- /src/ros_messages/std_msgs/Header.msg: -------------------------------------------------------------------------------- 1 | uint32 seq 2 | time stamp 3 | string frame_id 4 | -------------------------------------------------------------------------------- /src/ros_messages/tf/tfMessage.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/TransformStamped[] transforms 2 | -------------------------------------------------------------------------------- /src/ros_messages/tf2_msgs/TFMessage.msg: -------------------------------------------------------------------------------- 1 | geometry_msgs/TransformStamped[] transforms -------------------------------------------------------------------------------- /src/ros_messages/visualization_msgs/MarkerArray.msg: -------------------------------------------------------------------------------- 1 | Marker[] markers -------------------------------------------------------------------------------- /src/tests/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2017 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | add_subdirectory(navigation2DClientSnippet) 8 | add_subdirectory(navigation2DClientTest) 9 | add_subdirectory(simpleVelocityNavigationTest1) 10 | add_subdirectory(simpleVelocityNavigationTest2) 11 | -------------------------------------------------------------------------------- /src/tests/navigation2DClientSnippet/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project(navigation2DClientSnippet) 2 | 3 | file(GLOB folder_source *.cpp) 4 | file(GLOB folder_header *.h) 5 | 6 | source_group("Source Files" FILES ${folder_source}) 7 | source_group("Header Files" FILES ${folder_header}) 8 | 9 | include_directories(${ICUB_INCLUDE_DIRS}) 10 | 11 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 12 | 13 | target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} navigation_lib) 14 | 15 | set_property(TARGET navigation2DClientSnippet PROPERTY FOLDER "Examples") 16 | 17 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 18 | -------------------------------------------------------------------------------- /src/tests/navigation2DClientTest/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project(navigation2DClientTest) 2 | 3 | file(GLOB folder_source *.cpp) 4 | file(GLOB folder_header *.h) 5 | 6 | source_group("Source Files" FILES ${folder_source}) 7 | source_group("Header Files" FILES ${folder_header}) 8 | 9 | include_directories(${ICUB_INCLUDE_DIRS}) 10 | 11 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 12 | 13 | target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} navigation_lib) 14 | 15 | set_property(TARGET navigation2DClientTest PROPERTY FOLDER "Tests") 16 | 17 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 18 | -------------------------------------------------------------------------------- /src/tests/simpleVelocityNavigationTest1/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project(simpleVelocityNavigationTest1) 2 | 3 | file(GLOB folder_source *.cpp) 4 | file(GLOB folder_header *.h) 5 | 6 | source_group("Source Files" FILES ${folder_source}) 7 | source_group("Header Files" FILES ${folder_header}) 8 | 9 | include_directories(${ICUB_INCLUDE_DIRS}) 10 | 11 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 12 | 13 | target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} navigation_lib) 14 | 15 | set_property(TARGET simpleVelocityNavigationTest1 PROPERTY FOLDER "Tests") 16 | 17 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 18 | -------------------------------------------------------------------------------- /src/tests/simpleVelocityNavigationTest1/main.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/src/tests/simpleVelocityNavigationTest1/main.cpp -------------------------------------------------------------------------------- /src/tests/simpleVelocityNavigationTest2/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project(simpleVelocityNavigationTest2) 2 | 3 | file(GLOB folder_source *.cpp) 4 | file(GLOB folder_header *.h) 5 | 6 | source_group("Source Files" FILES ${folder_source}) 7 | source_group("Header Files" FILES ${folder_header}) 8 | 9 | include_directories(${ICUB_INCLUDE_DIRS}) 10 | 11 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 12 | 13 | target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} navigation_lib) 14 | set_property(TARGET simpleVelocityNavigationTest2 PROPERTY FOLDER "Tests") 15 | 16 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 17 | -------------------------------------------------------------------------------- /src/tests/simpleVelocityNavigationTest2/main.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/src/tests/simpleVelocityNavigationTest2/main.cpp -------------------------------------------------------------------------------- /src/tutorials/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2017 iCub Facility - IIT Istituto Italiano di Tecnologia 3 | # Author: Marco Randazzo marco.randazzo@iit.it 4 | # CopyPolicy: Released under the terms of the GNU GPL v2.0. 5 | # 6 | 7 | add_subdirectory(robotPathPlannerExample) 8 | add_subdirectory(robotGotoExample) -------------------------------------------------------------------------------- /src/tutorials/robotGotoExample/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project(robotGotoExample) 2 | 3 | file(GLOB folder_source *.cpp) 4 | file(GLOB folder_header *.h) 5 | 6 | source_group("Source Files" FILES ${folder_source}) 7 | source_group("Header Files" FILES ${folder_header}) 8 | 9 | include_directories(${ICUB_INCLUDE_DIRS}) 10 | 11 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 12 | 13 | target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} navigation_lib) 14 | 15 | set_property(TARGET robotGotoExample PROPERTY FOLDER "Examples") 16 | 17 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 18 | -------------------------------------------------------------------------------- /src/tutorials/robotPathPlannerExample/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project(robotPathPlannerExample) 2 | 3 | file(GLOB folder_source *.cpp) 4 | file(GLOB folder_header *.h) 5 | 6 | source_group("Source Files" FILES ${folder_source}) 7 | source_group("Header Files" FILES ${folder_header}) 8 | 9 | include_directories(${ICUB_INCLUDE_DIRS}) 10 | 11 | add_executable(${PROJECT_NAME} ${folder_source} ${folder_header}) 12 | 13 | target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} navigation_lib) 14 | 15 | set_property(TARGET robotPathPlannerExample PROPERTY FOLDER "Examples") 16 | 17 | install(TARGETS ${PROJECT_NAME} DESTINATION bin) 18 | -------------------------------------------------------------------------------- /tests/YarpBuildLocation.h.in: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2006-2023 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef YARP_BUILD_LOCATION_H 7 | #define YARP_BUILD_LOCATION_H 8 | 9 | #cmakedefine CMAKE_BINARY_DIR "@CMAKE_NATIVE_BINARY_DIR@" 10 | #cmakedefine TEST_DATA_DIR "@TEST_DATA_DIR@" 11 | 12 | #endif 13 | -------------------------------------------------------------------------------- /tests/harness.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2023 Istituto Italiano di Tecnologia (IIT) 3 | * SPDX-License-Identifier: BSD-3-Clause 4 | */ 5 | 6 | #ifndef YARP_TESTS_HARNESS_H 7 | #define YARP_TESTS_HARNESS_H 8 | 9 | #if !defined(WITHOUT_NETWORK) 10 | # include 11 | #endif // WITHOUT_NETWORK 12 | 13 | #include 14 | #include 15 | 16 | void increment_tests_skipped(); 17 | 18 | #define YARP_SKIP_TEST(...) \ 19 | { \ 20 | increment_tests_skipped(); \ 21 | FAIL(__VA_ARGS__); \ 22 | } 23 | 24 | #if !defined(WITHOUT_NETWORK) 25 | #define YARP_REQUIRE_PLUGIN(name, type) \ 26 | { \ 27 | bool has_plugin = yarp::os::YarpPluginSelector::checkPlugin(name, type); \ 28 | if (!has_plugin) { \ 29 | YARP_SKIP_TEST("Required plugin is missing: " << type << " - " << name); \ 30 | } \ 31 | } 32 | #endif // WITHOUT_NETWORK 33 | 34 | #endif // YARP_TESTS_HARNESS_H 35 | -------------------------------------------------------------------------------- /tests/misc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # SPDX-FileCopyrightText: 2023 Istituto Italiano di Tecnologia (IIT) 2 | # SPDX-License-Identifier: BSD-3-Clause 3 | 4 | # The following tests are disabled because they are already individually executed by 5 | # Github CI, there is no need to perform them twice. 6 | if (0) 7 | find_package(Perl QUIET) 8 | if(PERL_FOUND AND NOT WIN32 AND IS_DIRECTORY "${CMAKE_SOURCE_DIR}/.git") 9 | add_test( 10 | NAME misc::check_style 11 | COMMAND "${PERL_EXECUTABLE}" "${CMAKE_CURRENT_SOURCE_DIR}/check_style.pl" 12 | WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}" 13 | ) 14 | 15 | add_test( 16 | NAME misc::check_license 17 | COMMAND "${PERL_EXECUTABLE}" "${CMAKE_CURRENT_SOURCE_DIR}/check_license.pl" 18 | WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}" 19 | ) 20 | endif() 21 | 22 | find_package(Python QUIET) 23 | if(PYTHON_FOUND AND NOT WIN32 AND IS_DIRECTORY "${CMAKE_SOURCE_DIR}/.git") 24 | add_test( 25 | NAME misc::check_tests 26 | COMMAND "${Python_EXECUTABLE}" "${CMAKE_CURRENT_SOURCE_DIR}/check_tests.py" 27 | WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}" 28 | ) 29 | endif() 30 | endif() 31 | -------------------------------------------------------------------------------- /tests/misc/check_style_skip.txt: -------------------------------------------------------------------------------- 1 | README.md 2 | -------------------------------------------------------------------------------- /tests/misc/check_tests.py: -------------------------------------------------------------------------------- 1 | # SPDX-FileCopyrightText: 2023-2023 Istituto Italiano di Tecnologia (IIT) 2 | # SPDX-License-Identifier: BSD-3-Clause 3 | 4 | import os 5 | import sys 6 | 7 | verbose = 0 8 | def check_subfolders(root_dir): 9 | non_compliant_folders = [] 10 | skip_folders = [] 11 | with open('./tests/misc/check_tests_skip.txt', 'r') as f: 12 | skip_folders = [folder.strip() for folder in f.readlines()] 13 | if (verbose): print(skip_folders) 14 | for dirpath, dirnames, filenames in os.walk(root_dir): 15 | if dirpath == root_dir: 16 | for dirname in dirnames: 17 | subfolder_path = os.path.join(dirpath, dirname, 'tests') 18 | if (verbose): print (subfolder_path, skip_folders) 19 | if os.path.join(dirpath, dirname) not in skip_folders: 20 | if not os.path.exists(subfolder_path): 21 | non_compliant_folders.append(os.path.join(dirpath, dirname)) 22 | else: 23 | if (verbose): print("Skipping folder:", os.path.join(dirpath, dirname)) 24 | return non_compliant_folders 25 | 26 | root_dir = './src/devices' 27 | 28 | non_compliant_folders = check_subfolders(root_dir) 29 | 30 | if non_compliant_folders: 31 | print("The following subfolders (",len(non_compliant_folders),") do not contain a 'tests' subfolder:") 32 | for folder in non_compliant_folders: 33 | print(folder) 34 | sys.exit(1) 35 | else: 36 | print("All subfolders contain a 'test' subfolder.") 37 | sys.exit(0) 38 | -------------------------------------------------------------------------------- /tests/misc/check_tests_skip.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/robotology/navigation/8468e4ee7998d7f27b95b9dec6b61345cdbcb169/tests/misc/check_tests_skip.txt --------------------------------------------------------------------------------