background image

 
 

Mars Explorer Mecanum Wheel Robotic Kit 

(Arduino Mega2560) 

 

 

More information:    http://osoyoo.com/?p= 30176 

 

Summary of Contents for Mega2560

Page 1: ...Mars Explorer Mecanum Wheel Robotic Kit Arduino Mega2560 More information http osoyoo com p 30176 ...

Page 2: ...cluding remote control by Bluetooth IoT through Wifi Line tracking and Obstacle Avoidance auto driving With the help of powerful Mecanum wheels the car can make much more complicated movement such as sideway shifting and digaonally movement controlled by Cell phone APP The kit comes with OSOYOO MEGA2560 board fully compatiable with Arduino MEGA2560 and OSOYOO ESP8266 Wifi Shield Besides we have de...

Page 3: ...CONTEXT Lesson1 Assembling the Car 4 Lesson 2 Obstacle Avoidance Robot Car 17 Lesson 3 Tracking Line 23 Lesson 4 Bluetooth Imitation Robot Car 27 Lesson 5 Wifi IoT Control Robot Car 32 ...

Page 4: ...ws you how to install the chassis of this car and connect Arduino control signal wires to two model X L298N driver board This installation will be the start point of our other lessons OSOYOO Mecanum wheels robotic car chassis x1 2xleft wheels 2xright wheels and Motor x 4 OSOYOO Mega2560 board fully compatible with Arduino UNO Mega2560 x 1 OSOYOO V1 0 Wifi shield x 1 OSOYOO Model X motor driver x 2...

Page 5: ...per standoff please skip this step and directly go to Step 2 Follow the picture below to install 4 copper standoff on the positions of the blue lines first then fasten the 4 motors onto the 4 standoffs Make sure the motor directions must be correct exactly same as picture Picture 3 Motor fasten screws location map view from bottom of the chassis ...

Page 6: ...installed standoff please follow the pictures below to install them onto the chassis The four motors have two types of standoff positions Type A have standoffs installed on the RED wire side of the motor see picture 5 top two motors Group B have standoffs installed on the Black wire side of the motors see picture 5 lower two motors Picture 5 distinguish two type of motors ...

Page 7: ...Picture 6 Type A and Type B motors location map in chassis Picture 7 Wheel installation map ...

Page 8: ...heck the type A wheel and type Wheel by following picture 8 left side You must 100 sure that correct type of wheel is installed into correct position as per picture 8 right side the rolling direction of each wheel will determine the whole car moving directions showed in the picture Picture 8 Two types of Mecanum wheel and their installation position in the car ...

Page 9: ...will result in different car movement directions Following pictures shows how they works Step 4 Install Mega2560 Model X boards L298N Wifi shield onto the chassis Picture 10 MEGA2560 Model X voltage meter guide Picture 11 Battery box installation location ...

Page 10: ...Picture 12 Wifi shield installation guide ...

Page 11: ...the black plastic pin holder to do operation Never drag the wires to pull the plug out of the socket otherwise it will damage the wires Picture 13 Connect Model X board L298N to front motors Picture 14 connect another model X board L298N to rear motors Picture 15 Connect Front Model X pins to MEGA2560 ...

Page 12: ...connected to D22 which is located on the SECOND female hole from right in following picture 10 Many people treat the first hole as D22 THIS IS WRONG Picture 16 Front Model X board IN1 IN2 IN3 IN4 pin connect to D22 D24 D26 D28 ...

Page 13: ...Picture 17 Connect Rear model X control pins to Mega2560 Picture 18 Connect Model X to Voltage meter ...

Page 14: ...Open source Arduino Software IDE Download Arduino IDE here https www arduino cc en Main Software setlang en ...

Page 15: ...en Main Software setlang en then install the software Step 2 Download https osoyoo com driver mecanum mecanum 2560 lesson1 zip unzip the download zip file lesson1 zip you will see a folder called lesson2 Step 3 Connect mega2560 board to PC with USB cable Open Arduino IDE click file click Open choose code lesson1 ino in lesson1 folder load the code into arduino Step 4 Choose corresponding board por...

