WEEK 9: MECHANICAL DESIGN, MACHINE DESIGN



GROUP ASSIGNMENT
DESIGN A MACHINE THAT INCLUDES MECHANISM + ACTUATION + AUTOMATION. BUILD THE MECHANICAL PARTS AND OPERATE IT MANUALLY. ACTUATE AND AUTOMATE YOUR MACHINE. DOCUMENT THE GROUP PROJECT.


SELF BALANCING ROBOT

The task for this week is to create a machine that includes mechanisms, actuation, and automation. We considered a variety of options in light of the above requirements, with the self-balancing robot coming out on top due to its importance and benefits.


HOW DOES BALANCING WORK?

To keep the robot balanced, the motors must counteract the robot falling. This action requires feedback and correcting elements. The feedback element is the MPU6050 gyroscope + accelerometer, which gives both acceleration and rotation in all three axes. The Arduino uses this to know the current orientation of the robot. The correcting element is the motor and wheel combination.


SELF BALANCING ROBOT THEORY

In control theory, keeping some variable (in this case, the position of the robot) steady needs a special controller called a PID (proportional integral derivative). Each of these parameters has "gains", normally called Kp, Ki, and Kd. PID provides correction between the desired value (or input) and the actual value (or output). The difference between the input and the output is called "error". The PID controller reduces the error to the smallest value possible by continually adjusting the output. In our Arduino self-balancing robot, the input (which is the desired tilt, in degrees) is set by software. The MPU6050 reads the current tilt of the robot and feeds it to the PID algorithm, which performs calculations to control the motor and keep the robot in the upright position. PID requires that the gains Kp, Ki, and Kd values be "tuned" to optimal values. Engineers use software like MATLAB to compute these values automatically. Unfortunately, we can't use MATLAB in our case because it would further complicate the project. We will tune the PID values manually instead. Here's how to do this.

1. Make Kp, Ki, and Kd equal to zero.

2. Adjust Kp. Too little Kp will make the robot fall over, because there's not enough correction. Too much Kp will make the robot go back and forth wildly. A good enough Kp will make the robot go slightly back and forth (or oscillate a little).

3. Once the Kp is set, adjust Kd. A good Kd value will lessen the oscillations until the robot is almost steady. Also, the right amount of Kd will keep the robot standing, even if pushed.

4. Lastly, set the Ki. The robot will oscillate when turned on, even if the Kp and Kd are set, but will stabilize in time. The correct Ki value will shorten the time it takes for the robot to stabilize.



MY ROLE

In this group assignmnet my role was Soldering the PCB Satshakit "Arduino Board", Trubleshooting, Burnbootloading uploading the Code, Changing the PID values "kp, ki, kd" till Robot got balanced. "Wiring connection", Continuity checking, Inlast Assembling the Self Balancing Robot.


We decided that half work for PCB board will be done by my colleague Abid Anwar and remaining will be done by me. Then I started making component list for satshakit.

Arduino Board components list is here.


After Soldering the components into the Satshakit.


After Soldering we burn bootloading the Board to make it programmable or we say to programm the board.


Uploading the programme into the board.

CIRCUIT DIAGRAM

This is the circuit diagram which I followed while connecting the wiring with main circuit board.


ASSEMBLING

After laser cutting the Cad design which was made by one of my group partner Mansoor Ahmed then I started Assembling the parts togather along with fitting the Electronic components at their required position. It was very hard task for me arranging the components and correctly connecting the Electronic components with eachother. If any of wrong connection may cause the demaging of any of the electronic components which are used.

This is the first design which I Assembled here, Dc gear motor is used.


1st desigN was rejected due to motor shafts were too much out from the sides which we 3D printed were to long and 5mm Acrylic sheet was used Due to Acrylic Sheet Robot was too heavy.

SENSOR RESULT



WIRING AND UPLOADIG THE CODE

FTDI is connected with 328p board for uploading the code. In this picture we can see the wiring of the components according to the circuir diagram.


Here I was sitting while uploading the code for checking the voltages and continuty multiper is used because we got to much problems in powering and motor driver.


After Assembling the robot and wiring look with 328p PCB board.


Before Final Demo cheking the sensor either it is working properly or not.



FINAL DEMO

After so many trials of changing the PID values we got this result.

FEEDBACK

Before Assembling the parts in robot for final wiring check every electronic component seperately with coding. before using the components may sure you have have read the data sheet of the components. Otherwise it will be very difficult while debagging the problem most of the issue comes in mpu6050 for giving the correct values.

CONCLUSION

The field of robotics has dominated the minds of people around the world. It was the dream of humans to create such a machine that replicates them in every aspect of daily life. Two-wheel self-balancing robot is also a development in the field of robotics. This two-wheel self-balancing robot is based on the concept of Inverted pendulum theory. This type of robot has gained fame and interest among researchers and engineers because it utilizes such a control system that is used to stabilize an unstable system using efficient microcontrollers and sensors. Two-wheeled balancing robots can be used in several applications with different perspectives such as an intelligent gardener in agricultural fields, an autonomous trolley in hospitals, shopping malls, offices, airports, healthcare applications or an intelligent robot to guide blind or disable.

Here is a link to the group's documentation page.




Propeller Led Pendulum Clock by Engr. Rashid Ali is licensed under Attribution-ShareAlike 4.0 International