Skip to content
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

How to read DTC codes ? #14

Open
thanhhai16 opened this issue May 28, 2018 · 8 comments
Open

How to read DTC codes ? #14

thanhhai16 opened this issue May 28, 2018 · 8 comments

Comments

@thanhhai16
Copy link

thanhhai16 commented May 28, 2018

Hi, i'm new to this field and thanks for amazing library. My car now can connect to your demo app, but i don't know how to read DTC code from my car ?

Can someone give me some example pls

@thdankert
Copy link
Contributor

thdankert commented Aug 14, 2018

If you already have a connection to your car, you can get the DTCs by sending the appropriate PIDs and parsing the response.

  • LTOBD2PID_PERMANENT_DTC_0A
  • LTOBD2PID_PENDING_DTC_07
  • LTOBD2PID_STORED_DTC_03

The exact command depends on the kind of DTC you want to read, as there may be some only relevant to a freeze frame, or some are stored permanently due to repeated errors.

Either way, if there are DTC reported, the response will have an array troubleCodes which contains LTOBD2DTC. These have a code and an explanation.

If the explanation is empty, it's probably a manufacturer-defined code: These are usually explained in your car maker's service/workshop manual.

@janessbach
Copy link

Is there also the possibility to delete the error codes?

@mickeyl
Copy link
Owner

mickeyl commented Jun 12, 2019

Yes, sending LTOBD2PID_CLEAR_STORED_DTC_04 will reset the MIL and erase the stored DTCs.

@mukulpandey57
Copy link

mukulpandey57 commented Aug 24, 2020

Hello @mickeyl , @thdankert
I am getting incorrect DTC in my code using this Library.
From Other App i am getting "P0441","P0442","P0446" and in my app using LTSupportAutomotive i am getting "C0104" "C0204"
Please help it's urgent.
Screenshot 2020-08-24 at 2 22 21 PM
Screenshot 2020-08-24 at 2 23 23 PM

@thdankert
Copy link
Contributor

@mukulpandey57 Is your issue related to this one? The OP asked for general information on using this library to read DTCs - he probably moved on, as this issue has not seen any activity in over a year...

Regarding your question: which DTCs does the other app read, and which ones did you read using this library? There are 3 different PIDs for reading them:

  • LTOBD2PID_PERMANENT_DTC_0A
  • LTOBD2PID_PENDING_DTC_07
  • LTOBD2PID_STORED_DTC_03

@mukulpandey57
Copy link

@thdankert , Thanks for your quick response. I was using all three PID ($03, $07,$0A) and only getting the C Codes and other wired scanner and apps getting the P Codes. Please assist.

Seems like something related to this #31

Screenshot 2020-08-24 at 2 47 07 PM
Screenshot 2020-08-24 at 2 46 57 PM
Screenshot 2020-08-24 at 2 46 51 PM
Screenshot 2020-08-24 at 2 46 35 PM
Screenshot 2020-08-24 at 2 46 44 PM

@thdankert
Copy link
Contributor

I'm afraid I am unable to assist you there. I don't know anything about your car, the code you wrote, and how the other applications read DTCs.

@Nikhil-Quadrish
Copy link

How to clear the DTC code ? "LTOBD2PID_CLEAR_STORED_DTC_04" any more explanation to this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants