SummerSLAM

Weeks 1-6

  • Weeks 1-2 - Build and Program the Rover
    • What I wanted to build
    • Part 1 - Build the hardware
      • Why I chose an X-drive
      • Start from a reference
      • Design the two plates
      • Plan the decks around the parts
      • Measure the real boards
      • Print with useful margin
      • Split the computing work
      • The timer mistake
      • Why I used CAN
      • Main parts
      • Battery and power
      • Full wiring reference
      • Two short-circuit accidents
    • Part 2 - Program the rover
      • How to read the repository
      • Configure STM32CubeMX
      • Build with CMake in VS Code
      • Flash with STM32CubeProgrammer
      • Finalize Dupont wiring, then draw the PCB
      • Make one motor turn
      • Read all four encoders
      • Test CAN on the Raspberry Pi
      • CAN and tool problems I found
      • Add the PS2 controller
      • Drive test
    • What worked at the end
    • Main lessons
    • Source index
  • Week 3 - X-Drive Kinematics and Encoder Odometry
    • From a moving rover to a motion estimate
    • How to read the repository
    • Define one coordinate frame first
    • Why the STM32 sends cumulative counts
    • Convert ticks into wheel velocity
    • Measure the real CPR
    • Keep map, sign, frame, and scale separate
      • Failure: the rear encoder channels were swapped
    • Calibrate encoder signs with one simple motion
      • Failure: reversed feedback caused PID runaway
    • Separate the physical model from the controller units
    • Derive forward kinematics
      • Why lateral motion and rotation are negated
      • Why translation is multiplied by \(\sqrt{2}\)
    • Integrate body motion into the world frame
    • Keep the estimator independent of ROS
    • Test one degree of freedom at a time
      • Failure: the heartbeat stop was overwritten
    • What Week 3 established
    • Reproduction procedure
    • Source index
  • Week 4 — Ground-Truth Calibration and Motion Uncertainty
    • From kinematics to measured motion
    • How to read the repository
    • The calibration constants
    • Measurement principle
    • Test setup
      • Surface
      • Speed
      • D-pad fine adjustment
    • What the early trials showed
    • Failure: the missing 45-degree projection
      • Symptom
      • Diagnosis
      • Correction
    • Failure: the coordinate frame was mirrored
      • Symptom
      • Diagnosis
      • Correction
    • Midpoint pose integration
    • Hardware yaw
    • Smoke test
    • Test one degree of freedom at a time
    • What Week 4 established
    • Reproduction procedure
    • Source index
  • Week 5 — Ultrasonic Sensing and Measurement Model
    • From dead reckoning to range sensing
    • How to read the repository
    • Part 1 — Hardware acquisition
      • Why HC-SR04
      • TIM9 input capture
      • State machine
      • Sequential ranging with a shared trigger
      • Input-capture ISR
      • Timeout handling
      • Pulse-to-distance conversion
      • CAN frame 0x202
      • RPi decode
      • ROS publication
    • Part 2 — Bench calibration
      • Procedure
      • Results
      • Noise model
      • Invalid readings
    • Part 3 — Probabilistic beam model
      • The four-component model
      • BeamModel constructor
      • Hit component: truncated Gaussian
      • Short component: exponential decay
      • Log-space mixture
      • Numerical helpers
    • Part 4 — Map and ray casting
      • Rectangular map
      • Ray casting
      • Sensor offsets
      • Multi-sensor scoring
    • Part 5 — Map validation
      • Procedure
      • Results
      • Likelihood discrimination test
      • Smoke test
    • Failure and limitation record
      • Invalid readings
      • Bias
      • Beam width and non-perpendicular incidence
      • Debug serial port removed
    • What Week 5 established
    • Reproduction procedure
    • Source index
  • Week 6 — Monte Carlo Localization
    • From range scoring to pose estimation
    • Prerequisites
    • How to read the repository
    • Particle state and initialization
      • The weighted pose estimate
    • Holonomic body-frame motion update
      • Why the textbook model does not fit
      • The predict method
      • The alpha parameters
      • The noise floor
    • Measurement update in log space
      • 1. Score each particle
      • 2. Handle None sensors
      • 3. Exponentiate safely
      • 4. Resample
    • Low-variance resampling
    • CSV logging and offline replay
      • The shared log format
      • Body-frame delta computation
      • Replay loop
      • GIF animation
    • Convergence test: MCL vs dead reckoning
      • The L-path test
      • Why MCL error is 2.3 cm instead of zero
      • The arc test
    • Limits of heading observability
      • The noise floor keeps the problem bounded
    • Design corrections
      • Holonomic motion model
      • Alpha parameter scaling
      • Noise floor necessity
    • Source and evidence
    • Verification state

Appendices

  • Reproduction Environment
    • Hardware and operating systems
    • Repository workflow
    • Build the notes locally
    • Deployment
  • CAN Protocol Reference
    • Identifier categories
    • Motor index contract
    • Sources
  • Calibration Data
    • Encoder and motion calibration
    • Ultrasonic calibration
    • Reproducibility rule
  • Safety and Debugging Index
    • Power and hardware safety
    • Firmware and transport
    • Motion and control
    • Sensing and localization
    • Documentation rule
SummerSLAM
  • Search


© Copyright 2026, Thomas Pan.

Built with Sphinx using a theme provided by Read the Docs.