Skip to content

Penny#3

A low-budget three-servo hexapod robot that walks, dances and avoids obstacles using infrared proximity sensors.

  • Other
  • Open source
  • 3D printable

Suggested by Robotheca, created by @ssloy (opens in a new tab), from github.com/ssloy/penny (opens in a new tab). Pinned to commit 0526dc4 (opens in a new tab).

Photo and 3D model

Penny#3, photo from its repository
Photo:@ssloy (opens in a new tab)WTFPLsource file (opens in a new tab)

3D preview converted from github.com/ssloy/penny at 0526dc4, under WTFPL. View the original files from GitHub (4.5 MB) (opens in a new tab)

What it can do

Written by Robotheca from the project's documents.

  • Walks as a three-servo hexapod using a repeating four-step gait sequence
  • Moves forward, backward, and turns left or right depending on obstacle detection
  • Detects nearby obstacles with two infrared proximity sensors and avoids them
  • Servo movement planned as constant-speed linear interpolation between keyframes
  • Low-cost build, roughly ten dollars in parts, intended as a weekend project

Bill of materials

This repository has no parts list Robotheca can read yet.

Build guide

The creator's steps, each with its instructions.

  1. 1Order the bill of materials and etch or order the motherboard
  2. 2Print the body parts and assemble the legs with M3 nylon screws
  3. 3Solder the ATMega8 microcontroller and flash it
  4. 4Assemble the infrared proximity sensor eyes
  5. 5Attach the servos and battery holder and flash the firmware

The guide appears here as you scroll.

Guide by @ssloy (README.md), under WTFPL.

Wiring and electronics

Notes written by Robotheca from the project's documents.

Main parts

  • ATMega8A-AU microcontroller (QFP-32) as the controller
  • Three SG90 9g micro servos for leg movement
  • Two infrared LEDs and two phototransistors as proximity sensors, with 2N3904 transistors
  • Four AAA battery holder as the power source
  • Designed by Dennis van Elteren, the motherboard uses the same basic schematic as Penny

Connections

  • Two servos are driven from the 16-bit timer1 PWM outputs (OCR1A and OCR1B)
  • The center servo is driven from the 8-bit timer2 via a one-shot pulse re-armed at each timer1 capture interrupt
  • Proximity sensor phototransistor outputs are read through ADC channels 4 and 5
  • Infrared LEDs are powered through a series resistor R6, which sets their current; the value may need adjusting
  • Phototransistor collector voltage drops when reflected infrared light is detected, with a closer object giving a stronger signal