This manual applies to versions >1.00 of Freediag/Scantool.
Table of contents:
In the Mid 1990's the US introduced mandated diagnostics on all vehicles sold in the USA for certain emissions related information. The idea behind this is that cars would monitor for emissions related problems and when they occur to light a "Check Engine" lamp on the dashboard and log fault information that could be then read by a Scantool. Scantools would become cheap and available to the smallest of vehicle repairers. These diagnostic protocols were grouped under the term "OBD II".
Europe has recently introduced similar, compatible systems, which are known as EOBD (European OBD).
OBDII/EOBD requires a standardised physical connector to be present within a small distance of the vehicle’s steering wheel. OBDII allows 3 types of physical interface (ISO9141/14230, SAEJ1850 VPW and SAEJ1850-PWM) and the related software protocols that are used with those physical interfaces.
This manual assumes that you have some knowledge of vehicle systems and
have probably used a scantool before.
This Scantool uses SAEJ1979 (ODB II) protocol on ISO9141, ISO14230, SAEJ1850 VPW and SAEJ1850-PWM interfaces depending on what hardware interface is attached to the PC. The scantool does not yet support any manufacturer specific protocols for talking to non OBDII vehicles.
It is configured by default to use a generic (dumb) serial to ISO9141 converter such as those used on the VAG-COM software, It also supports smart interfaces from Multiplex Engineering and from B.Roadman for SAEJ1850 vehicles (mainly Ford and GM). Support for ELMxxx devices is being added but should be considered inexistant as of early 2014.
Support for CANbus (ISO 15765) is incomplete and unusable.
Please refer to the "supported interfaces" document to determine which
interface support what protocols.
Note that win32 is not supported at the moment. The scantool distribution is a source-code distribution, so you will have to configure/compile it for your Linux system. To do this, unpack the archive and in the src directory, type:
The Scantool should be run as SuperUser as the process has to set real-time scheduling in order to get accurate timing control under Linux. If it is run by an un-privileged user than a warning will be printed and the scantool may not work. It is extremely unlikely to work on ISO9141/ISO14230 interfaces, it may work with SAEJ1850 type interfaces where timing is not so critical.
Start the Scantool CLI by running "./scantool", you will get a command prompt:
The scantool will read commands from a startup file called .scantoolrc in your home directory or scantool.ini in the program directory, depending on options set at compile time (see ./configure --help).
Many people will put the appropriate
set interface <type>
command (see section 4) in their .scantoolrc file and will just want to use
scan, and the
The CLI is hierarchical, with normal commands at the top level. These commands include:
scan: start a scan
monitor: loop repeatedly checking/displaying ECU values
2nd level commands, such as commands to set the address used by the scantool, can be accessed as:
set testerid <value>
or by entering the set menu:
and then using the
Note the cli prompt will change from
To leave that menu and return to the main menu, type either:
quit command at the main menu will end the scantool
All numeric values can be entered as:
help command is available at every menu and gives you
help for the commands available at that menu. Further information about a
specific command can be obtained by typing
The CLI supports shell like command line editing if supported by your
The following commands are available. Other commands may be visible from the CLI but are not supported
||Does an OBDII Scan for all parameters|
||Loops requesting/displaying OBD - Mode 1/2/7 results|
||Clear stored Diagnostic Trouble Codes|
||Read commands from <filename>|
||Basic data logging to logfile specified|
||Watch the K line bus and attempt to decode data|
||SUBMENU, see later, perform various tests - mostly performed in scan process|
||SUBMENU, see later, set parameters for diagnostic functions|
||SUBMENU, see later, extended diagnostic functions|
||SUBMENU, see later|
||Do OBD Mode 9 requests for vehicle info (vin etc)|
||Request/Display continuously monitored system results|
||Request/Display non continuously monitored system results [more verbose than in scan]|
||Do readiness tests [more verbose than in scan]|
||Show all "setable" values|
||Shows/Sets the interface and device to use. Use set interface ? to get a list of names|
||Select simulation file to use as data input. See freediag_carsim_all.db for an example|
||Sets english or metric display|
||Shows/Sets the speed to connect|
||Shows/Sets the source ID for us to use|
||Shows/Sets the destination ID to connect|
||Shows/Sets the address type to use|
||Shows/Sets the hardware protocol to use. Use set l1protocol ? to get a list of protocols|
||Shows/Sets the software protocol to use. Use set l2protocol ? to get a list of protocols|
||Shows/Sets the initialisation mode to use. Use set initmode ? to get a list of protocols|
||Connect to an ECU, but do not run any tests. Uses the protocol/speed etc set, i.e does not try multiple protocols.|
||Send data on the bus|
||Read data from the bus, timeout after
||Show debug levels|
||Show/set layer 0 debug value|
||Show/set layer 1 debug value|
||Show/set layer 2 debug value|
||Show/set layer 3 debug value|
||Show/set layer cli debug value|
||Show/set debug values for all the layers|
||Show supported PIDS/TESTs for mode 1/2/5/6/9|
||Show received data for mode 1/2 tests|
||Available debug levels (combine by adding values) :
DIAG_DEBUG_OPEN 0x01 /* Open events */ DIAG_DEBUG_CLOSE 0x02 /* Close events */ DIAG_DEBUG_READ 0x04 /* Read events */ DIAG_DEBUG_WRITE 0x08 /* Write events */ DIAG_DEBUG_IOCTL 0x10 /* Ioctl stuff (setspeed etc) */ DIAG_DEBUG_PROTO 0x20 /* Other protocol stuff */ DIAG_DEBUG_INIT 0x40 /* Initialisation stuff */ DIAG_DEBUG_DATA 0x80 /* Dump data depending on other flags */ DIAG_DEBUG_TIMER 0x100 /* Timer stuff */
||Set the mass of the vehicle, including driver and passengers|
||Dynamically determine power lost by aerodynamic and friction forces (follow the instructions)|
||Manually enter aerodynamic and friction forces parameters|
||Run dyno (follow the instructions)|
||Display run results|
||Display run graphs|
||Save run measures and results to a file|
Please refer to the "supported" interface document to determine which hardware interface is appropriate for your usage and which version of the interface you should purchase.
In order to use the appropriate driver for your hardware interface, the
set interface XXX command needs to be run. The
default interface driver is the dumb driver which works with most
generic serial to ISO9141 interfaces. It is recommended that you put this
command in your .scantoolrc file.
Andy Whittaker's OBD-II ISO9141 interface:
set interface dumb
Jeff's OBD-II ISO 9141 interface:
set interface dumb
Silicon Engines ISO 9141 interface:
set interface dumb
B.Roadman ISO9141/VPW/PWM interface:
set interface br1
Multiplex Engineering VPW, PWM, and ISO 9141-2 interface:
set interface met16
Note, if you have a Multiplex Engineering interface not purchased for the
freediag software, it will have a different ID to that used in the freediag
project. Freediag uses ID 0x38. If you know the ID of your interface you can
INTERFACE_ADDRESS definition in diag_l0_me.c