-
Notifications
You must be signed in to change notification settings - Fork 21
Home
Welcome to the EQM_OBDWEB wiki!
# EQM_OBDWEB A WEB Based or Wifi/BLE (EL327 Compatible) OBDII Dongle Platform using the ESP32 WROVER Module
An OBDII Dongle using the ESP32 Wrover with built-in SPIFFF memory is used as a CAN BUS OBDII reader and the data is presented as web page using a built-in webserver. The Webpage communicates to the dongle via WiFi and Websockets, ESP32 is a dual core microcontroller with the first core handling the CAN Bus Comunications part, and the 2nd core handling the websocket part. OBDII data is pushed to the UI ever 60ms to 100ms for critical data such as rpm and speed and every 1000ms for not so critical data such as temp, voltage, etc. Using ESP32 RTOS for the multi core multi tasking component. That's basically a webserver running inside that diy dongle attached to the car's obd port. And literally you can read every car metric data and show it on the infotainment with customizable fancy UI stuff (gauges, graphs, etc.) using standard HTML/JS/CSS/JPG renders.
Mobile phone apps not required as long as the infotainment/mobilephone/etc can render the UI using a standard webbrowser.
Once the UI client is connected to the ESP32 via WIFI, Webserver can be accessed via these urls;
OBD HomePage:
ESP32 Load Monitoring
http://192.168.0.10/page?var=file&val=/ui/CPULoad/index.html
WEB ASSETS are stored in the ESP32 SPIFFS memory storage which is automatically populated one time from the data on the SD Card. A SPIFF memory update is triggred by deleting the lock.file on the SD card. Any updates on the WEBSERVER files should be done on the SD card with the "lock.file" deleted.
There are two BLE modules used for this project. The first BLE/Bluetooth Module built in with the ESP32 is used as the Bluetooth connector for the OBDII dongle and can be used to to connect to Mobile OBDII apps such as TORQUE.
The 2nd Bluetooth/BLE module a JDY-08 contains a user programmable CC2541 BLE Chipset which can be used to receive Car sensor data that are bluetooth based. DEMO CC2541 codes are provided to receive BLE Advertisments from TPMS Sensors such as the Bluetooth based VC601 Tire Pressure Sensors or a Battery Monitoring Sensor (BM2). The same BLE module can be loaded with a UART-BLE for ELM327 AT command compatible communication.
Here is the Connection diagram from the ESP32 Wrover with SD Card Reader and JDY08 BLE Module
And here is the suggested development platform (codes included) which provide the user options to burn firmware on the CC2541 by simply dropping a cc2541.bin file on the SD card.
SAMPLE WEBUI RENDERS;
Homepage;
OBDII Screen (Screenshot using data from an OBDII Emulator)
TPMS (Tire Pressure Monitoring Screen)
Battery Monitor via BM2 BLE Broadcasts. Other Battery data is also possible
ESP32 LOAD Monitoring Screen
Sample 3D Printed OBD Dongle (3d files/stl included in the respository)
How to flash the esp32 itself ;
Using an "ESP32 Downloader"
CC2541 JDY08 BLE Module Firmwares
TPMS VC601 Broadcast emulator for testing the cc2541 codes uing a CCDebugger
Firmware Source ( You need IAR to compile these)
JDY08 Firmware source codes to receive BLE VC601 TPMS Sensor broadcasts and presented to the ESP32 via UART
COMPILING and FLASHING
This version of the program works best with a ESP32-D0WD-V3 (revision 3) 16MB with the following compile settings;
Formatting and Flashing the SPIFF Memory is initiated by checking if a detected/attached SD Card is without a "lock.file" inside;
ON-SITE DEBUGGING
A portable flasher and Serial Console Monitoring port in one as implemented on the EQM_OBDWEB Dongle. The idea here is we use the same 6 pin port to flash new code on the ESP32 inside the obd dongle OR use it as Serial Console port by plugging in a JDY-16 Bluetooth UART module and connect it to a mobile app BLE Serial Terminal and monitor the ESP32 activity through a mobile phone;
JDY-16 Module for Bluetooth UART Console Port Monitoring
Connection Diagram
Mobile APP with the Serial Console Data
Flasher and JDY-16 modules both fit on the same flashing port on the EQM_OBDWEB Dongle
DEVELOPMENT ENVIRONMENT
The Development Environment basically is a multiple Instance of the OBD ESP32 Dongles - One with loaded code functioning as an OBDII-Simulator (code included in the repository), A Dummy OBD--II Node (To simulate CAN BUS Traffic) and the EQM_OBDWEB ESP32 OBDII Dongle. The Dummy OBDII CAN Bus node is just the same code as the EQM_OBDWEB with a different WIFI/BLE name and it doesn't wait for CAN BUS Activity. The EQM_OBDWEB waits for CAN BUS Activity specifically to put it in SLEEP MODE (Power Management). This one needs more improvement as we are still trying to find options to lessen the the power consumption if in case we decide to leave the dongle attached to the OBDII port of the car....
and YES!! you can technically use any ESP32 Board such as a ESP32-CAM as an OBDII Dongle (but you need to check the memory specs)
Here is one Example of an ESP32-CAM Board used as an OBD-II Emulator and its flashing LED as an indicator for CAN BUS Activity :-D