Walking Quadruped
Project Description and Learning Standards
This project uses two LEGO double motors from the CS Education & AI kits to build a quadruped. We then use reinforcement learning to train the quadruped to walk straight forward and turn back to walk straight when it veers.
This project is for students interested in more advanced machine learning and AI such as in higher-level high school classes, after-school robotics clubs and competitive robotics clubs, and college-level courses. It aligns with the following Computer Science teaching standards:
Likely alignment
- CSTA HS-ALG-ML-08 — Develop a machine learning model for a chosen task using appropriate data and tools.
- CSTA HS-ALG-PS-03 — Evaluate algorithms for efficiency, correctness, and clarity, using metrics or test cases. Training and evaluating whether the quadruped walks forward requires measurable performance tests.
- CSTA HS-PRO-PD-13 — Use documentation, libraries, APIs, and other tools in program development. The physical implementation uses the LEGO Education Python API.
Conditional alignment
- CSTA HS-ALG-ML-06 — Justify the selection of a type of AI algorithm to accomplish a task. Students need to compare reinforcement learning with a fixed gait or another control method.
- NGSS HS-ETS1-4 — Use a computer simulation to model the impact of proposed solutions to a complex real-world problem. This applies only if simulation is meaningfully used to test gait designs before deployment; hardware alone is not sufficient. NGSS explicitly recognizes computer simulation as an engineering-design tool.
Documentation and Instructions
Project Preview
This robot model uses LEGO technic parts from the SPIKE Prime kit for the legs and double motors from the CS Education & AI kits for the body/motors

.gif)
Behaviour Cloning Car
About the project
The project aims to have a simple-to-build LEGO robot (using the CS & AI kit) imitate the signature from a human demonstration. The hardware setup includes a LEGO pen (the data), a LEGO car with a pen-lifting mechanism (the robot), and the fixed overhead camera with a Aruco-tag paper placing on the table (the environment).
The same project goal is tested and experimented using three different methods: 1) Pure-pursuit control, 2) Behaviour cloning, 3) and PPO-reinforcement learning






