Omnidirectional Mecanum Car

Overview

For Fullscreen: https://www.youtube.com/watch?v=qF7bqQxeu84

This project will show you how to utilize three of our currently four DIY Kits in one project. We will use the Joystick, the Four Motor and the Power Supply DIY Kits to build a mecanum car that can go forwards, backwards and also sideways.

ADVANCED

2-3h

2 CLIENTS USED


Hardware Components

Quantum Joystick DIY Kit

 

1

Can be purchased here

Four Motor DIY Kit

1

Can be purchased here

Mecanum car

1

Can be purchased here

You can use any Mecanum car but be sure to use motors which are running with 5V and not 12V.

AA Battery Holder

1

Can be purchased here

AA Batteries

4

Can be purchased here

5V Power Supply DIY Kit

1

Can be purchased here

*This is a substitute for the AA Battery pack

Jumper Cables MM

 

8-12

Included in Component Kit

Or you can purchase it here

Q-Client Builder Base

2

Q-Client

Tools Used

Picture

Name

Quantity

Link

Picture

Name

Quantity

Link

 

Small flat-head screwdriver

1

Included in Component Kit

Or you can pick one from our Recommended Tools List


Assemble the Circuit

First we gonna build the mecanum car circuit. The following image should be a good reference to wire your own circuit.

Now wire your joystick. We will only show you the ribbon connector due to clarity.


Build the Firmware

Follow the table below to build the firmware or simply download them in the library tab on your Q-Server.

This table is for the motors.

 

GSCLK

XLAT

BLANK

SIN

SCLK

DC 1

DC 2

 

GSCLK

XLAT

BLANK

SIN

SCLK

DC 1

DC 2

MFL

GP0

GP1

GP2

GP3

GP4

0

1

MFR

GP0

GP1

GP2

GP3

GP4

2

3

MBL

GP0

GP1

GP2

GP3

GP4

4

5

MBR

GP0

GP1

GP2

GP3

GP4

6

7

For the joystick watch this short video.


Build the App

There are two ways to build the app for this project. The first is to download the mecanum car app in the library tab of your Q-Server and edit it. Also you can just download the app in the resource section of this project page.

When you want to edit the mecanum car app it should look like this:

To get the car in an omnidirectional way we need to adjust the app. It should look like this:

We added two “Value Changed” and two “Digital TOGGLE” objects. The “Digital TOGGLE” object is used to invert the signal because the joystick buttons are a pull up system but we want it to be a pull down. SO when we push the buttons of one of the joysticks the car will go sideways. To let the car go sideways 2 wheels must spin forward and two must spin backward. The “Value Changed” is to change the value of the button push. It is needed to distinguish it from the other signals the joystick is sending. Adjust your mecanum car app like this and you should be good to go.

The joystick app is relatively simple to make.

Two joystick objects are connected with a two slider analog objects for both axis and a switch for the button. Then we have a button connected with a switch which is the smaller button on your Joystick DIY Kit.

When you are finished make sure to save the app!


Map the Hardware

After you saved the app you will be back at the overview of all your apps. Click on the play button to start the app.

Now we have to map the hardware to the software. Select the corresponding motors and joysticks.

When you are finished and successfully mapped the hardware all status symbols should be greencheckmarks.

Click on “Save + Run” to start the app.


Run the App!

Now it’s time to use the car! Enjoy!


Resources

Application

 

Firmware

 

Diagram