Page 16: ... code the car will move forward backward left turn right turn left shift right shift If the car does not move as per this sequence you need check the wire connection Youtube Video Link https www youtube com embed 15qYSh9M5AE ...

Page 17: ... board fully compatible with Arduino x 1 OSOYOO V1 0 Wifi shield x 1 OSOYOO Model X motor driver x 2 OSOYOO MG90 servo motor x 1 OSOYOO Ultrasonic sensor module x1 OSOYOO Mount holder OSOYOO Battery box x 1 18650 Batteries 3 7V x 2 You must complete lesson 1 assembling the car before you continue on with this lesson In this lesson3 we will add a servo motor and to the robotic car built in Lesson 1...

Page 18: ...motor at the front of upper car chassis with 2pcs M2 2 8 Self Tapping Screws Step 4 Install mount holder for Ultrasonic Module on servo motor with M2 4 Self Tapping screw Please note please upload code to adjust servo motor direction before fixing this screw ...

Page 19: ...on 1 connections same as it is STEP5 Connect Servo 3 pin head to any Model X board servo slot yellow to S pin red to 5v brown to G pin then connect another S pin to Wifi board D13 STEP6 Connect Ultrasonic sensor module to wifi board as following graph ...

Page 20: ... version after 1 1 16 please skip this step Download Arduino IDE from https www arduino cc en Main Software setlang en then install the software Step 2 Download https osoyoo com driver mecanum mecanum 2560 lesson2 zip unzip the download zip file lesson2 zip you will see a folder called lesson2 Step 3 Connect mega2560 board to PC with USB cable Open Arduino IDE click file click Open choose code les...

Page 21: ...tion as following picture Otherwise the obstacle avoidance program will not work properly After adjusting sensor direction turn on battery again If its direction is not straight forward turn off battery and do direction alignment again If the ultrasonic module turn to front view position that means you no need adjust sensor position anymore Just wait 5 seconds If no obstacle is detected the car wi...

Page 22: ...and make your Ultrasonic sensor position change you must remember to do sensor direction alignment again Youtube Video Link https www youtube com embed 5VRMH276oas ...

Page 23: ...e white ground OSOYOO Mecanum wheels robotic car chassis x1 2xleft wheels 2xright wheels and Motor x 4 OSOYOO Mega2560 board fully compatible with Arduino UNO Mega2560 x1 OSOYOO V1 0 Wifi shield x1 OSOYOO Model X motor driver x2 OSOYOO 3 Point Tracking sensor module x1 OSOYOO Battery box x1 18650 Batteries 3 7V x2 You must complete lesson 1 assembling the car before you continue on with this lesso...

Page 24: ...20cm female to female cable as the following photo shows Remember DO NOT remove any existing wires installed in Lesson 1 Open source Arduino Software IDE Download Arduino IDE here https www arduino cc en Main Software setlang en 7 zip is a free zip utility that un zips zip files Download 7zip here for free https www 7 zip org Step 1 Install latest Arduino IDE If you have Arduino IDE version after ...

Page 25: ...lder load the code into arduino as following Step 4 Choose corresponding board port for your project upload the sketch to the board Step 5 Adjust the sensitivity of tracking sensor modules Turn on and hold the car and adjust the potentiometer on the tracking sensor with cross screwdriver until you get the best sensitivity status the signal indicate LED light will turn on when sensor is above white...

Page 26: ...ted that the bend angle of track can t be too sharp otherwise the car will move out of the track Turn on the car and put the middle of tracking sensor module facing over black track and then the car will move along the black track automatically Youtube Video Link lesson3 https www youtube com embed NTqsy7HClZc ...

Page 27: ...ls 2x right wheels and 4x motor OSOYOO Mega2560 board fully compatible with Arduino OSOYOO V1 0 Wifi Shield x 1 OSOYOO Model X motor driver x 2 OSOYOO HC02 bluetooth module OSOYOO Battery box x 1 18650 Batteries 3 7V x 2 You must complete lesson 1 assembling the car before you continue on with this lesson No need change anything just keep the hardware wire connection as it is STEP1 Connect B_TX an...

