|
Daedalus (PY2026)
Codebase for the Husky Robotics 2025-2026 rover Daedalus
|
Variables | |
| const double | ROBOT_LENGTH = 1.0 |
| const double | ROBOT_WIDTH = 1.0 |
| const double | WHEEL_BASE = 2. / 3. |
| Distance between left and right wheels. | |
| const double | EFF_WHEEL_BASE = 1.40 |
| Effective distance between wheels. | |
| const double | WHEEL_RADIUS = 0.15 |
| const double | PWM_PER_RAD_PER_SEC = 5000 |
| const double | MAX_DRIVE_PWM = 25000 |
| Can be up to 2^15 - 1 (32767), but we have limited it because driving at full speed draws a massive amount of current that's too much for our power supply (and full speed is hard to control anyway) | |
| const double | MAX_WHEEL_VEL = WHEEL_RADIUS * MAX_DRIVE_PWM / PWM_PER_RAD_PER_SEC |
| Maximum tangential velocity for the rover's wheels. | |
| const double | MAX_DTHETA |
| Maximum angular velocity (i.e. | |
| const double | STEER_EPSILON = 10000 |
| Represents the allowable error in millidegrees for steer motors to still process a drive request. | |
Drive constants.
| const double Constants::Drive::EFF_WHEEL_BASE = 1.40 |
Effective distance between wheels.
Tweaked so that actual rover angular rate roughly matches the commanded angular rate, based on 2-wheel kinematic model.
| const double Constants::Drive::MAX_DTHETA |
Maximum angular velocity (i.e.
dtheta in setCmdVel()) of the rover.
Computed assuming that the left wheel is going at full speed backwards while the right wheel is going at full speed forwards.
| const double Constants::Drive::MAX_WHEEL_VEL = WHEEL_RADIUS * MAX_DRIVE_PWM / PWM_PER_RAD_PER_SEC |
Maximum tangential velocity for the rover's wheels.
If the rover is driving straight and not turning, this is the maximum forward velocity (i.e. dx in setCmdVel()) of the rover.
| const double Constants::Drive::STEER_EPSILON = 10000 |
Represents the allowable error in millidegrees for steer motors to still process a drive request.
That is, we make sure all the wheels are close enough to their target rotation before actually driving.