Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
364 changes: 364 additions & 0 deletions rmcs_ws/src/rmcs_bringup/config/deformable-infantry-omni.yaml
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,364 @@
rmcs_executor:
ros__parameters:
update_rate: 1000.0
components:
- rmcs_core::hardware::DeformableInfantryOmni -> deformable_infantry

- rmcs_core::referee::Status -> referee_status
- rmcs_core::referee::Command -> referee_command

- rmcs_core::referee::command::Interaction -> referee_interaction
- rmcs_core::referee::command::interaction::Ui -> referee_ui
- rmcs_core::referee::app::ui::Infantry -> referee_ui_infantry

- rmcs_core::controller::gimbal::DeformableInfantryGimbalController -> gimbal_controller

- rmcs_core::controller::shooting::FrictionWheelController -> friction_wheel_controller
- rmcs_core::controller::shooting::HeatController -> heat_controller
- rmcs_core::controller::shooting::BulletFeederController17mm -> bullet_feeder_controller
- rmcs_core::controller::pid::PidController -> left_friction_velocity_pid_controller
- rmcs_core::controller::pid::PidController -> right_friction_velocity_pid_controller
- rmcs_core::controller::pid::PidController -> bullet_feeder_velocity_pid_controller

- rmcs_core::controller::chassis::DeformableChassis -> chassis_controller
- rmcs_core::controller::chassis::ChassisPowerController -> chassis_power_controller
- rmcs_core::controller::chassis::DeformableOmniWheelController -> deformable_chassis_controller

- rmcs_core::controller::chassis::DeformableJointController -> lf_joint_controller
- rmcs_core::controller::chassis::DeformableJointController -> lb_joint_controller
- rmcs_core::controller::chassis::DeformableJointController -> rb_joint_controller
- rmcs_core::controller::chassis::DeformableJointController -> rf_joint_controller

- rmcs_core::broadcaster::ValueBroadcaster -> value_broadcaster
# - rmcs::AutoAimComponent -> auto_aim_component

value_broadcaster:
ros__parameters:
forward_list:
- /gimbal/yaw/angle
- /gimbal/yaw/velocity

deformable_infantry:
ros__parameters:
serial_filter_rmcs_board: "AF-73B2-E8A1-A544-79ED-5BDA-D088-7F21-A6A6"
serial_filter_top_board: "D4-0262-9E84-E715-CADB-9894-7241"
serial_filter_imu: "AF-8217-B05F-811B-6F3E-04EA-448E-9D03-CA2C"
left_front_zero_point: 374
left_back_zero_point: 5801
right_back_zero_point: 7817
right_front_zero_point: 7136
yaw_motor_zero_point: 50642
pitch_motor_zero_point: 6245
debug_log_supercap: false
debug_log_wheel_motor: false
debug_log_deformable_joint_motor: false

chassis_controller:
ros__parameters:
# Deploy geometry / chassis-owned joint intent
min_angle: 8.0
max_angle: 58.0
active_suspension_enable: true
spin_ratio: 1.0

# Suspension geometry / support model.
active_suspension_mass: 22.5
active_suspension_rod_length: 0.150
active_suspension_Kz: 150.0
active_suspension_D_leg: 10.0
active_suspension_torque_limit: 80.0
active_suspension_gravity_comp_gain: 1.0
active_suspension_control_acceleration_limit: 6.0
active_suspension_preload_angle_deg: 8.0
active_suspension_entry_offset_deg: 1.5
active_suspension_ride_height_offset_deg: 3.0
active_suspension_hold_travel_deg: 5.0
active_suspension_activation_velocity_threshold_deg: 15.0

# IMU attitude correction as suspension force bias.
active_suspension_pitch_kp: 8.0
active_suspension_pitch_ki: 0.35
active_suspension_pitch_kd: 0.28

active_suspension_roll_kp: 8.0
active_suspension_roll_ki: 0.35
active_suspension_roll_kd: 0.28

active_suspension_pitch_angle_diff_limit_deg: 45.0
active_suspension_roll_angle_diff_limit_deg: 45.0
active_suspension_pid_integral_limit_deg: 20.0

# Chassis-owned joint intent trajectory limits while attitude correction is active.
active_suspension_target_velocity_limit_deg: 80.0
active_suspension_target_acceleration_limit_deg: 360.0

