Skip to content

Compass Lab

Photo needed

We don't have a photo of this kit yet.

Adds a digital compass (HMC5883L/QMC5883L) so a robot knows which direction it is moving, which is useful for swarms of robots.

Source book: STEM Robots
Kit page: https://dmccreary.github.io/stem-robots/kits/compass-hmc5883l/
Printable one-pager: compass-hmc5883l-one-pager.html

Features

  • Uses the HMC5883L / QMC5883L Compass
  • Uses the Raspberry Pi Pico RP2040
  • Uses the SSD1306 128×64 OLED

Benefits

  • Free, open lessons: the STEM Robots textbook has the kit page, wiring, and MicroPython code.
  • Classroom friendly: built on a solderless breadboard or no-solder connectors.
  • Instant feedback: students see their code's results on lights or a display.
  • Real-world data: students read sensors and turn measurements into decisions.
  • Budget: about \(2–\)3 for the HMC5883L compass module on eBay (QMC5883L versions are \(5–\)8 in some listings); it is an add-on to a robot.

Parts

  • Raspberry Pi Pico ($4) — Microcontroller
  • HMC5883L / QMC5883L Compass — Sensor
  • SSD1306 128×64 OLED — Display
  • 830-Point Breadboard ($1.10) — Breadboard
  • Micro-USB Data Cable ($2.50) — Power and programming cable