this help me to begin with
http://en.wikipedia.org/wiki/OBD-II_PIDs
these are the standard modes
Mode (hex) Description
01 Show current data
02 Show freeze frame data
03 Show stored Diagnostic Trouble Codes
04 Clear Diagnostic Trouble Codes and stored values
05 Test results, oxygen sensor monitoring (non CAN only)
06 Test results, other component/system monitoring (Test results, oxygen sensor monitoring for CAN only)
07 Show pending Diagnostic Trouble Codes (detected during current or last driving cycle)
08 Control operation of on-board component/system
09 Request vehicle information
0A Permanent Diagnostic Trouble Codes (DTCs) (Cleared DTCs)
so normally you want mode 01
so torque send
21 and 22 is the bit of the same as 01 but a bit less standard
this is the one a use
i ask for 2101
if you do TEST in the PID you will see what is the full answer to that request
in my case
the response is a bunch of line
i start with 06101 to say it a response to 2101,,it add 40 to the request so 6101
after that you need to know a bit for what you are looking for
A is the value of the next 2 digit, B the 2 after that ect
in my case the response was five row
and the response was way back there
in my case it was to get boost pressure to find it i used a 10k trim pot instead of the sensor and was moving value from 0 to 5V so i could see the full range
my math was ((45.6124/1023)*(O+P*256))-([33]*0.14503)
in my case the response is in two byte O and P
O increase from 0 to FF (255) and the roll over to 0 but P increase of 1
sometime you lucky and the value get out in standard form
in my case it was not
45.6125 is the psi range of the sensor (3 bar so 0 to 45.6125 psi)
divided by 1023…when i was at max it would gave me 1023 and 1024 is common any way like 255
O+P*255 to get the current result
[33] if found in torque while playing it’s atmopherique pressure in kpa i think…multiply by 0.14503 to put in psi
so like that i have neg value in vaccum and plus in boost
before i did that i even did some trick with my arduino…
i was reading the 0-5V signal from the sensor
and using torque to request an adress with no response, the arduino was responding instead of the pcm…torque was good with that lol he had a response…
|