Computer Engineering Remote Controlled Car Project ACSE 2006 Graham Smyth Jerry Dolata
Computer Engineering Units 1. Hardware 2. Networking 3. Integrated Circuits 4. Programming 5. Interfaces Grades Five Hands-0n Units
Software Turing parallelput ( number) put parallelget mousewhere ( x, y, click) play (“CDEFG”) drawline ( x1, y1, x2, y2, red) Provincially Licensed
Parallelport Pin Configuration (printer port) View from back of Computer Output D0 – D7 Input I0 – I3 Input I4 Grounds
D sub Pin Assignment pinfunctionparallelput 2forward1 3reverse2 4left4 5right8 18ground
parallelput(number) NumberD7D6D5D4D3D2D1D parallelput(4) parallelput(5) parallelput(255)
Colour Code for Cables WireColourFunctionD Subparallelput 1OrangeForwardPin 21 2Orange/ WhiteReversePin 32 3GreenLeftPin 45 or 6 4Green/WhiteRightPin 59 or 10 5BlueGroundPin 18
Breadboard Connections Connected High Fives Divider Low Fives
Remote Controlled Car Project Hardware
Removing Shipping Holders 1. Remove Screw 2. Remove Screw
Removing Battery Covers 1. Remove Screw 2. Remove Screw 4. Insert 1 9V 3. Insert 4 AA
Opening Case Carefully Remove 10 Small Screws
Removing Joysticks Separate Case Remove Joysticks
4 Pair From Joystick 1. Green/White2. Green 3. Blue 4. Orange 5. Orange/White Carefully Wrap 5 Wires to Board
Closing Case Removing Battery Covers Use 2 Screws in Opposite Corners to Close Case Wrap to Secure Cable Antenna Inserted
4 Pair Wire to Transistors Orange to Right Pin Orange/White to Right Pin Green to Right Pin White/Green to Right Pin Blue to Ground
Adding Resistors Each Resistor to Middle Pin Each Resistor Jumps Divider
Adding Grounds Left Pin to Ground
From D Sub-connector From D sub Blue Ground From D sub
From D Sub-connector to BB Pin 2 Orange Pin 3 Orange/White Pin 5 White/Green Pin 4 Green Pin 18 Ground
Remote Controlled Car Project Software
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
Software 1: Answer var 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
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
Software 2: Answer loop getch(key) if key = “7” then parallelput(5) elsif key = “8” then parallelput (1) elsif key = “9” then parallelput (9) etc
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
Addresses