Skip to content
EQMOD edited this page Oct 17, 2023 · 1 revision

Welcome to the EQM_OBDWEB wiki!

image# 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:

http://192.168.0.10/

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.

image

Here is the Connection diagram from the ESP32 Wrover with SD Card Reader and JDY08 BLE Module

image

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.

image

image

SAMPLE WEBUI RENDERS;

Homepage;

image

OBDII Screen (Screenshot using data from an OBDII Emulator)

image

TPMS (Tire Pressure Monitoring Screen)

image

Battery Monitor via BM2 BLE Broadcasts. Other Battery data is also possible

image

ESP32 LOAD Monitoring Screen

image

Sample 3D Printed OBD Dongle (3d files/stl included in the respository)

image

How to flash the esp32 itself ;

image

Using an "ESP32 Downloader"

image

CC2541 JDY08 BLE Module Firmwares

image

TPMS VC601 Broadcast emulator for testing the cc2541 codes uing a CCDebugger

image

Firmware Source ( You need IAR to compile these)

https://github.com/EQMOD/EQM_OBDWEB/tree/main/CC254x_TPMS_BATMON/Custom%20JDY08-CC2541%20Firmware%20TPMS%20BATMON/SDK/BLE-CC254x-1.4.0/Projects/ble/TPMSBroadcast_Tester

JDY08 Firmware source codes to receive BLE VC601 TPMS Sensor broadcasts and presented to the ESP32 via UART

https://github.com/EQMOD/EQM_OBDWEB/tree/main/CC254x_TPMS_BATMON/Custom%20JDY08-CC2541%20Firmware%20TPMS%20BATMON/SDK/BLE-CC254x-1.4.0/Projects/ble/TPMS_OBD

COMPILING and FLASHING

This version of the program works best with a ESP32-D0WD-V3 (revision 3) 16MB with the following compile settings;

image

Formatting and Flashing the SPIFF Memory is initiated by checking if a detected/attached SD Card is without a "lock.file" inside;

image

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;

image

JDY-16 Module for Bluetooth UART Console Port Monitoring

image

Connection Diagram

image

Mobile APP with the Serial Console Data

image

Flasher and JDY-16 modules both fit on the same flashing port on the EQM_OBDWEB Dongle

image

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....

image

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)

image

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

image

Clone this wiki locally