Control Lego NXT with wiimote
Ever want to build your own RC vehicle? Now you can. Your in control of its design, and as simple to use a Legos, because it is Legos. All you need is a Lego NXT, a computer with a Bluetooth dongle, and control software


I am 17 years old.

Step 1: Materials

Control Lego NXT with wiimote
You will need:
*standard NXT kit
*computer with bluetooth
*wiimote

Step 2: Step 1

Control Lego NXT with wiimote
This part is best explained visually. View pictures for guidance.

Step 3: Step 2

Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 4: Step 3

Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 5: Step 4

Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 6: Step 5

Control Lego NXT with wiimote
View pictures for guidance.

Step 7: Step 6

Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 8: Step 7

Control Lego NXT with wiimote
View pictures for guidance.

Step 9: Step 8

Control Lego NXT with wiimote
View pictures for guidance.

Step 10: Step 9

Control Lego NXT with wiimote
View pictures for guidance.

Step 11: Step 10

Control Lego NXT with wiimote
View pictures for guidance.

Step 12: Step 11

Control Lego NXT with wiimote
View pictures for guidance.

Step 13: Step 12

Control Lego NXT with wiimote
View pictures for guidance.

Step 14: Step 13

Control Lego NXT with wiimote
View pictures for guidance.

Step 15: Step 14

Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 16: Step 15

Control Lego NXT with wiimote
Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 17: Step 16

Control Lego NXT with wiimote
View pictures for guidance.

Step 18: Step 17

Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 19: Step 18

Control Lego NXT with wiimote
View pictures for guidance.

Step 20: Step 19

Control Lego NXT with wiimote
View pictures for guidance.

Step 21: Step 20

Control Lego NXT with wiimote
Control Lego NXT with wiimote
Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 22: Step 21

Control Lego NXT with wiimote
View pictures for guidance.

Step 23: Step 22

Control Lego NXT with wiimote
Control Lego NXT with wiimote
View pictures for guidance.

Step 24: Step 23

Control Lego NXT with wiimote
View pictures for guidance.

Step 25: Step 24

Control Lego NXT with wiimote
View pictures for guidance.

Step 26: Step 25

Control Lego NXT with wiimote
View pictures for guidance.

Step 27: Step 26

Control Lego NXT with wiimote
View pictures for guidance.

Step 28: Step 27

Control Lego NXT with wiimote
View pictures for guidance.

Step 29: Step 28

Control Lego NXT with wiimote
View pictures for guidance.

Step 30: Step 29

Control Lego NXT with wiimote
Plug left cable into port b. The picture is wrong.

Step 31: Step 30

Control Lego NXT with wiimote
Plug the right cable into port c. The picture is wrong.

Step 32: Software

Control Lego NXT with wiimote
download glovepie from:
http://glovepie.org/glovepie_download.php

download the controller:
http://www.norgesgade14.dk/bluetoothremote.php


After downloading extract the files.

Step 33: Turn brick on

Control Lego NXT with wiimote
Control Lego NXT with wiimote

Step 34: Find Bluetooth

Control Lego NXT with wiimote
Control Lego NXT with wiimote
use left and right keys until Bluetooth is centered.

Step 35: Select Bluetooth

Control Lego NXT with wiimote
Once you find the Bluetooth icon hit the orange button.

Step 36: Find On/Off

Control Lego NXT with wiimote
Use the right and left arrows to find On/Off

Step 37: Turning on Bluetooth

Control Lego NXT with wiimote
Select On if not already.

Step 38: Finding visibility

Control Lego NXT with wiimote
While in the Bluetooth menu find the visibility icon.

Step 39: Make it visible

Control Lego NXT with wiimote
Select On if not already selected.

Step 40: Start

Control Lego NXT with wiimote
click on the orb or hit super on your keyboard.

Step 41: Control

Control Lego NXT with wiimote
Start the control panel.

Step 42: Bluetooth

Control Lego NXT with wiimote
double click the Bluetooth icon.

Step 43: Add device

Control Lego NXT with wiimote
Select add device from the menu bar.

Step 44: Find device

Control Lego NXT with wiimote
After clicking on add new device a window will open. Other devices than your brick may appear. Wait until your NXT brick is found to double click on it. My bricks name was Sean, so I clicked on it.

Step 45: Pairing

Control Lego NXT with wiimote
A window will open asking for the device's password.

Step 46: Paring password

Control Lego NXT with wiimote
Look at your brick. The default password is "1234." You can change the password if you want to. Once you know what password you want to use select the check mark.

Step 47: Paring

Control Lego NXT with wiimote
Enter pairing password from NXT.

Step 48: Finish pairing

Control Lego NXT with wiimote
Click connect and windows will install the drivers needed.

Step 49: Wait

Control Lego NXT with wiimote
Wait until all the drivers have been installed and the brick has been successfully paired to move on.

Step 50: Pairing wiimote

Control Lego NXT with wiimote
Go back to the Bluetooth window. Your brick should now appear there. Select add new device.

Step 51: Pairing wiimote

Control Lego NXT with wiimote
Make sure your Wii is off. Either hold down both the 1 and 2 buttons or hit sync on the back of the controller.

Step 52: Find device

