Difference between revisions of "OBDLink LX"

From BITPlan can4eve Wiki
Jump to navigation Jump to search
Line 1: Line 1:
 +
__NOTOC__
 
[[File:OBDLinkLX .jpg|400px]]
 
[[File:OBDLinkLX .jpg|400px]]
 +
Connection: Bluetooth
 
= Identification =
 
= Identification =
 
<source lang='bash'>
 
<source lang='bash'>
Line 16: Line 18:
 
13.4V
 
13.4V
 
</source>
 
</source>
= Connecting to an OBDLink LX from Linux =
+
= Usage =
 +
 
 +
== Connecting to an OBDLink LX from Linux ==
 
the following was tested on a Raspberry PI
 
the following was tested on a Raspberry PI
  
== Bluetooth pairing with bluetoothctl ==
+
=== Bluetooth pairing with bluetoothctl ===
 
<source lang='bash'>
 
<source lang='bash'>
 
bluetoothctl
 
bluetoothctl
Line 43: Line 47:
 
</source>
 
</source>
  
== Setting up an rfcomm device ==
+
=== Setting up an rfcomm device ===
 
<source lang='bash'>
 
<source lang='bash'>
 
sudo rfcomm bind rfcomm0 00:04:3E:9F:A3:C0
 
sudo rfcomm bind rfcomm0 00:04:3E:9F:A3:C0
Line 50: Line 54:
 
</source>
 
</source>
  
== Testing ==
+
=== Testing ===
 
<source lang='bash'>
 
<source lang='bash'>
 
minicom -D /dev/rfcomm0 115200
 
minicom -D /dev/rfcomm0 115200
 
</source>
 
</source>
  
== Testing with a python script ==
+
=== Testing with a python script ===
 
<source lang='bash'>
 
<source lang='bash'>
 
python3 source/java/can4eve/scripts/obdtest.py  
 
python3 source/java/can4eve/scripts/obdtest.py  
Line 84: Line 88:
 
</source>
 
</source>
  
== Forwarding the OBDII Adapter via TCP/IP ==
+
=== Forwarding the OBDII Adapter via TCP/IP ===
 
<source lang='bash'>
 
<source lang='bash'>
 
python source/java/can4eve/scripts/tcp_serial_redirect.py --debug -P 7000 /dev/rfcomm0 115200
 
python source/java/can4eve/scripts/tcp_serial_redirect.py --debug -P 7000 /dev/rfcomm0 115200

Revision as of 05:42, 23 June 2017

OBDLinkLX .jpg Connection: Bluetooth

Identification

>AT I
ELM327 v1.3a

>AT @1
SCANTOOL.NET LLC

>STDI
OBDLink LX BT r1.2

>STI
STN1155 v4.0.0
>AT RV
13.4V

Usage

Connecting to an OBDLink LX from Linux

the following was tested on a Raspberry PI

Bluetooth pairing with bluetoothctl

bluetoothctl
agent on
scan on
Discovery started
...
[NEW] Device 00:04:3E:9F:A3:C0 OBDLink LX
pair 00:04:3E:9F:A3:C0
Attempting to pair with 00:04:3E:9F:A3:C0
[CHG] Device 00:04:3E:9F:A3:C0 Class: 0x020300
[CHG] Device 00:04:3E:9F:A3:C0 Icon: network-wireless
[CHG] Device 00:04:3E:9F:A3:C0 Connected: yes
Request confirmation
[agent] Confirm passkey 559460 (yes/no): yes
[CHG] Device 00:04:3E:9F:A3:C0 UUIDs:
	00001101-0000-1000-8000-00805f9b34fb
[CHG] Device 00:04:3E:9F:A3:C0 Paired: yes
Pairing successful
[CHG] Device 00:04:3E:9F:A3:C0 Trusted: yes
Changing 00:04:3E:9F:A3:C0 trust succeeded
quit

Setting up an rfcomm device

sudo rfcomm bind rfcomm0 00:04:3E:9F:A3:C0
ls -l /dev/rfcomm0
crw-rw---- 1 root dialout 216, 0 Jun 21 21:41 /dev/rfcomm0

Testing

minicom -D /dev/rfcomm0 115200

Testing with a python script

python3 source/java/can4eve/scripts/obdtest.py 
>K
>LM327 v1.3a
>KE0
OK

>
ELM327 v1.3a

>
OK

>
ISO 15765-4 (CAN 11/500)

>
OK

>
OK

>
OK

>

Forwarding the OBDII Adapter via TCP/IP

python source/java/can4eve/scripts/tcp_serial_redirect.py --debug -P 7000 /dev/rfcomm0 115200
--- TCP/IP to Serial redirect on /dev/rfcomm0  115200,8,N,1 ---
--- type Ctrl-C / BREAK to quit
Waiting for connection on 7000...

At this point your OBDLink LX is available via LAN - you can simply do a telnet host 7000 to the server where you ran the commands. The can4eve software can now use the bluetooth device as if it was a Wifi/LAN device