Read VIN from OBD adapter

17.6k views Asked by At

i'm working on this app which requires me to read the VIN from the OBD II adapter and check if OBD is connected to the same vehicle. When i'm sending the command(09 02) to fetch VIN i'm not able to get the complete VIN.

Every time i send the command i'm not receiving first 3 characters. The only thing i receive is the last 7 characters of the VIN, and sometimes i get the previous 7 characters.

Not able to figure out whats wrong.

Any kind of help or support will be much appreciated.

3

There are 3 answers

0
iCoder On

I was also not able to get VIN number response. We were getting VIN number from some of the cars but not from all . Then after we came to know that every car manufacturer doesn't provide support for VIN number. We had also implemented for VIN number decoding by just sending command "0902\r" and whatever response we get, was parsed as mentioned in the below mentioned url. I had checked for supported PIDs of mode 9 by sending 0100 command also

http://elmelectronics.com/DSheets/ELM327DS.pdf

Can you please update me how you got the response for VIN number using bluetooth obd2 device. I am using obd2 plx kiwi2wifi device.

So I don't think that you get VIN number response from all the cars.

See my question

Unable to Get VIN Number response from OBD-2 Device, reply me if you have got the solution

1
Dragomir Goranov On

Yes, not every manufacturer supports this command ($09 $02) for reading the VIN. Different manufacturers use different commands. Please, provide more detailed information, so that you can receive a good answer:

  1. What is the vehicle that you are connecting to?
  2. What is the communication protocol (KWP 2000, UDS, CAN, K-Line, J1850...) ?
  3. What device are you using to communicate with the vehicle?
  4. With which control unit exactly are you trying to communicate?
2
mohsen_og On

This post is a bit old but might be helpful to others!

VIN is usually around 20 characters. In CAN protocol since each message data content is limited to 8 bytes, therefore it should be sent in more than one messages (depends on the answer).

Firstly you should send a message to controller, then controller will response with first frame (FF) and then you should send a flow control message (FC) to tell the controller to send the other data. This is the procedure for multi-frame messages in CAN protocol. Here is my the post which I answered it for MCP2515. The procedure is same for other devices since it is the CAN Bus protocol.

Feel free to ask any questions!