Thumbnail

Inverted Pendulum

The inverted pendulum skill is designed to be used with the Sainsmart v3 balance robot but technically you can use the Sainsmart hardware, combined with ARC, to balance any robot.

+ How To Add This Control To Your Project (Click to Expand)
  1. Make sure you have the latest version of ARC installed.
  2. Select the Get button in this page to download the archive file.
  3. Double click the downloaded archive file to execute installer.
  4. The installer will add this control to ARC.
  5. Load ARC and press the Project -> Add Control button from the menu.
  6. Choose the Movement Panels category tab.
  7. Press the Inverted Pendulum icon to add the control to your project.

Manual

The inverted pendulum skill is designed to be used with the Sainsmart v3 balance robot but technically you can use the Sainsmart hardware, combined with ARC, to balance any robot. You'll just need some patience to tune the PID values. In order to use this skill you'll have to install the custom EZB firmware onto the Sainsmart robot's Arduino Mega and connect it to ARC.  

Main window


User-inserted image


1. PID Gain Value Sliders
These sliders adjust the proportional, integral, and derivative (Kp, Ki, and Kd) values that are used for the closed loop balancing algorithm.

2. Values Display & Update Realtime Checkbox
The Kp, Ki, and Kd values are displayed here as well as Omega, Angle, Distance, encoder values, angle offset, and speed values. The Checkbox is used for showing realtime values if needed.

3. Angle Correction Offset Slider
Correct the angle of your balancing robot with this slider.

4. Movement panel
This panel allows you to move the balancing robot, forward, reverse, left and right. 

5. Calibrate Button
This button sends the Calibration command to the Arduino Mega.

6. Status Display
This displays communication between ARC and the Arduino Mega.

How to Use Inverted Pendulum


1) Download the EZB firmware onto the Sainsmart Balancing robot's Arduino Mega.

2) Add the Inverted Pendulum Skill to your ARC project (Project -> Add Skill -> Movement Panels -> Inverted Pendulum).

3) Connect the Arduino Mega's COM port to ARC with a USB cable or Bluetooth.

4) Push the Calibrate button then start adjusting the sliders in the Inverted Pendulum Skill until you have optimal balancing. Adjust Kp, then Kd, and then Ki. Note that Kp is a usually higher in value and Kd is a very low value.

Video




Requirements


You will have to program the EZB firmware onto the Arduino Mega, located on the hardware page, in order to use this skill.

Resources


The hardware for this skill can be found here: https://synthiam.com/Docs/Hardware/SainSmart-Balance-Robot

Here is the Inverted Pendulum firmware for the Arduino Mega: https://synthiam.com/uploads/imagesrc/EZ-Mega-v1_Balance_Robot-636848728401310251.zip

The tutorial for installing the EZB firmware onto an Arduino Mega is here: https://synthiam.com/Community/Tutorials/Connecting-Arduino-to-EZ-Builder-17526

*Note: This skill is in beta stages

Synthiam
#2   — Edited
Fixed URL. I'll also have that old URL redirected because there's a ton of content posting to that old url that wasn't updated. Thanks for letting me know