Arduino library for generating all the quadruped movements for controlling a mePed robot V2 with 8 servos.
It also controls the optional IR receiver and NeoPixels.
Available as QuadrupedControl example of the Arduino library ServoEasing.
- Smooth movements due to the use of Servo easing library for Arduino.
- Demo mode after initial timeout.
- Predefined complex movements like twist, wave and dance.
- Complete control by a simple IR remote from an Arduino IR set.
- Speed, direction and height can be controlled independent by the remote.
- If EEPROM existent -which is true for AVR CPU's- the servos inital positions can be calibrated and stored by the IR remote.
- Can be extended with Buzzer, NeoPixel strips and a US distance sensor.
mePed V2 demo mode | Another implementation |
---|---|
For lifting the legs, the lift servos just use the ServoEasing easing type EASE_QUADRATIC_BOUNCING.
A very simple and easy to understand version of controlling a mePed can be found here
- Install ServoEasing library with Tools > Manage Libraries... or Ctrl+Shift+I. Use "ServoEasing" as filter string.
- Open the example QuadrupedControl, available at File > Examples > Examples from Custom Libraries / ServoEasing.
To customize the software to different requirements, there are some compile options / macros available.
Modify them by enabling / disabling them in the file QuadrupedConfiguration.h, or change the values if applicable.
Name | Default value | Description |
---|---|---|
QUADRUPED_HAS_IR_CONTROL |
disabled | IR remote control is enabled. |
IR_RECEIVE_PIN |
A0 | Pin for IR remote control sensor. |
PIN_BUZZER |
3 | Pin for buzzer / piezo. |
QUADRUPED_HAS_NEOPIXEL |
disabled | NeoPattern animations on a 24 pieces Neopixel strip handled logically as 3 8 pieces strips is enabled. |
QUADRUPED_HAS_US_DISTANCE |
disabled | US distance sensor at pin A3 + A4 is enabled. The distance is displayed on the middle/front 8 pieces of the Neopixel strips. |
QUADRUPED_HAS_US_DISTANCE_SERVO |
disabled | A pan servo for the US distance sensor is enabled at pin 13. |
QUADRUPED_ENABLE_RTTTL |
disabled | The quadruped plays a melody at startup. |
QUADRUPED_1_WITH_DVD_REMOTE , QUADRUPED_2_WITH_LAFVIN_REMOTE , QUADRUPED_3_WITH_KEYES_CLONE_REMOTE |
disabled | 3 predefined configurations. |