Overview

The Kiwi swerve drivetrain project focuses on creating a low-power, affordable, and easy-to-maintain omnidirectional drive system that can be used in both robotics competitions and real-world robotic applications. By using three modules instead of four, continuous-rotation servos with encoders for smooth steering, and general-purpose mechanical components, the design significantly reduces cost and complexity without sacrificing performance. A custom electronics stack and Python-based control system handle all motion and feedback, allowing software to replace expensive hardware solutions. This project demonstrates how thoughtful mechanical design combined with strong software control can produce a practical, efficient, and accessible swerve drivetrain while also serving as a platform for teaching robotics design and programming.

This project is still being worked on

First Prototype

Build

The Kiwi swerve prototype was designed to reduce cost and complexity while maintaining reliable and smooth performance. To keep the system affordable, the modules use general-purpose gears and bearings instead of specialty or competition-specific components. All of the generic parts are found on amazon or servo city making the pods easier to replace and significantly cheaper. This makes the drivetrain more practical for long-term use. The structure combines 3D printed parts, CNCed plates with standard hardware.

Each module uses a continuous-rotation (CR) servo for steering, paired with an encoder attached to the servo. Instead of relying on a positional servo, the encoder provides precise angle feedback, allowing the servo to be controlled through software. This setup enables cleaner, smoother, and more consistent steering movements, since motion is continuously corrected rather than snapping to preset positions. This servo is connected to the pod itself using a HTD5 belt to turn the system.

For the drive motor a HTD2 belt is used to connect the motor to the pod. It is longer, lighter, and more cost-effective than the HTD5 rotation belt of the same length. This is done to allow for the servo and motor to be stationary while the pod moves freely. This combination balances durability where it matters most with lower cost and efficiency where high strength is not required.

Electronics

The drivetrain is controlled using a custom electronics setup centered around a Raspberry Pi. Each drive motor is powered by a 10-amp motor driver, while steering is handled through a servo HAT. A 12-bit encoder board provides accurate steering angle feedback for each module, enabling closed-loop control. Using generic electronics instead of competition-specific systems helped reduce cost and made the drivetrain easier to maintain and modify.

Programming

All control software for the Kiwi swerve drivetrain was written in Python and runs on a Raspberry Pi. The code handles Kiwi swerve kinematics, converting driver or autonomous commands into smooth, coordinated motion across all three modules. Because the drivetrain relies on continuous-rotation servos for steering, the software plays a major role in maintaining accuracy and stability.

Steering is controlled using a closed-loop system, where encoder feedback is constantly compared to the target angle and corrected in real time. This allows the CR servos to rotate smoothly to the desired position instead of snapping or overshooting, resulting in cleaner and more predictable movement. The software also manages synchronization between steering and drive motors, ensuring the modules stay aligned during motion while minimizing unnecessary power draw. This approach makes the drivetrain highly flexible, easy to tune, and well-suited for both competition use and teaching students how software-driven control can replace mechanical complexity.