Computer Engineering Remote Controlled Car Project ACSE 2006

27
Computer Engineering Remote Controlled Car Project ACSE 2006 Graham Smyth Jerry Dolata

description

Computer Engineering Remote Controlled Car Project ACSE 2006. Graham Smyth Jerry Dolata. Computer Engineering Units. Grades 10 - 12 Five Hands-0n Units. 1 . Hardware 2. Networking 3. Integrated Circuits 4. Programming 5. Interfaces. Software. Turing. parallelput ( number) - PowerPoint PPT Presentation

Transcript of Computer Engineering Remote Controlled Car Project ACSE 2006

Page 1: Computer Engineering Remote Controlled Car Project ACSE 2006

Computer Engineering Remote Controlled Car

ProjectACSE 2006

Graham Smyth

Jerry Dolata

Page 2: Computer Engineering Remote Controlled Car Project ACSE 2006

Computer Engineering Units

1. Hardware

2. Networking

3. Integrated Circuits

4. Programming

5. Interfaces

Grades 10 - 12Five Hands-0n Units

Page 3: Computer Engineering Remote Controlled Car Project ACSE 2006

SoftwareTuring

• parallelput ( number)• put parallelget• mousewhere ( x, y, click)• play (“CDEFG”)• drawline ( x1, y1, x2, y2, red)• Provincially Licensed

Page 4: Computer Engineering Remote Controlled Car Project ACSE 2006

Parallelport Pin Configuration(printer port)

View from back of Computer

13 12 11 10 9 8 7 6 5 4 3 2 1

25 24 23 22 21 20 19 18 17 16 15 14

OutputD0 – D7

InputI0 – I3

Input I4 Grounds18 - 25

Page 5: Computer Engineering Remote Controlled Car Project ACSE 2006

D sub Pin Assignment

pin function parallelput

2 forward 1

3 reverse 2

4 left 4

5 right 8

18 ground

Page 6: Computer Engineering Remote Controlled Car Project ACSE 2006

parallelput(number)

Number D7 D6 D5 D4 D3 D2 D1 D0

1 1 1 1 1 1 1 1

0 0 0 0 0 1 0 0parallelput(4)

parallelput(5) 0 0 0 0 0 1 0 1

parallelput(255)

Page 7: Computer Engineering Remote Controlled Car Project ACSE 2006

Colour Code for Cables

Wire Colour Function D Sub parallelput

1 Orange Forward Pin 2 1

2 Orange/ White Reverse Pin 3 2

3 Green Left Pin 4 5 or 6

4 Green/White Right Pin 5 9 or 10

5 Blue Ground Pin 18

Page 8: Computer Engineering Remote Controlled Car Project ACSE 2006

Breadboard Connections

Connected

Connected

HighFives

DividerLowFives

Page 9: Computer Engineering Remote Controlled Car Project ACSE 2006

Remote Controlled Car Project

Hardware

Page 10: Computer Engineering Remote Controlled Car Project ACSE 2006

Removing Shipping Holders

1. Remove Screw 2. Remove Screw

Page 11: Computer Engineering Remote Controlled Car Project ACSE 2006

Removing Battery Covers

1. Remove Screw

2. Remove Screw

4. Insert 1 9V 3. Insert 4 AA

Page 12: Computer Engineering Remote Controlled Car Project ACSE 2006

Opening Case

Carefully Remove 10 Small Screws

Page 13: Computer Engineering Remote Controlled Car Project ACSE 2006

Removing Joysticks

Separate Case

Remove Joysticks

Page 14: Computer Engineering Remote Controlled Car Project ACSE 2006

4 Pair From Joystick

1. Green/White2. Green

3. Blue4. Orange5. Orange/White

Carefully Wrap 5 Wires to Board

Page 15: Computer Engineering Remote Controlled Car Project ACSE 2006

Closing Case

Removing Battery Covers

Use 2 Screws in Opposite Corners to Close Case

Wrap to Secure Cable

Antenna Inserted

Page 16: Computer Engineering Remote Controlled Car Project ACSE 2006

4 Pair Wire to TransistorsOrange to Right Pin

Orange/White to Right Pin

Green to Right Pin

White/Green to Right Pin

Blue to Ground

Page 17: Computer Engineering Remote Controlled Car Project ACSE 2006

Adding Resistors

Each Resistor to Middle Pin

Each Resistor Jumps Divider

Page 18: Computer Engineering Remote Controlled Car Project ACSE 2006

Adding Grounds

Left Pin to Ground

Page 19: Computer Engineering Remote Controlled Car Project ACSE 2006

From D Sub-connector

From D sub

Blue GroundFrom D sub

Page 20: Computer Engineering Remote Controlled Car Project ACSE 2006

From D Sub-connector to BB

Pin 2 Orange

Pin 3 Orange/White

Pin 5 White/Green

Pin 4 Green

Pin 18 Ground

Page 21: Computer Engineering Remote Controlled Car Project ACSE 2006

Remote Controlled Car Project

Software

Page 22: Computer Engineering Remote Controlled Car Project ACSE 2006

Software 1

• When 8 is pressed the car should go forward

• When 5 is pressed the car should stop

• When 0 is entered the program should exit

Page 23: Computer Engineering Remote Controlled Car Project ACSE 2006

Software 1: Answervar key : string (1)

loop

getch(key)

if key = “8” then

parallelput(1)

elsif key = “5” then

parallelput (0)

end if

exit when key = “0”

end loop

Page 24: Computer Engineering Remote Controlled Car Project ACSE 2006

Software 2

Add to the previous program commands that will instruct the car to go:

• Forward/left when 7 is pressed• Forward when 8 is pressed• Forward/right when 9 is pressed• Stop when 5 is pressed• Reverse/left when 1 is pressed• Reverse when 2 is pressed• Reverse/right when 3 is pressed• Exit program when 0 is pressed

Page 25: Computer Engineering Remote Controlled Car Project ACSE 2006

Software 2: Answer

loop

getch(key)

if key = “7” then

parallelput(5)

elsif key = “8” then

parallelput (1)

elsif key = “9” thenparallelput (9)

etc

Page 26: Computer Engineering Remote Controlled Car Project ACSE 2006

Software 3

• Write a program so the car will auto parallel park

• Add computer controlled turn signals

• Add reverse lights

• Add light sensors so the car will follow a light source

Page 27: Computer Engineering Remote Controlled Car Project ACSE 2006

Addresses

[email protected]

www.classictechnology.ca

www.holtsoft.com