This is a revised and imporved upon version of the algorithm I originally wrote for my quadruped project.
As of now there is still a lot to be done. But this version is already a big step up from the previous one I included in the GrabCad files.
The major improvements are:
- added testing
- visual debugger
- turning is working again
YouTube: https://www.youtube.com/watch?v=Y6QYdh4bs70&t
GrabCad: https://grabcad.com/library/walking-quadruped-robot-diy-1
This option is there for testing and debugging purposes.
Use any c++ compiler to compile main.cpp
with the compilation define ARDUINO_FREE 1
.
You might add these defines like this in the build command:
- MSVC:
/D ARDUINO_FREE=1
- Clang\GCC:
-DARDUINO_FREE=1
Use the additional compilation define VISUALIZE_QUADRUPED 1
for creating a window showing a 3d representation of the leg movements.
Control the robot in the visual debugger using U,I,O,J,K,L,SPACE.
This mode relies on Raylib.
When building on windows with Visual Studio, just execute the build.bat
script from the Microsoft Visual Studio "x64 Native Tools Command Prompt" or from any command prompt with the vcvars64.bat environment.
- Paste the contents of
main.cpp
in the Arduino-IDE. - Install the board pack esp32 by Espressif Systems
- Install the following libraries:
- Adafruit PWM Servo Driver Library by Adarfuit
- PS3 Controller Host by Jeffry van Pernis
- Install the esp32 usb communication drivers.
- Select the board: ESP32 Dev Module
- Compile and upload to the esp32.