This is Ben and I's final project for Embedded Systems. Our goal was to create a car diagnostic system that interfaces with the CAN bus in all US sold cars newer than 2008. We aimed to request data such as RPM, Vehicle speed, engine temp, etc and then display our findings. This software was succussful in communicating with the car and reading and writing, however it fails to accomplish it's task when dealing with certain makes of cars, specifically Honda. Included are various PID codes, functions, and files that interface with a car's CAN bus system.

Dependencies:   UniGraphic mbed

Committer:
Nrode17
Date:
Wed Jan 27 17:40:51 2016 +0000
Revision:
0:bb9076ae4c4a
Final Update for our final project

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Nrode17 0:bb9076ae4c4a 1 #ifndef ODBII_H
Nrode17 0:bb9076ae4c4a 2 #define ODBII_H
Nrode17 0:bb9076ae4c4a 3
Nrode17 0:bb9076ae4c4a 4 #include "mbed.h"
Nrode17 0:bb9076ae4c4a 5 //Can Speed
Nrode17 0:bb9076ae4c4a 6 #define CANSPEED_125 125000
Nrode17 0:bb9076ae4c4a 7 #define CANSPEED_250 250000
Nrode17 0:bb9076ae4c4a 8 #define CANSPEED_500 500000
Nrode17 0:bb9076ae4c4a 9 //These are used to define the different PID codes as well as other codes
Nrode17 0:bb9076ae4c4a 10 #define ENGINE_COOLANT_TEMP 0x05
Nrode17 0:bb9076ae4c4a 11 #define ENGINE_RPM 0x0C
Nrode17 0:bb9076ae4c4a 12 #define VEHICLE_SPEED 0x0D
Nrode17 0:bb9076ae4c4a 13
Nrode17 0:bb9076ae4c4a 14
Nrode17 0:bb9076ae4c4a 15 #define PID_REQUEST 0x7DF
Nrode17 0:bb9076ae4c4a 16 #define PID_REPLY 0x7E8
Nrode17 0:bb9076ae4c4a 17 //the two functions
Nrode17 0:bb9076ae4c4a 18 float request(char pid);
Nrode17 0:bb9076ae4c4a 19 void set_frequency(int amount);
Nrode17 0:bb9076ae4c4a 20
Nrode17 0:bb9076ae4c4a 21 #endif