Mecanum Webots via Supervisor kinematic injection
Replace the failing ODE-rolled mecanum chassis dynamics with a Supervisor.setVelocity call that uses the gym mecanum forward kinematics formula directly. Wheel motors still spin (visual); chassis motion comes from the gym model so training and deployment match by construction. Results (seed=42, n=10 sheep): BC + RL mecanum pen 10/10 in both field and field_round. n=5 mecanum cells still 0/5 due to tracker phantoms anchored to wall corners under the 360° LiDAR — documented in docs/status.md as the remaining gap. Cleanup: drop deploy-time hacks (HERDING_HEADING_*, HERDING_OMEGA_CLAMP, HERDING_TRACKER_*) that were workarounds for the old ODE chaos; revert the proto inertiaMatrix, roller dampingConstant, and reduced motor torque since they no longer carry load; refresh comments around the mecanum config presets.
This commit is contained in:
@@ -9,7 +9,7 @@ PROTO ShepherdDogMecanum [
|
||||
field SFString controller "shepherd_dog"
|
||||
field MFString controllerArgs []
|
||||
field SFString customData ""
|
||||
field SFBool supervisor FALSE
|
||||
field SFBool supervisor TRUE
|
||||
field SFBool synchronization TRUE
|
||||
]
|
||||
{
|
||||
@@ -1993,6 +1993,7 @@ PROTO ShepherdDogMecanum [
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
# ========== IMU SENSORS ==========
|
||||
Accelerometer {
|
||||
translation 0 0 0.10
|
||||
@@ -2052,6 +2053,10 @@ PROTO ShepherdDogMecanum [
|
||||
}
|
||||
|
||||
# ========== PHYSICS ==========
|
||||
# Chassis dynamics are not exercised in herding runs — the
|
||||
# controller drives the body kinematically via Supervisor
|
||||
# setVelocity (see drive_mecanum in controllers/shepherd_dog).
|
||||
# Webots-derived inertia from the bounding box is sufficient.
|
||||
physics Physics {
|
||||
density -1
|
||||
mass 5.0
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user