Decision Module  1.0
ICRA2020 AI Challenge Northwestern Polytechnical University Aoxiang Team Strategy Code
roborts_decision Namespace Reference

Classes

class  AbstractCommonStrategy
 
class  AttackAndSurvival
 
class  BehaviorNode
 Behavior tree base node. More...
 
class  BehaviorTestNode
 
class  BehaviorTree
 Behavior tree class to initialize and execute the whole tree. More...
 
class  Blackboard
 
class  BlackboardRaw
 
struct  BuffZoneStatus
 
class  CaptureBulletsMoveStrategy
 
class  CaptureEnemyBloodMoveStrategy
 
class  CaptureOurBloodStrategy
 
class  ChassisExecutor
 
class  CompositeNode
 Behavior tree composite node inherited from BehaviorNode. More...
 
class  ControllerConfig
 
class  data
 
class  DecisionConfig
 
class  EnemyRobot
 
class  EscapeConstraint
 
class  ExploreMoveStrategy
 
class  Field
 
class  GimbalContrl
 The class can make a transformation: the 3D position of enemy --> pitch,yaw angle of gimbal. For more derails, see projectile_model.pdf TODO: add enemy motion estimation. More...
 
class  GimbalExecutor
 
class  KeepDirectionAttackMoveStrategy
 
class  KeepDirectionDefenseMoveStrategy
 
class  MultiRobot
 
class  MyRobot
 
class  ParallelNode
 Behavior tree parallel node inherited from CompositeNode. More...
 
class  PID_Controller
 
class  Point
 
struct  PointValue
 
class  PredictionSystem
 
class  SearchConstraint
 
class  SelectorNode
 Behavior tree selector node inherited from CompositeNode. More...
 
struct  StaticDescriptorInitializer_controller_2eproto
 
struct  StaticDescriptorInitializer_decision_2eproto
 
class  StopMove
 
class  StopShootStrategy
 
class  StrategyExecute
 
class  ToBetterOppShootStrategy
 
class  ToWorseOppShootStrategy
 
class  TwoRobortsChase
 
class  WaitForEnemySupplyArea
 
class  WhirlVel
 

Enumerations

enum  BehaviorType {
  BehaviorType::PARALLEL, BehaviorType::SELECTOR, BehaviorType::SEQUENCE, BehaviorType::ACTION,
  BehaviorType::PRECONDITION
}
 Type of behavior tree node. More...
 
enum  BehaviorState { BehaviorState::RUNNING, BehaviorState::SUCCESS, BehaviorState::FAILURE, BehaviorState::IDLE }
 Behavior state. More...
 
enum  Posture { Posture::TILTANGLE, Posture::TWIST }
 
enum  MyRobotBehavior { CHASE, ESCAPE, GOAL, SUPPLY }
 
enum  ArmorId { FRONT = 0, RIGHT = 1, BACK = 2, LEFT = 3 }
 
enum  BuffStatus {
  RED_RESTORATION = 1, RED_PROJECTILE_SUPPLIER = 2, BLUE_RESTORATION = 3, BLUE_PROJECTILE_SUPPLIER = 4,
  NO_SHOOTING = 5, NO_MOVING = 6, UNKNOWN_STATUS = 7
}
 
enum  EnemyBuffZone { PROJECTILE_SUPPLIER, RESTORATION }
 
enum  RobotType {
  RED_1 = 3, RED_2 = 4, BLUE_1 = 13, BLUE_2 = 14,
  UNKNOWN_TYPE
}
 
enum  RobotId { MY_ROBOT_1 = 0, MY_ROBOT_2 = 1, ENEMY_ROBOT_1 = 2, ENEMY_ROBOT_2 = 3 }
 
enum  MyColor { RED, BLUE, UNKNOWN_COLOR }
 
enum  Decision { OFFENSIVE }
 
enum  RobotBehavior {
  RobotBehavior::SPIN_FORWARD, RobotBehavior::SPIN_IN_PLACE, RobotBehavior::STAY_STILL, RobotBehavior::KEEP_DIRECTION_MOVE,
  RobotBehavior::SET_GIMBAL_ODOM_POSE, RobotBehavior::SHOOT_AIMED, RobotBehavior::TOWARD_W_POS_SHOOT
}
 Basic action of robot. More...
 
enum  Signal { Signal::NONE, Signal::HELP }
 Signal for interaction between robot. More...
 
enum  StrategyID {
  StrategyID::stopMove, StrategyID::keepDirectionAttackMove, StrategyID::keepDirectionDefendMove, StrategyID::captureHomeBloodMove,
  StrategyID::captureEnemyBloodMove, StrategyID::captureBulletsMove, StrategyID::exploreMove, StrategyID::stopShoot,
  StrategyID::toBetterOppShoot, StrategyID::toWorseOppShoot
}
 

Functions

void protobuf_AssignDesc_controller_2eproto ()
 
void protobuf_ShutdownFile_controller_2eproto ()
 
