osrf / rmf_core

Provides the centralized functions of RMF: scheduling, etc.
Apache License 2.0
102 stars 41 forks source link

How to fulfill the trajectory planning of robot or fleet #214

Closed Jason-Zhou1 closed 3 years ago

Jason-Zhou1 commented 3 years ago

Hi all,

I am a bit confused about how to fulfill the trajectory planning of the robot fleet. I have found two areas in the rmf_core relevant to planning work:

  1. rmf_core/rmf_traffic/src/rmf_traffic/agv/Planner.cpp
  2. rmf_core/rmf_fleet_adapter/src/rmf_fleet_adapter/jobs/Planning.cpp

May I know where the trajectory planning is executed? Which are the main functions to fulfill the planning procedure? Thanks!

mxgrey commented 3 years ago

rmf_core/rmf_traffic/src/rmf_traffic/agv/Planner.cpp

This file defines the functions of the rmf_traffic::agv::Planner class, which is part of the stable public API of the rmf_traffic library. This class is meant to be used by anyone interested in generating a traffic-schedule-compliant motion plan for an AGV.

rmf_core/rmf_fleet_adapter/src/rmf_fleet_adapter/jobs/Planning.cpp

This is an internal implementation file for the rmf_fleet_adapter library. It wraps the rmf_traffic::agv::Planner class with rxcpp so it can be used in a heavily multi-threaded parallelized plan solver. Nothing in this file is intended for public use; it is purely for implementing some features of the rmf_fleet_adapter library.

Which are the main functions to fulfill the planning procedure?

Can you elaborate on your goal? Are you trying to understand how the existing rmf_fleet_adapter library works, or are you trying to make your own fleet adapter from scratch (not using the rmf_fleet_adapter library) by working at the RMF message protocol layer?

I would strongly discourage trying to work at the RMF message protocol layer without having a comprehensive understanding of how all the layers work.

Instead I would suggest focusing on understanding how to use the rmf_fleet_adapter API to integrate with your fleet's API. If you focus on using the rmf_fleet_adapter API, then you don't really need answers to any of the questions you've been asking, because all of those details will be taken care of for you.

Jason-Zhou1 commented 3 years ago

Hi mxgrey, My goal is to understand how the rmf_core system works out the trajectory planning task. I try to understand how the existing rmf_fleet_adapter library works instead of making my own fleet adapter from scratch. Thanks a lot for your reply!