# Automatic IMU mounting-error calibration.
# When all four requested joint targets stay equal for 2s, average pitch/roll from 2s to 5s.
chassis_imu_calibration_wait_s: 2.0
chassis_imu_calibration_sample_s: 3.0

gimbal_controller:
ros__parameters:
upper_limit: -0.61 # -35 deg
lower_limit: 0.05 # 6 deg

yaw_angle_kp: 30.0
yaw_angle_ki: 0.0
yaw_angle_kd: 0.0

yaw_velocity_kp: 15.0
yaw_velocity_ki: 0.0
yaw_velocity_kd: 0.0

yaw_vel_ff_gain: 0.47
yaw_acc_ff_gain: 0.00

pitch_angle_kp: 25.0
pitch_angle_ki: 0.0
pitch_angle_kd: 0.0

pitch_velocity_kp: 2.2
pitch_velocity_ki: 0.0
pitch_velocity_kd: 0.0

pitch_acc_ff_gain: 0.10

pitch_torque_control: true

pitch_fusion_enabled: true
pitch_fusion_alpha: 0.98

friction_wheel_controller:
ros__parameters:
friction_wheels:
- /gimbal/left_friction
- /gimbal/right_friction
friction_velocities:
- 600.0
- 600.0
friction_soft_start_stop_time: 1.0

heat_controller:
ros__parameters:
heat_per_shot: 10000
reserved_heat: 0
Comment thread
creeper5820 marked this conversation as resolved.

bullet_feeder_controller:
ros__parameters:
bullets_per_feeder_turn: 8.0
shot_frequency: 30.0
safe_shot_frequency: 10.0
eject_frequency: 10.0
eject_time: 0.05
deep_eject_frequency: 5.0
deep_eject_time: 0.2
single_shot_max_stop_delay: 2.0

left_friction_velocity_pid_controller:
ros__parameters:
measurement: /gimbal/left_friction/velocity
setpoint: /gimbal/left_friction/control_velocity
control: /gimbal/left_friction/control_torque
kp: 0.003436926
ki: 0.00
kd: 0.009373434

right_friction_velocity_pid_controller:
ros__parameters:
measurement: /gimbal/right_friction/velocity
setpoint: /gimbal/right_friction/control_velocity
control: /gimbal/right_friction/control_torque
kp: 0.003436926
ki: 0.00
kd: 0.009373434

bullet_feeder_velocity_pid_controller:
ros__parameters:
measurement: /gimbal/bullet_feeder/velocity
setpoint: /gimbal/bullet_feeder/control_velocity
control: /gimbal/bullet_feeder/control_torque
kp: 1.5
ki: 0.0
kd: 0.0

deformable_chassis_controller:
ros__parameters:
mass: 22.5
moment_of_inertia: 1.0
chassis_radius: 0.2341741
rod_length: 0.150
wheel_radius: 0.055
friction_coefficient: 66.6
k1: 2.958580e+00
k2: 3.082190e-03
no_load_power: 11.37

lf_joint_controller:
ros__parameters:
# Joint-local servo inputs produced by chassis intent generation
measurement_angle: /chassis/left_front_joint/physical_angle
measurement_velocity: /chassis/left_front_joint/physical_velocity
setpoint_angle: /chassis/left_front_joint/target_physical_angle
setpoint_velocity: /chassis/left_front_joint/target_physical_velocity
mode_input: /chassis/left_front_joint/suspension_mode
suspension_torque: /chassis/left_front_joint/suspension_torque
control: /chassis/left_front_joint/control_torque

# Normal ADRC servo mode
dt: 0.001
b0: -0.60
kt: 1.0
td_h: 0.001
td_r: 50.0
eso_w0: 250.0
eso_auto_beta: true
k1: 30.0
k2: 17.0
alpha1: 0.75
alpha2: 0.7
delta: 0.02
u_min: -200.0
u_max: 200.0
output_min: -200.0
output_max: 200.0

# Suspension ADRC servo mode
suspension_td_h: 0.001
suspension_td_r: 12.0
suspension_eso_w0: 80.0
suspension_k1: 6.0
suspension_k2: 3.0
suspension_alpha1: 0.75
suspension_alpha2: 0.7
suspension_delta: 0.02
suspension_u_min: -35.0
suspension_u_max: 35.0
suspension_output_min: -35.0
suspension_output_max: 35.0