void protobuf_AddDesc_controller_2eproto ()
 
void protobuf_AssignDesc_decision_2eproto ()
 
void protobuf_ShutdownFile_decision_2eproto ()
 
void protobuf_AddDesc_decision_2eproto ()
 

Variables

const double PI = 3.1415926535
 
const float GRAVITY = 9.78
 
struct roborts_decision::StaticDescriptorInitializer_controller_2eproto static_descriptor_initializer_controller_2eproto_
 
struct roborts_decision::StaticDescriptorInitializer_decision_2eproto static_descriptor_initializer_decision_2eproto_
 

Detailed Description

Prediction system: responsible for predicting all enemy and our robot information

选取合适的点

  1. 射击分打强的和不强的,跑应与此有对应(
  2. 跑分为防御跑点和进攻跑点(依据障碍物防御或避开障碍物进攻)
  3. 跑点应考虑与自身位置的关系(从自身出发的扩展树或遗产算法)
  4. 跑点应考虑同伴(优先分散)

Enumeration Type Documentation

◆ ArmorId

Enumerator
FRONT 
RIGHT 
BACK 
LEFT 

◆ BehaviorState

Behavior state.

Enumerator
RUNNING 

Running state in process.

SUCCESS 

Success state as result.

FAILURE 

Failure state as result.

IDLE 

Idle state, state as default or after cancellation.

◆ BehaviorType

Type of behavior tree node.

Enumerator
PARALLEL 

Parallel Composite Node.

SELECTOR 

Selector Composite Node.

SEQUENCE 

Sequence Composite Node.

ACTION 

Action Node.

PRECONDITION 

Precondition Node.

◆ BuffStatus

Enumerator
RED_RESTORATION 
RED_PROJECTILE_SUPPLIER 
BLUE_RESTORATION 
BLUE_PROJECTILE_SUPPLIER 
NO_SHOOTING 
NO_MOVING 
UNKNOWN_STATUS 

◆ Decision

Enumerator
OFFENSIVE 

◆ EnemyBuffZone

Enumerator
PROJECTILE_SUPPLIER 
RESTORATION 

◆ MyColor

Enumerator
RED 
BLUE 
UNKNOWN_COLOR 

◆ MyRobotBehavior

Enumerator
CHASE 
ESCAPE 
GOAL 
SUPPLY 

◆ Posture

当前机器人的位姿

Enumerator
TILTANGLE 

以固定角度跑位,包括倾斜一定角度,或者没有倾斜

TWIST 

在进行旋转跑位

◆ RobotBehavior

Basic action of robot.

Enumerator
SPIN_FORWARD 
SPIN_IN_PLACE 
STAY_STILL 
KEEP_DIRECTION_MOVE 
SET_GIMBAL_ODOM_POSE 
SHOOT_AIMED 
TOWARD_W_POS_SHOOT 

◆ RobotId

Enumerator
MY_ROBOT_1 
MY_ROBOT_2 
ENEMY_ROBOT_1 
ENEMY_ROBOT_2 

◆ RobotType

Enumerator
RED_1 
RED_2 
BLUE_1 
BLUE_2 
UNKNOWN_TYPE 

◆ Signal

Signal for interaction between robot.

Enumerator
NONE 
HELP 

◆ StrategyID

The id of Strategy. One Id corresponds to one class.

Enumerator
stopMove 
keepDirectionAttackMove 
keepDirectionDefendMove 
captureHomeBloodMove 
captureEnemyBloodMove 
captureBulletsMove 
exploreMove 
stopShoot 
toBetterOppShoot 
toWorseOppShoot 

Function Documentation

◆ protobuf_AddDesc_controller_2eproto()

void roborts_decision::protobuf_AddDesc_controller_2eproto ( )

◆ protobuf_AddDesc_decision_2eproto()

void roborts_decision::protobuf_AddDesc_decision_2eproto ( )

◆ protobuf_AssignDesc_controller_2eproto()

void roborts_decision::protobuf_AssignDesc_controller_2eproto ( )

◆ protobuf_AssignDesc_decision_2eproto()

void roborts_decision::protobuf_AssignDesc_decision_2eproto ( )

◆ protobuf_ShutdownFile_controller_2eproto()

void roborts_decision::protobuf_ShutdownFile_controller_2eproto ( )

◆ protobuf_ShutdownFile_decision_2eproto()

void roborts_decision::protobuf_ShutdownFile_decision_2eproto ( )

Variable Documentation

◆ GRAVITY

const float roborts_decision::GRAVITY = 9.78

◆ PI

const double roborts_decision::PI = 3.1415926535

◆ static_descriptor_initializer_controller_2eproto_

struct roborts_decision::StaticDescriptorInitializer_controller_2eproto roborts_decision::static_descriptor_initializer_controller_2eproto_

◆ static_descriptor_initializer_decision_2eproto_

struct roborts_decision::StaticDescriptorInitializer_decision_2eproto roborts_decision::static_descriptor_initializer_decision_2eproto_