Introduction: MARIO KART

The subjects of Instrumental laboratory for mechatronics and electronics laboratory, are both subjects designed for learning about how to work with the control of electrical energy, producing real work or signals through the use of concepts previously seen in other subjects. The mario kart contest is a project for students to develop abilities such as teamwork, programming skills, designing and boosting the creativity of each participant to make the most functional car for motion, power (in the weapon) and aesthetic design. The competition takes place inside the installations of ITESM Chihuahua. The institution will provide the students all the material needed, but they are free to add stuff to make a better performance.

Step 1: General Explanation of the Project

Mario kart is a project designed to develop certain abilities for the students to learn about electronics, implementing a micro controller arduino. The competition is basically cars designed by the students, the cars must have a weapon to burst balloons, each car has three balloons and the ultimate survivor will win.

Two subjects are involved on the competition, Instrumental laboratory of mechatronics and laboratory of electronics, students of both groups will fight to be the best in the mario kart contest.

It took place during the maker's fest of the ITESM CUU in the semester Agu-Dec 2016.

Each car must have a weapon and three balloons, as soon as all the balloons in your car are busted , you will be out of the competition, the last one standing will be the winner of the contest. The control of the car must be wireless, through a cellphone, computer or any other device capable of sending signals to the arduino shield controlling motor.

Step 2: Materials

Arduino UNO. Is an open-source prototyping platform based on easy-to-use hardware and software. Arduino provides an open-source and easy-to-use programming tool, for writing code and uploading it to your board.

Geared motors. It is a shafted 5 cm long motor, with an input of 12 volts and a maximum output power of 1.55 watts a weight of 65 grams and a maximum torque of 0.071 Nm.

Adafruit motor shield for the arduino. Is the shield used to control the motors. Instead of using a latch and the Arduino's PWM pins, we have a fully-dedicated PWM driver chip onboard. This chip handles all the motor and speed controls over I2C

SparkFun bluetooth mate silver. The Bluetooth Mate is very similar to our BlueSMiRF modem, but it is designed specifically to be used with our Arduino Prosand LilyPad Arduinos. These modems work as a serial (RX/TX) pipe, and are a great wireless replacement for serial cables. Any serial stream from 2400 to 115200bps can be passed seamlessly from your computer to your target.

Bluetooth module HC-06. As a slave module is a simple and useful for small projects in which you look up to an easy communication between your cellphone and the Arduino or other micro controllers.

Rechargeable 12v battery. This energy source is used to feed the motors, the arduino and the bluetooth module, while using 4 more 1.5v bateries to feed the weapon.

Weapon. It is basically a heat resistance, through a cable, we heat up a wire that is located on the edge of the wood sticks.


Laser cutting machine

Cautin weller

Lap top



Corel Draw

Step 3: Design and Assembling

For the design we used the AutoCad available on the computing center, the design was a simple classic square shaped car, with 4 columns that supported the roof of the car. We drew the chassis, which consists in one bottom piece, 3 walls and one roof, we left one empty side to manipulate the arduino inside of the car. The printing of the parts was made in the laser cutting machine available in the laboratory.

To export the file from the autocad to a usb port, the format of the drawing must be in a Corel Draw format so the laser cutting machine could read it and eject it.

The assembling consisted on gluing all the parts that we drew on the software, also we glued the motors to the chassis and through a hole in the middle of the bottom part, we passed the wires connected to the motors.

The weapon and balloons were located on top of the roof one ahead of the other respectively.

The design of the weapon was changed in multiple occasions, but the final design was made with two wooden sticks separated by 3 cms and a wire along the sticks and a cable enrolled in two screws located on the edge, the cable will heat up and burst the balloons.

The weapon was fed with 4 batteries of 1.5 volts each and serially connected.

To send the signal, we used an android system phone, we made the interface to communicate the cellphone with the bluetooth module and send the information to the arduino board then through the output, send the current needed for the motors to work.

Step 4: Code

The code that we used was in C language in the arduino's computer program. The lines of the code were the following:

#include #include "utility/Adafruit_MS_PWMServoDriver.h" #include int bluetoothTx = 51; // TX-O pin of bluetooth mate, Arduino D2 int bluetoothRx = 50; // RX-I pin of bluetooth mate, Arduino D3 int i, ia, vDI,vDD, vTI, vTD, DI, DD ; SoftwareSerial bluetooth(bluetoothTx, bluetoothRx); Adafruit_MotorShield AFMS = Adafruit_MotorShield(); Adafruit_DCMotor *MotorDI = AFMS.getMotor(1); Adafruit_DCMotor *MotorDD = AFMS.getMotor(2); Adafruit_DCMotor *MotorTI = AFMS.getMotor(3); Adafruit_DCMotor *MotorTD = AFMS.getMotor(4); void setup() { Serial.begin(9600); // Begin the serial monitor at 9600bps bluetooth.begin(115200); // The Bluetooth Mate defaults to 115200bps bluetooth.print("$"); // Print three times individually bluetooth.print("$"); bluetooth.print("$"); // Enter command mode delay(100); // Short delay, wait for the Mate to send back CMD bluetooth.println("U,9600,N"); // Temporarily Change the baudrate to 9600, no parity // 115200 can be too fast at times for NewSoftSerial to relay the data reliably bluetooth.begin(9600); // Start bluetooth serial at 9600 AFMS.begin(); MotorDI->setSpeed(150); MotorDI->run(FORWARD); MotorDI->run(RELEASE); MotorDD->setSpeed(150); MotorDD->run(FORWARD); MotorDD->run(RELEASE); MotorTI->setSpeed(150); MotorTI->run(FORWARD); MotorTI->run(RELEASE); MotorTD->setSpeed(150); MotorTD->run(FORWARD); MotorTD->run(RELEASE); } void loop() { if(bluetooth.available()) // If the bluetooth sent any characters { i =; } if(Serial.available()) // If stuff was typed in the serial monitor { // Send any characters the Serial monitor prints to the bluetooth bluetooth.print((char); } if( ia!= i) { switch (i) { case 119: bluetooth.println("w"); vDI = 250; vDD = 250; vTI = 250; vTD = 250; DI = 1; DD = 1; break; case 101: bluetooth.println("e"); vDI = 220; vDD = 50; vTI = 220; vTD = 50; DI = 1; DD = 1; break; case 100: bluetooth.println("d"); vDI = 250; vDD = 250; vTI = 250; vTD = 250; DI = 1; DD = 2; break; case 115: bluetooth.println("s"); vDI = 0; vDD = 0; vTI = 0; vTD = 0; DI = 1; DD = 1; break; case 97: bluetooth.println("a"); vDD = 250; vDI = 250; vTD = 250; vTI = 250; DI = 2; DD = 1; break; case 113: bluetooth.println("q"); vDD = 250; vDI = 50; vTD = 250; vTI = 50; DI = 1; DD = 1; break; case 120: bluetooth.println("x"); vDI = 220; vDD = 220; vTI = 220; vTD = 220; DI = 2; DD = 2; break; } MotorDI->setSpeed(vDI); MotorDI->run(DI); MotorDD->setSpeed(vDD); MotorDD->run(DD); MotorTI->setSpeed(vTI); MotorTI->run(DI); MotorTD->setSpeed(vTD); MotorTD->run(DD); ia=i; } }

Step 5: Competition

The competition was about bursting others balloons, as explained on the introduction. Here is a video of the contest. The pink squared car is the one we made. WE WERE THE CHAMPIONS.