# Joint-local feedforward / limit shaping
torque_feedforward_gain: 0.0
suspension_torque_feedforward_gain: -1.0

lb_joint_controller:
ros__parameters:
# Same joint-servo layout as lf_joint_controller
measurement_angle: /chassis/left_back_joint/physical_angle
measurement_velocity: /chassis/left_back_joint/physical_velocity
setpoint_angle: /chassis/left_back_joint/target_physical_angle
setpoint_velocity: /chassis/left_back_joint/target_physical_velocity
mode_input: /chassis/left_back_joint/suspension_mode
suspension_torque: /chassis/left_back_joint/suspension_torque
control: /chassis/left_back_joint/control_torque
dt: 0.001
b0: -0.60
kt: 1.0
td_h: 0.001
td_r: 50.0
eso_w0: 250.0
eso_auto_beta: true
k1: 30.0
k2: 17.0
alpha1: 0.75
alpha2: 0.7
delta: 0.02
u_min: -200.0
u_max: 200.0
output_min: -200.0
output_max: 200.0
suspension_td_h: 0.001
suspension_td_r: 12.0
suspension_eso_w0: 80.0
suspension_k1: 6.0
suspension_k2: 3.0
suspension_alpha1: 0.75
suspension_alpha2: 0.7
suspension_delta: 0.02
suspension_u_min: -35.0
suspension_u_max: 35.0
suspension_output_min: -35.0
suspension_output_max: 35.0
torque_feedforward_gain: 0.0
suspension_torque_feedforward_gain: -1.0

rb_joint_controller:
ros__parameters:
# Same joint-servo layout as lf_joint_controller
measurement_angle: /chassis/right_back_joint/physical_angle
measurement_velocity: /chassis/right_back_joint/physical_velocity
setpoint_angle: /chassis/right_back_joint/target_physical_angle
setpoint_velocity: /chassis/right_back_joint/target_physical_velocity
mode_input: /chassis/right_back_joint/suspension_mode
suspension_torque: /chassis/right_back_joint/suspension_torque
control: /chassis/right_back_joint/control_torque
dt: 0.001
b0: -0.60
kt: 1.0
td_h: 0.001
td_r: 50.0
eso_w0: 250.0
eso_auto_beta: true
k1: 30.0
k2: 17.0
alpha1: 0.75
alpha2: 0.7
delta: 0.02
u_min: -200.0
u_max: 200.0
output_min: -200.0
output_max: 200.0
suspension_td_h: 0.001
suspension_td_r: 12.0
suspension_eso_w0: 80.0
suspension_k1: 6.0
suspension_k2: 3.0
suspension_alpha1: 0.75
suspension_alpha2: 0.7
suspension_delta: 0.02
suspension_u_min: -35.0
suspension_u_max: 35.0
suspension_output_min: -35.0
suspension_output_max: 35.0
torque_feedforward_gain: 0.0
suspension_torque_feedforward_gain: -1.0

rf_joint_controller:
ros__parameters:
# Same joint-servo layout as lf_joint_controller
measurement_angle: /chassis/right_front_joint/physical_angle
measurement_velocity: /chassis/right_front_joint/physical_velocity
setpoint_angle: /chassis/right_front_joint/target_physical_angle
setpoint_velocity: /chassis/right_front_joint/target_physical_velocity
mode_input: /chassis/right_front_joint/suspension_mode
suspension_torque: /chassis/right_front_joint/suspension_torque
control: /chassis/right_front_joint/control_torque
dt: 0.001
b0: -0.60
kt: 1.0
td_h: 0.001
td_r: 50.0
eso_w0: 250.0
eso_auto_beta: true
k1: 30.0
k2: 17.0
alpha1: 0.75
alpha2: 0.7
delta: 0.02
u_min: -200.0
u_max: 200.0
output_min: -200.0
output_max: 200.0
suspension_td_h: 0.001
suspension_td_r: 12.0
suspension_eso_w0: 80.0
suspension_k1: 6.0
suspension_k2: 3.0
suspension_alpha1: 0.75
suspension_alpha2: 0.7
suspension_delta: 0.02
suspension_u_min: -35.0
suspension_u_max: 35.0
suspension_output_min: -35.0
suspension_output_max: 35.0
torque_feedforward_gain: 0.0
suspension_torque_feedforward_gain: -1.0
Loading