Close
0%
0%

OBD2 CAN PIC16F876A

Display live on TFT 12 sensors

Similar projects worth following
This project is suitable for cars with OBD2 CAN protocol ISO 15765 11 bits 500 Kb/s, most cars have this protocol. The application reads data of the ECU . The app all 12 common PIDs are displayed on one screen.

TFT screen is 160x128 pixels, 1.8 inch with ST7735 driver.
The MCP2515 module drives the CAN BUS. The circuit supply is from the car 12V , 5V regulator generates the 5V for the TFT and MCP2515. Setting up filters in the MCP2515 is for allowing only 7DF messages to be read by the PIC.
The code requests the data every second. The request is an address 7DF, number of bytes, service #, PID and padding 5 bytes of 0x55. The reply from the ECU is address 7E8, number of bytes, 0x41, PID and 2 bytes of data. The data is calculated.
The C code is migrated from Arduino lib, C++ was changed to C so it can be compiled by free XC8 in MPLABX.

OBD2_PIC16F876A.zip

code for MPLABX

x-zip-compressed - 97.54 kB - 03/06/2024 at 18:30

Download

View all 8 components

  • 1
    Step 1

    Circuit

View all instructions

Enjoy this project?

Share

Discussions

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates