-
Notifications
You must be signed in to change notification settings - Fork 125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Protocol Data Point #232
Comments
use |
I would also like to know which protocol is actually used by the ELM327 to communicate with the vehicle. I am using ESP32 + Vgate iCar2. When using ELM responded with error "UNABLE TO CONNECT"
Setting protocol via AT TP A%c did not work - trying via AT SP %c
Clearing input serial buffer
Sending the following command/query: AT SP 0
Received char: O
Received char: K
Received char: \r
Received char: \r
Received char: >
Delimiter found.
All chars received: OK
Setting protocol via AT SP %c did not work
Connected to ELM327
Clearing input serial buffer
Sending the following command/query: AT DP
Received char: A
Received char: U
Received char: T
Received char: O
Received char: \r
Received char: \r
Received char: >
Delimiter found.
All chars received: AUTO When using ELM responded with error "UNABLE TO CONNECT"
Setting protocol via AT TP A%c did not work - trying via AT SP %c
Clearing input serial buffer
Sending the following command/query: AT SP 0
Received char: O
Received char: K
Received char: \r
Received char: \r
Received char: >
Delimiter found.
All chars received: OK
Setting protocol via AT SP %c did not work
Connected to ELM327
Clearing input serial buffer
Sending the following command/query: AT DPN
Received char: A
Received char: 0
Received char: \r
Received char: \r
Received char: >
Delimiter found.
All chars received: A0 |
After setting the auto protocol (ATSP0 or ATTP0), you also need to make a request to initiate the protocol search and then wait for the protocol negotiation to complete. Easiest way to do that is to send command "0100". Once that returns, you can check which protocol was negotiated. |
@jimwhitelaw THX! I also learnt the way to get the data returned by sendCommand_Blocking, the way of sendCommand should be similar, right? The example code is as follows, others can refer to: char obdProtocolCode = 0;
......
myELM327.sendCommand_Blocking("0100");
if (myELM327.nb_rx_state == ELM_SUCCESS) {
myELM327.sendCommand_Blocking("ATDPN");
if (myELM327.nb_rx_state == ELM_SUCCESS) {
myELM327.get_response();
obdProtocolCode = myELM327.payload[1];
}
}
Serial.println("OBD Protocol: " + String(obdProtocolCode)); |
Hello everyone
With which data point can I see which protocol the ELM327 communicates with the vehicle?
I would like to see which protocol is used.
Best regards
The text was updated successfully, but these errors were encountered: