The purpose was to develop a low-cost robot using recycled material.
The project covers the software and hardware of a robot car made from scratch using recycled material and a PIC18F45K22 as its brain.
The Robotzord was developed as a personal project during my Electrical Engineering graduation and it was mounted on a breadboard according to /Hardware folder schematics.
The code was developed specifically to PIC platform. However, if some changes were made, mainly in initialization, configuration and some registers, the project can be adapted to other microcontroller families, from different manufacturers.
The programming language used in project was C and the Interface Development Environment (IDE) was MikroC Pro Pic.
Robotzord was developed when I was in my 3rd semester of the Electrical Engineering at UFSM. So, I would like to make it clear that if I would develop the same project today, certainly a lot of things would be different, improved and optimized. ;)
The robot mechanical structure was made from recycled material.
Its chassi is an old computer CD/DVD drive + an electric plastic box cutted on half, its wheels are from an old plastic toy motorbike and its rear supporting wheel is composed by an old fan and old plastic parts from broken toys.
Below there are some images of the robot mechanical structure.
The hardware was mounted on a breadboard and coupled on the robot's chassi.
The robot breadboard contains an H bridge to do the motors control, a LCD display as IHM and a set of buttons to receive user commands.
Moreover, the robot has 2 pairs of infrared sensors to acquire its pulses per revoultion.
The robot battery is a bunch of 1.2V AA batteries in series, totalizing ~6.0V.
The software was developed using MikroC, and the robot main idea is to receive some specific inputs from users and move according received instructions. I developed some routines making it capable to move in circles, squares, line, etc..
In addition, I did put a holed plastic wheel on each axis to couple the infrared sensors and count the number of pulses per revolution. Though, we have an encoder and can measure the distance that the robot moved, making its instructions more accurate.
The robot can move based on time or based on the distance measured in software using its encoder.
This project pictures do not show the encoders in place, but it is working on the Robotzord 2.0 version, that will be available soon in my Github page.
File types in project:
- The .c file contains the developed code in C.
- The .asm file contains the code translated to assembly
- The .hex file is the ready to burn file, containing the code in hexadecimal language.
- The .mccpi file is the link between all files in project, created by MikroC compiler (IDE used to software development).
- The other files are configuration files, created by compiler.
- Inside /Hardware folder it is the project hardware schematic
Below there is an imagem of the project hardware designed using Altium Designer.
Bill of materials:
- 1 x PIC18F45K22F microcontroller
- 2 x Robotic DC Motor (servo-motor control circuit less)
- 1 x 7805 Voltage Regulator
- 5 x Push button
- 5 x Resistores 1k ohm
- 1 x 20MHz Crystal
- 2 x 22pF Capacitors
- 1 x 100nF Capacitors
- 4 Mosfet IRF540N
- 4 Mosfet IRF9540N
- 1 x LCD Display
- 1 x 10k Potentiometer
- 2 x infrared emmiter
- 2 x infrared receptor
- 4 x 270R resistor
- 1 x ~6.0V battery
- 1 x Breadboard
This project generated a paper publication on an International Sustainability Forum hosted in Santa Maria (RS), Brazil:
http://ecoinovar.com.br/cd2014/arquivos/artigos/ECO091.pdf
Below, there is an image of the final result.
P.S.1: In the picture its missing the microcontroller, but you can see its spot on the picture, between the LCD and the buttons board, on the breadboard center :P
P.S.2: There is a new version of the robot, and it contains more sensors and the hardware and software are really optimized, but I did not have time yet to post the project on Github. However, I'll post it and make a report soon as I can. :)
The project can be reproduced without any problems.
However, I only ask you to keep author credits. :)
Enjoy!
Hollweg