8. Cinemática de Robots Móviles. / 8. Kinematics of Mobile Robots.

En este programa, utilizaremos el conocimiento sobre la cinemática de robots móviles para hacer que Piero dé vuelta.

 

In this program, we will use the knowledge about the kinematics of mobile robots to make Piero turn. 

8.1 Basic

inv - dir.png.1

Para construir este programa, es esencial saber qué es la matriz Jacobiana y para qué se utiliza.

To build this program it is essential to know what the Jacobian matrix is and for what it is used. 

jacobian.PNG.1

Usamos Jacobiano Directo para cambiar la velocidad interna a velocidad externa.

Usamos Jacobiano Inverso para cambiar la velocidad externa a la velocidad interna -  la diferencia en la ecuación (excepto que cambia el Jacobiano Directo en Inverso) es que estamos intercambiando la velocidad externa y la velocidad interna.

 

We use the Direct Jacobian matrix in order to change the inner speed to external speed.  

We use the Inverse Jacobian matrix in order to change the external speed to inner speed - the difference in the equation (except changing Direct Jacobian into Inverse one) is that we are swapping external speed and inner speed. 

 

8.2. Simulink.

calyProgg.png.1

Arriba podemos ver el aspecto general de nuestro proyecto. Nuestra entrada es teta - el ángulo de la curva. Como podemos ver, tenemos una ruta principal, donde transformamos el ángulo a velocidad para cada rueda y luego verificamos la posición real del Piero. Además, tenemos un circuito de retroalimentación, donde restamos el valor real del ángulo.

 

Above we can see the overall look of our project. Our input is teta - the angle of the curve. As we can see we have one main path, where we transforming the angle to velocity for each wheel and then checking the actual position of the Piero. Also, we have a feedback loop, where we subtracting the actual angle value. 

sim1.png.1

El primer bloque es el Bloque Constante que nos da el valor de ángulo deseado. Del bucle de retroalimentación, tenemos el ángulo real, que restamos para recibir un error. Este error pasa al Discrete PID Controller que controla el proceso y nos da la velocidad del ángulo - w. Omega y velocidad son la entrada de Mux, que se une a ellos dando la matriz. Esta matriz se multiplica por Jacobiano Inverso en el bloque Matrix Multiply. Así es como recibimos las velocidades V1 y V2 para cada rueda. 

 

The first block it is Constant Block which gives us the wanted angle value. From the feedback loop, we have the actual angle, which we subtract to receive an error.  This error goes to Discrete PID Controller which control the process and give us the w - angle velocityOmega and velocity are the input of Mux, which joins them giving the array.  This array is multiplied by Inverse Jacobian in Matrix Multiply block. This is how we receive V1 and V2 - velocities for each wheel. 

sim2.png.1

 

 

 

 

 

 

 

 

 

 

V1 y V2 van al Subsystem - este subsistema es el proyecto anterior que se refiere al control de la velocidad. Ese subsistema nos da velocidades reales de las ruedas desde el codificador. Otro bloque es Reshaper  - este cambia la forma de la matriz dada. Necesitábamos poder multiplicar esa velocidad por Jacobiano Directo. Después de la multiplicación, tenemos otro subsistema: este tiene un cálculo básico para recibir Vy, Vx y w.

 

V1 and V2 go to Subsystem - this subsystem is the previous project which refers to the control of the velocity. That subsystem gives us actual wheel velocities from the encoder. Another block is Reshaper - this one changes the shape of given array. We needed it to be able to multiply that velocity by Direct Jacobian. After multiplication, we have another subsystem - this one has a basic calculation to receive Vy, Vx, and w.

calcuuu.png

El siguiente bloque después de este cálculo es el Discrete-Time Integrator desde el cual, como salida, recibimos una posición real en los ejes X e Y y el ángulo real.

El último bloque es XY Graph, nos ayuda a ver si el programa funciona bien.

 

Next block after this calculation is Discrete-Time Integrator from which as an output we receive an actual position on X and Y axis and actual angle.

The last block is XY Graph - it helps us to see if the program works well.

xy.png.1

 

8.3. Resumen. / 8.3. Summary.

Gracias a esto, entiendo mejor la importancia y el uso de la matriz jacobiana. Además, ese fue otro paso para mejorar la actuación de Piero.

 

Thanks to this I better understand the importance and use of the Jacobian matrix. Moreover, that was another step to improve Piero's performance.