Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add complex_recovery package #1597

Open
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

sktometometo
Copy link
Contributor

@sktometometo sktometometo commented Sep 14, 2022

Add complex_recovery package which provides SequentialComplexRecovery and ParallelComplexRecovery plugins.

complex_recovery

This package provides recovery behavior plugins which combines multi recoveries to one recovery behavior.
This is useful for assuring a set of recovery behavior to run at one time.

There are two types of recoveries. One is to run multi recoveries sequentially and another is to run them in parallel.

complex_recovery_diagrams

complex_recovery/SequentialComplexRecovery

  • ~recovery_behaviors (list of dictionaries which has name and type entries, default: None)

Example configuration of move_base is like

recovery_behavior_enabled: true
recovery_behaviors:
  - name: "speak_then_clear_costmap0"
    type: "complex_recovery/SequentialComplexRecovery"
speak_then_clear_costmap0:
  recovery_behaviors:
    - name: "speak_and_wait0"
      type: "speak_and_wait_recovery/SpeakAndWaitRecovery"
    - name: "clear_costmap0"
      type: "clear_costmap_recovery/ClearCostmapRecovery"
  speak_and_wait0:
    speak_text: "I'm clearing costmap."
    duration_wait: 5.0
    duration_timeout: 1.0
    sound_action: /sound_play
  clear_costmap0:
    reset_distance: 1.0

In this case, speak_and_clear_costmap0 recovery runs speak_and_wait0 recovery first, then runs clear_costmap0.
So a robot speaks first and then clear its costmap.

complex_recovery/ParallelComplexRecovery

  • ~recovery_behaviors (list of dictionaries which has name and type entries, default: None)

Example configuration of move_base is like

recovery_behavior_enabled: true
recovery_behaviors:
  - name: "speak_and_rotate_costmap0"
    type: "complex_recovery/SequentialComplexRecovery"
speak_and_rotate_costmap0:
  recovery_behaviors:
    - name: "speak_and_wait0"
      type: "speak_and_wait_recovery/SpeakAndWaitRecovery"
    - name: "rotate0"
      type: "rotate_recovery/RotateRecovery"
  speak_and_wait0:
    speak_text: "I'm rotating."
    duration_wait: 5.0
    duration_timeout: 1.0
    sound_action: /sound_play
  rotate0:
    sim_granularity: 0.017
    frequency: 20.0

In this case, speak_and_rotate_costmap0 recovery runs speak_and_wait0 and rotate0 simultaneously.
So a robot speaks during its rotation.

TODO

  • Add test
  • Update meta information

@sktometometo sktometometo changed the title [WIP] Add complex_recovery package Add complex_recovery package Sep 14, 2022
@sktometometo sktometometo marked this pull request as ready for review September 14, 2022 09:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant