F14: Team5-Self Driving Car - AUG

From Embedded Systems Learning Academy
Revision as of 23:15, 13 December 2014 by Proj user12 (talk | contribs) (Schedule)

Jump to: navigation, search

Self Driving Car

Fig 2. Build in Progress

Abstract

Objective and Scope

Team Members & Responsibilities

  1. Sensor Controller (2 Members) - [Bailey Wu, Rishabh Sareen]
  2. Motor Controller (2 Members) - [Abraham Ruiz, Sree Harsha, Arpit Amin]
  3. I/O Unit (2 Members) - [Yoni Klein, Tejeswar]
  4. Communication Bridge + Android (3 Members) - [Shaw Ken Chang, Arnold Bajet Jr., Thomas Pantels]
  5. Geographical Controller (3 Members) - [Himanshu Saini, Divya Kamath]
  6. Master Controller (3 Members) - [Akash Ayare, Sree Harsha, Karthik Vadiraja]

Introduction

Schedule

Geographical Controller

Sl. No Start Date End Date Task Status Actual Completion Date
1 1-Oct-2014 14-Oct-2014 Order Components and Make a schedule Completed 14-Oct-2014
2 8-Oct-2014 14-Oct-2014 Decide commands that Geographical Controller will support Completed 14-Oct-2014
3 7-Oct-2014 14-Oct-2014 Complete CAN RX task and subscription handling. Verify communication with other controllers Completed 21-Oct-2014
4 14-Oct-2014 24-Oct-2014 Interface GPS module and Compass and develop drivers if needed Completed 28-Oct-2014
5 24-Oct-2014 30-Oct-2014 Design and develop algorithm to calculate heading and bearing from GPS coordinates Completed. 30-Oct-2014
6 24-Oct-2014 5-Nov-2014 Work on calibration of compass and heading calculation In Progress
7 1-Nov-2014 10-Nov-2014 Test with the central and Bluetooth controller communication works. Working on steering algorithm in central using geo data
8 10-Nov-2014 25-Nov-2014 Begin testing with fully assembled car In Progress
9 25-Nov-2014 10-Dec-2014 Final Testing and changes as needed


Sensor Controller

Sl. No Start Date End Date Task Status Actual Completion Date
1 10/3/2014 10/10/2014 Order ultrasonic sensor parts and develop simple test code for the sensors Done 10/10/2014
2 10/10/2014 10/17/2014 Wire the ultrasonic sensors, develop and implement the sensors using analog to digital converter Done 10/17/2014
3 10/17/2014 10/24/2014 Collaborate with the other sub teams to finish the CAN bus communication and allow the self driving car to drive autonomously Done 10/24/2014
4 10/24/2014 11/1/2014 Develop, implement and test the ultrasonic sensors using the pulse width modulation and universal asynchronous receiver/transmitter Done 11/1/2014
5 11/2/2014 11/9/2014 Develop, implement and test the front and back infrared sensors using analog to digital converter Done 11/9/2014
6 11/10/2014 11/17/2014 Develop, implement and test the current/voltage sensor for the battery packs of the self driving car using I2C Delayed TBD
7 11/18/2014 11/25/2014 Collaborate with the other sub teams to make sure that the sensors are in working condition Done 11/25/2014
8 11/26/2014 12/5/2014 Collaborate with the other sub teams to debug any problems that may encountered Done 12/5/2014
9 12/6/2014 12/13/2014 Prepare for Demo Scheduled


IO Controller

Sl. No Start Date End Date Task Status Actual Completion Date
1 10/7/2014 10/14/2014 Research and order LCD appropriate for this project Finished 10/11/2014
2 10/7/2014 10/17/2014 Implement CAN RX/Subscription task Finished 10/13/2014
3 10/7/2014 10/17/2014 Finalize Task Architecture In Progress
4 10/18/2014 10/21/2014 Interface and test LCD Finished 10/20/2014
5 10/21/2014 10/28/2014 Implement special button features
6 10/21/2014 10/28/2014 Implement auto scrolling feature
7 10/28/2014 11/4/2014 Design LCD UI with buttons


Communication Bridge + Android

Sl. No Start Date End Date Task Status Actual Completion Date
1 16-Sep-2014 23-Sep-2014 Test bluetooth module using computer serial port and an android app(simple bluetooth terminal app downloaded from google play). Test the real life range and stability of the bluetooth module (HC-06). Modify the bluetooth chat example to work with the bluetooth module. Done 20-Sep-2014
2 28-Sep-2014 12-Oct-2014 Draw UI design layouts for a basic android application that can view Google map as well as send GPS data through bluetooth by clicking on the map. Study google maps API and make a simple app that will post a short toast that shows the GPS location after a long press event. Done 12-Oct-2014
3 7-Oct-2014 11-Oct-2014 Interface bluetooth module with SJSUOne board and able to verify that the connection is stable and that transaction via the bluetooth is accurate. This is done by adding a test button where if you press the button it send a command to the board. After receiving the command, the board should react with a response (LED light and/or text response to the android phone) Done 19-Oct-2014
4 11-Oct-2014 19-Oct-2014 Integrate Google Maps and Bluetooth component together in Android app. After a long press on the map, the user should be prompted to start the car and set the location as the places the user selected. Add a textView to display the location selected by pressing on the map. Add a button for sending location to the car. Done 27-Oct-2014
5 19-Oct-2014 26-Oct-2014 CAN infrastructure implmentation: Use our team's common CAN infrasturcture code and modify it specifically for our controller. First created the CAN communication table and then modify the infracturacture code to implement the broacasting as well as filtering of neccessary data. This only focuses on broadcasting a stop/start command and the destination GPS data (set by android) as well as getting car's current location data from the geological controller. Done 07-Nov-2014
6 26-Oct-2014 1-Nov-2014 Test and implement car information reading as well as other functions of Android app In Progress
7 2-Nov-2014 4-Nov-2014 Iterate UI design In Progress
8 5-Nov-2014 16-Nov-2014 Implement 2nd UI design In Progress


Motor Controller

Sl. No Start Date End Date Task Status Actual Completion Date
1 10/1/2014 10/8/2014 PWM2 (used to control motors) and PWM3 (used to control servo) interface with the car servo and motor. Write a test code to operate the servo and motor from the terminal command. Completed and Tested 10/11/2014
2 10/9/2014 10/18/2014 Design and code CAN receive task for subscription. Check for basic CAN message commands for throttle and steer control. Completed and tested 10/26/2014
3 10/19/2014 10/28/2014 Design the CAN message table for motor control and servo control Completed and tested 10/26/2014
4 10/29/2014 11/07/2014 Design acceleration Vs steer control function for smooth run. Check for other factors involved. Completed and tested 11/22/2014
5 11/08/2014 11/14/2014 Research on RPM sensor. Interface the RPM sensor to calculate the Speed. Test the RPM sensor by running the car at different speed Code completed, but rpm task needs to be tested in the car. Completed and tested with a hall sensor 11/22/2014
6 11/15/2014 11/21/2014 Fine tune motor control code and integrate with all the controllers for proper working. In Progress. Servo is working with the same behavior using the can_rx and terminal task; however, motors needs more testing. Completed and tested 11/22/2014
7 11/22/2014 11/28/2014 Test and check if more features can be added to improve performance. Completed and tested In Progress.
8 11/29/2014 12/05/2014 Final Testing and Debugging before the Demo day Planned

Central Controller

Sl. No Start Date End Date Task Status Actual Completion Date
1 16-Sep-2014 23-Sep-2014 Develop API for CAN bus communication. Done 23-Sep-2014
2 11-Oct-2014 15-Oct-2014 Develop communication table for all controllers. In Progress
3 15-Oct-2014 20-Oct-2014 Broadcast message and target message setup. In Progress
4 21-Oct-2014 28-Oct-2014 Co-ordinate all controllers and take major decisions. Planned
5 28-Oct-2014 11-Nov-2014 Complete Building and fine-tuning of RC car. Planned
6 21-Oct-2014 11-Nov-2014 Develop coordination mechanism to ensure controllers are initialized and ready In Progress
7 21-Oct-2014 28-Oct-2014 Develop kill switch In Progress
8 14-Oct-2014 21-Oct-2014 Build external power distribution circuit Done 21-Oct-2014
9 28-Oct-2014 04-Nov-2014 Coordination algorithm between steering and throttle for smooth turns Planned
10 04-Nov-2014 11-Nov-2014 Collision avoidance and cliff detection algorithms Planned
11 04-Nov-2014 11-Nov-2014 Intermediate unit and functional tests Planned
12 21-Oct-2014 4-Nov-2014 Initialize all boards with GPS-time Planned
13 11-Nov-2014 25-Nov-2014 Functional tests and algorithm adjustments Planned
14 25-Nov-2014 02-Dec-2014 Fine tuning and stretch goals (headlights, parallel parking, etc.) Planned
15 02-Dec-2014 09-Dec-2014 Prepare for demo Planned

Parts List & Cost

Qty Description Manufacturer Part Number Total Cost

Backup Parts & cost

Qty Description Manufacturer Part Number Total Cost

Design & Implementation

Controller Communication Table

Controller ID Table
Controller ID Controller
0x01 Master Controller
0x02 Geographical Controller
0x03 Motor Controller
0x04 Sensor Controller
0x05 IO Controller
0x06 Communication (Bluetooth Bridge/Android App) Controller
Central Controller Communication Table
Sl. No Message Number Purpose Data layout
1 0x501 Send Throttle and steering to motor throttle

steering

2 0x502 Start car
3 0x503 Stop car
4 0x101 Broadcast request revision
5 0x102 Broadcast Set time
6 0x103 Request TX count (broadcast)
7 0x104 Request RX count (broadcast)
8 0x105 Send TX count (LCD)
9 0x106 Send RX count (LCD)
10 0x107 All controllers initialize
Communication (Bluetooth Bridge/Android App) Controller Communication Table
Sl. No Message Number Purpose Data layout
1 0x301 Broadcast Start command
2 0x302 Broadcast Stop command
3 0x303 Broadcast GPS destination set by Android byte [0-3] : (float), Longitude

byte [4-7] : (float), Latitude

Sensor Controller Communication Table
Sl. No Message Number Purpose Data layout
1 0x501 Broadcast front sensors values byte[0]: Right ultrasonic sensor value in inches

byte[1]: Front ultrasonic sensor value in inches

byte[2]: Left ultrasonic sensor value in inches

byte[3]: Front bottom infrared sensor value in inches

2 0x502 Broadcast back infrared sensor value byte[0]: Back infrared sensor value in inches
3 0x503 Broadcast battery sensor value byte[0]: current/voltage sensor value in percentage
4 0x504 Broadcast light sensor value byte[0]: light sensor value as integer
5 0x505 Broadcast tilt sensor value byte[0]: X-Axis tilt sensor value as integer

byte[1]: Y-Axis tilt sensor value as integer

byte[2]: Z-Axis tilt sensor value as integer

Motor/Servo Controller Communication Table
Sl. No Send Code Description Data
1 0x201 Heartbeat data Controller id 1 byte
2 0x201 Heartbeat data Controller id 1 byte
3 0x201 Heartbeat data Controller id 1 byte
4 0x202 Mem info data Sys-mem remaining 4bytes
5 0x501 RPM data send RPM (2 bytes)
6 0x502 Speed data send Speed (2bytes)
Sl. No Receive Code Description Response
1 0x300 Kill Receive only
2 0x301 Stop Receive only
3 0x302 Straight Receive only
4 0x307 move forward 25% Receive only
5 0x30C move forward 50% Receive only
6 0x311 move forward 75% Receive only
7 0x315 move forward 100% Receive only
8 0x31A move backward 25% Receive only
9 0x31F move backward 50% Receive only
10 0x324 move backward 75% Receive only
11 0x329 move backward 100% Receive only
12 0x334 Steer right 25% Receive only
13 0x339 Steer right 50% Receive only
14 0x33E Steer right 75% Receive only
15 0x343 Steer right 100% Receive only
16 0x348 Steer Left 25% Receive only
17 0x34D Steer left 50% Receive only
18 0x352 Steer left 75% Receive only
19 0x357 Steer left 100% Receive only
Io Controller Communication Table
Sl. No Message Number Purpose Destination
1 0x301 Start command for car Central Controller
2 0x302 Stop command for car Central Controller
3 0x303 Go to a predefined Destination. Central Controller
Geographical Controller Communication Table
Message Number Message Type Purpose Data layout
0x0301 Get Geo Data Request for GPS Data (lat,long)
0x0302 " Request for current compass heading and destination heading
0x0304 " Request Time
0x0601 Response to 0x3xx request GPS Data (lat,long)
dword[0] : [32-bit latitude]
dword[1] : [32-bit longitude] 
0x0602 " Compass heading and destination bearing
dword[0] : [32-bit compass heading]
dword[1] : [32-bit destination bearing] 
0x0504 " Time
dword[0] : [32-bit time 0x00hhmmss]
0x0501 Periodic Message GPS data, broadcast periodically
dword[0] : [32-bit longitude]
dword[1] : [32-bit latitude]  
0x0502 " Current and destination heading broadcast periodically
dword[0] : [32-bit compass heading]
dword[1] : [32-bit bearing]

Testing & Technical Challenges

Sl. No Test Case Test Description Result

Challenges and Learning

Future Enhancement

Conclusion

Project Video

Project Source Code

References

Acknowledgement

References Used

  1. Preetpal Kang, Lecture notes of CMPE 243, Computer Engineering, Charles W. Davidson College of Engineering, San Jose State University, Aug-Dec 2014.
  2. en.wikipedia.org/