This repository has been archived by the owner on Jan 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
63 changed files
with
412 additions
and
2,587 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
# bitbots_behavior | ||
|
||
This is the behavior code of the RoboCup Humanoid League team Hamburg Bit-Bots. | ||
It is divided into a behavior for the head and the body. | ||
Both are programmed using the dynamic_stack_decider package (https://github.com/bit-bots/dynamic_stack_decider). | ||
|
||
It is build using the dynamic_stack_decider framework (https://github.com/bit-bots/dynamic_stack_decider). |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,35 @@ | ||
from typing import Optional | ||
|
||
from bitbots_blackboard.capsules.animation_capsule import AnimationCapsule | ||
from bitbots_blackboard.capsules.blackboard_capsule import BlackboardCapsule | ||
from bitbots_blackboard.capsules.misc_capsule import MiscCapsule | ||
from bitbots_blackboard.capsules.game_status_capsule import GameStatusCapsule | ||
from bitbots_blackboard.capsules.kick_capsule import KickCapsule | ||
from bitbots_blackboard.capsules.pathfinding_capsule import PathfindingCapsule | ||
from bitbots_blackboard.capsules.team_data_capsule import TeamDataCapsule | ||
from bitbots_blackboard.capsules.world_model_capsule import WorldModelCapsule | ||
from bitbots_blackboard.capsules.costmap_capsule import CostmapCapsule | ||
from bitbots_utils.utils import get_parameter_dict | ||
from rclpy.action import ActionClient | ||
from rclpy.node import Node | ||
import tf2_ros as tf2 | ||
from rclpy.publisher import Publisher | ||
|
||
|
||
class BodyBlackboard: | ||
def __init__(self, node: Node, tf_buffer: tf2.Buffer): | ||
# References | ||
self.node = node | ||
self.tf_buffer = tf_buffer | ||
|
||
# Config | ||
self.config = get_parameter_dict(node, "body") | ||
self.base_footprint_frame: str = self.node.get_parameter("base_footprint_frame").value | ||
self.map_frame: str = self.node.get_parameter("map_frame").value | ||
self.odom_frame: str = self.node.get_parameter("odom_frame").value | ||
self.in_sim: bool = self.node.get_parameter("use_sim_time").value | ||
self.blackboard = BlackboardCapsule(node) | ||
|
||
# Capsules | ||
self.misc = MiscCapsule(node) | ||
self.gamestate = GameStatusCapsule(node) | ||
self.animation = AnimationCapsule(node) | ||
self.kick = KickCapsule(self) | ||
self.world_model = WorldModelCapsule(self) | ||
self.costmap = CostmapCapsule(self) | ||
self.pathfinding = PathfindingCapsule(self, node) | ||
self.team_data = TeamDataCapsule(node) | ||
self.goalie_arms_animation: str = self.node.get_parameter("Animations.Goalie.goalieArms").value | ||
self.goalie_falling_right_animation: str = self.node.get_parameter("Animations.Goalie.fallRight").value | ||
self.goalie_falling_left_animation: str = self.node.get_parameter("Animations.Goalie.fallLeft").value | ||
self.goalie_falling_center_animation: str = self.node.get_parameter("Animations.Goalie.fallCenter").value | ||
self.cheering_animation: str = self.node.get_parameter("Animations.Misc.cheering").value | ||
self.init_animation: str = self.node.get_parameter("Animations.Misc.init").value | ||
|
||
self.dynup_action_client: Optional[ActionClient] = None | ||
self.dynup_cancel_pub: Optional[Publisher] = None | ||
self.hcm_deactivate_pub: Optional[Publisher] = None | ||
|
||
self.lookat_action_client: Optional[ActionClient] = None |
23 changes: 21 additions & 2 deletions
23
bitbots_blackboard/bitbots_blackboard/capsules/animation_capsule.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
bitbots_blackboard/bitbots_blackboard/capsules/kick_capsule.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.