Page 28: ...STEP2 Bluetooth Module should be inserted into bluetooth 6 pin slot in OSOYOO Wifi Board ...

Page 29: ...then install the software Step 2 Download https osoyoo com driver mecanum mecanum 2560 lesson4 zip unzip the download zip file lesson4 zip you will see a folder called lesson4 Step 3 Connect mega2560 board to PC with USB cable Open Arduino IDE click file click Open choose code lesson4 ino in lesson4 folder load the code into arduino Step 4 Choose corresponding board port for your project upload th...

Page 30: ... before open the APP In your cell phone Setting Bluetooth find a Bluetooth device called HC02 pair it with password 1234 2 After bluetooth HC02 device is paired open the APP If you are using Android APP Click BT Search Button to connect APP to HC02 device if it is iOS APP just click connect 3 Click Engine Switch to start stop the car ...

Page 31: ... direction steering wheel will rotate while you are turning the phone 6 Click Gear button to change gear to Forward or Backward direction 7 Press F1 to Shift to left way F5 to shift to right way F3 to up left diagonal F4 to up right diagonal Youtube Video Link https youtu be GzVJng2rCBI ...

Page 32: ...O V1 0 Wifi Shield x 1 OSOYOO Model X motor driver x 2 OSOYOO Battery box x 1 18650 Batteries 3 7V x 2 If you just finishes all Lesson 1 Lesson3 please keep all lesson connections same as it is Then plug out bluetooth from Wifi Shield Remove the connection B_TX and B_RX to D18 and D19 Connect E_TX to D19 RX1 and E_RX to D18 TX1 Note You need split 2 pcs of male to female jumper wires from our 10 p...

Page 33: ...e https www 7 zip org Step 1 Install latest Arduino IDE If you have Arduino IDE version after 1 1 16 please skip this step Download Arduino IDE from https www arduino cc en Main Software setlang en then install the software STEP2 Please download the library zip file from WiFiEsp master Open Arduino IDE click Sketch Include Library Add ZIP library then load above zip file into Arduino ...

Page 34: ...ot APP in Google Play or Apple Store and then install this APP STEP4 Arduino Sketch code Installation Robot Car can work in two Wifi modes AP mode and STA mode The Arduino sketches for these two modes are different Let s explain these two modes one by one ...

Page 35: ...2560 lesson5A zip Unzip the file and you will see a folder named mecanum 2560 lesson5A upload the code into Arduino 2 Open your Arduino Serial monitor and set 9600 baud then you will see a similar result as AP mode A new Wifi SSID osoyoo_robot with IP address 192 168 4 1 will show up in the window This means your Robot car has a Wifi Hot Spot name osoyoo_robot its IP address is 192 168 4 1 3 Now y...

Page 36: ...phone control the robot car 5 You can click the v direction keys to make the car move Use pause key to stop the car movement Click Obstacle to shift left side Click Tracking to shift right side Click F1 to make upper left diagonal movement Click F3 to make upper right diagonal ...

Page 37: ...n LAN IP address from DHCP server You can use Mobile APP to access the robot car s IP address and control its movement 1 Please download STA mode sketch code from https osoyoo com driver mecanum mecanum 2560 lesson5B zip Unzip the file and you will see a folder named mecanum 2560 lesson5b then load themecanum 2560 lesson5b ino code into Arduino 2 You need change the code Line 176 and Line 177 char...

Page 38: ... IP address and click Setting to set up robot IP address and set this IP address to your APP Setting section no need change default port 80 in APP 5 Now your Robot car is connected to your LAN you can use Mobile phone under same LAN to control the robot car If your APP is in WAN you need to go to your Router Control Panel forward Port 80 to Robot car LAN IP address then you can use Router IP to co...

Page 39: ...o stop the car movement Click Obstacle to shift left side Click Tracking to shift right side Click F1 to make upper left diagonal movement Click F3 to make upper right diagonal movement Click F4 to make back left diagonal movement Click F6 to make back right diagonal movement ...

Reviews: