diff --git a/README.md b/README.md index edb6e83ad908d17b28786544da45d3e204f01fe7..2f845e2449a6bf1e42d7872d8890a0868dfb5b2a 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,51 @@ # Description +This project is intended to be used as a base class for ROS behavior tree clients. + +It provides: +* Two internal variables to enable a behavior that allows the user to start, and stop the BT execution. +* A **start_tree** and **stop_tree** function to allow the control of that varibles from C++. +* A set of basic BT nodes. These BT nodes are: + * **NOP**: Async Action node that does nothing. + * **is_start_tree**: Condition to know if internal start variable is set to true. + * **async_is_start_tree**: Async function equal to *is_start_tree* but returning RUNNING instead of FAILURE. + * **is_not_stop_tree**: Condition to know if internal stop variable is set to false. + * **async_is_not_stop_tree**: Async function equal to *is_not_stop_tree* but returning RUNNING instead of FAILURE. + * **set_start_tree**: Sync Action to set internal start variable. + * **set_stop_tree**: Sync Action to set internal stop variable. + * **reset_start_tree**: Sync Action to unset internal start variable. + * **reset_stop_tree**: Sync Action to unset internal stop variable. +* A init function to register these BT nodes. +* A set of Dynamic reconfigure checkbox to enable/disable all loggers. +* A set of ros parameters to set the BT file to be executed. + +TODO: Add BT example with start/stop/restart structure. + # ROS Interface +### Service servers +- *~/set_parameters* ([dynamic_reconfigure/Reconfigure.srv](http://docs.ros.org/melodic/api/dynamic_reconfigure/html/srv/Reconfigure.html)): + Service to dynamically change the parameters of the node. Only the parameters defined in the .cfg file can be modified this way. + +### topic publishers +- */diagnostics* ([diagnostic_msgs/DiagnosticArray](http://docs.ros.org/api/diagnostic_msgs/html/msg/DiagnosticArray.html)): + Topic with all the diagnostics published by the node. + +### Parameters +- **bt_client_rate** *(double; Default: 10.0; Max: 1000.0; Min: 0.1)*: The Tick rate. +- **path** *(String)*: The BT trees' folder path. +- **tree_xml_file** *(String)*: The BT tree xml file's name without extension. +- **bt_client_enable_cout_logger** *(Bool; Default: false)*: Enables cout_ ogger. +- **bt_client_enable_minitrace_logger** *(Bool; Default: false)*: Enables minitrace logger. +- **bt_client_enable_file_logger** *(Bool; Default: false)*: Enables file logger. +- **bt_client_enable_zmq_publisher** *(Bool; Default: false)*: Enables ZMQ publisher. +- **START** *(Bool; Default: false)*: Intendet to be used to start the tree execution. +- **STOP** *(Bool; Default: false)*: Intendet to be used to stop the tree execution. + # Dependencies -This base node has no dependencies. + +- [behaviortree_cpp_v3](https://github.com/BehaviorTree/BehaviorTree.CPP) +- [iri_behaviortree](https://gitlab.iri.upc.edu/labrobotica/ros/iri_core/iri_behaviortree) # How to use it