User Tools

Site Tools



Keywords:Pneumatic,inverted pendulum,automatic controls,pid,lqr.

Motivation and Audience: This tutorial's motivation is to study about the mechanisms behind the control of an inverted pendulum , which is largely used in the robotics industry. Readers of this tutorial assumes the reader has the following background and interests:

  • Pneumatic mechanisms
  • Inverted Pendulum Mechanisms
  • Automatic Controls Theory (PID and LQR)
  • Controls Programming using Arduino

Overview:This tutorial is an adaptation from Jiyue Hue tutorial , which is available here: Jiyue He from DASL-Drexel

The rest of the tutorial is presented as follows:

  • Parts List and Source
  • How it works
  • Construction
  • Modelling
  • Programming
  • Final Words

Parts List and Source

How it works

Using a linear encoder and a rotational encoder, we can calculate the cart position and the pendulum angle. The cart velocity and the pendulum angular velocity can be calculated through programming.

The PD loop will calculate the necessary input voltage to be sent to the proportional valve. As the proportional valve only takes analog signals, we will need to convert the digital input calculated by the Arduino code to an analog signal – a DAC (digital to analog converter) and an operational amplifier can be used. The DAC’s output (current) is very little, so the use of an operational amplifier to amplify this signal is necessary (the signal that goes to the proportional valve is voltage). The digital value calculated by the Arduino will be send to the DAC, which will give a current output, that goes to the operational amplifier and then the output voltage goes to the proportional valve. The proportional valve takes the input voltage and gives a force output, which will drive the cart forward or backward depending on the pendulum angle.





Final Words

Original project working:

As the original tutorial related , the system's performance is not very good. Can be pointed:

  • The Arduino cannot read accurately the counts of the rotational encoder after about 10 seconds (even if the pendulum returns to the equilibrium position , after a while , this equilibrium position will not give 0 as angle , consequently the PD equation will calculate the necessary input in the proportional valve as something different than 5,1V ( voltage that makes no air flow in the valve )
  • The Arduino cannot modify 8 ports at the same time to send the binary input to the DAC , so the calculated value by the PD equation will not be the same as the value on the input of the proportional valve. (The best choice is to use a DAC with an I2C or SPI interface)
  • The travel distance of the air cylinder is very short , very often the pendulum will loose control and the air cylinder will not have enough travel distance to reestablish the balance. ( that's why you always have to be taking care of the pendulum to not let it balance too much ).
pneumatic_ip_tutorial.txt · Last modified: 2016/03/17 22:13 by joaomatos