Control Lego NXT with wiimote
After clicking on add new device a window will open. Other devices than the wiimote may appear. Wait until your wiimote is found to double click on it.

Step 53: Connect wiimote to computer

Control Lego NXT with wiimote
For the password option. Select pair without password.

Step 54: Finish connecting wiimote

Control Lego NXT with wiimote
The wiimote should pair with your computer and install drivers.

Step 55: Getting com port

Control Lego NXT with wiimote
Go to the Bluetooth menu. Right click on your brick, select properties, then settings. After loading you will see which COM port the brick is using.

Step 56: Start the control program

Control Lego NXT with wiimote
Double click on the controllers icon.

Step 57: Enter COM port

Control Lego NXT with wiimote
Enter the com port of the brick. Then click start.

Step 58: Enable keyboard

Control Lego NXT with wiimote
Click enable keyboard in lower right corner of the program.

Step 59: Start glovepie

Control Lego NXT with wiimote
Double click on the glovepie icon.

Step 60: Program

Here is the program. Just copy and past

if var.run == FALSE then
var.run = TRUE
HidePie
var.hidden = TRUE
endif


if ((DoubleClicked(Wiimote.Home) and Wiimote.HasClassic == FALSE) or DoubleClicked(Home) or DoubleClicked(Wiimote.Classic.Home)) and (var.hidden == true) then
ShowPie
var.hidden = FALSE
elseif ((DoubleClicked(Wiimote.Home) and Wiimote.HasClassic == FALSE) or DoubleClicked(Home) or DoubleClicked(Wiimote.Classic.Home)) and (var.hidden == FALSE) then
HidePie
var.hidden = TRUE
endif


var.home = SingleClicked(Wiimote.Home)
If var.home and var.on then
var.on = FALSE
elseif var.home and var.on = FALSE then
var.on = TRUE
endif


key.u = wiimote.a
key.j = wiimote.b
key.t = wiimote.Plus
key.g = wiimote.minus
key.y = wiimote.right
key.h = wiimote.Left
var.err = 15 //edit to change intervals. (0 - 180) are possible values

if ((wiimote.roll > var.err) && (wiimote.pitch < -(var.err)))
key.w =false
key.d =false
key.s =false
key.a =false
key.e =true
key.c =false
key.z =false
key.q =false
else
key.e =false
endif

if ((wiimote.roll > var.err) && (wiimote.pitch > var.err))
key.w =false
key.d =false
key.s =false
key.a =false
key.e =false
key.c =true
key.z =false
key.q =false
else
key.c =false
endif

if ((wiimote.roll < -(var.err)) && (wiimote.pitch < -(var.err)))
key.w =false
key.d =false
key.s =false
key.a =false
key.e =false
key.c =false
key.z =false
key.q =true
else
key.q =false
endif

if ((wiimote.roll var.err))
key.w =false
key.d =false
key.s =false
key.a =false
key.e =false
key.c =false
key.z =true
key.q =false
else
key.z =false
endif

if ((Abs(wiimote.roll) var.err))
key.w =false
key.d =false
key.s =true
key.a =false
key.e =false
key.c =false
key.z =false
key.q =false
else
key.s = false
endif

if ((wiimote.roll > var.err) && (Abs(wiimote.pitch) key.w =false
key.d =true
key.s =false
key.a =false
key.e =false
key.c =false
key.z =false
key.q =false
else
key.d = false
endif

if ((Abs(wiimote.roll) key.w =true
key.d =false
key.s =false
key.a =false
key.e =false
key.c =false
key.z =false
key.q =false
else
key.w = false
endif

if ((wiimote.roll < -(var.err)) && (Abs(wiimote.pitch) key.w =false
key.d =false
key.s =false
key.a =true
key.e =false
key.c =false
key.z =false
key.q =false
else
key.a = false
endif

if (((Abs(wiimote.roll) key.w =false
key.d =false
key.s =false
key.a =false
key.e =false
key.c =false
key.z =false
key.q =false
endif


Wiimote.Led1 = var.on
Wiimote.Led2 = true
Wiimote.Led3 = var.on
Wiimote.Led4 = true


if Wiimote.Battery Say "Low Battery"
var.warned = TRUE
endif
var.bat = Wiimote.Battery / 192 * 100
debug ='Battery= '+var.bat+'%'

Step 61: Controls

hold wiimote with IR camera facing away from you and level.

tilt wiimote down to go forward

tilt wiimote backward to go backward

tilt wiimote right to turn right

tilt wiimote left to turn left

tilt wiimote down and right to go forward to the right

tilt wiimote up and right to go backward to the right

tilt wiimote down and left to go forward to the left

tilt wiimote up and left to go backward to the left

plus button increases speed

minus button decreases speed

right button on gamepad increases spin speed

left button on gamepad decreases spin speed

a button increases turn ratio

b button decreases turn ratio

double click home button to reopen glove pie

Step 62: Run glove pie

Click run and enjoy.

I am 17 and if I can do, so can you.

Step 63: Finished

 
 

Tag cloud

make build easy simple arduino making homemade solar laser printed portable cheap mini building custom cardboard wooden create super lego turn paracord chocolate your paper light intel