[Android Q&A, Help & Troubleshooting] yodamiit:
And then:

$ su

su

# sdptool add --channel 16 SP

sdptool add --channel 16 SP

Serial Port service registered

# sdptool browse local

sdptool browse local

Browsing FF:FF:FF:00:00:00 ...

Service Name: Headset Audio Gateway

Service RecHandle: 0x10000

Service Class ID List:

"Headset Audio Gateway" (0x1112)

"Generic Audio" (0x1203)

Protocol Descriptor List:

"L2CAP" (0x0100)

"RFCOMM" (0x0003)

Channel: 12

Profile Descriptor List:

"Headset" (0x1108)

Version: 0x0102

Service Name: Hands-Free Audio Gateway

Service RecHandle: 0x10001

Service Class ID List:

"Handsfree Audio Gateway" (0x111f)

"Generic Audio" (0x1203)

Protocol Descriptor List:

"L2CAP" (0x0100)

"RFCOMM" (0x0003)

Channel: 13

Profile Descriptor List:

"Handsfree" (0x111e)

Version: 0x0105

Service Name: Audio Source

Service RecHandle: 0x10002

Service Class ID List:

"Audio Source" (0x110a)

Protocol Descriptor List:

"L2CAP" (0x0100)

PSM: 25

"AVDTP" (0x0019)

uint16: 0x102

Profile Descriptor List:

"Advanced Audio" (0x110d)

Version: 0x0102

Service Name: AVRCP TG

Service RecHandle: 0x10003

Service Class ID List:

"AV Remote Target" (0x110c)

Protocol Descriptor List:

"L2CAP" (0x0100)

PSM: 23

"AVCTP" (0x0017)

uint16: 0x103

Profile Descriptor List:

"AV Remote" (0x110e)

Version: 0x0100

Service Name: Voice Gateway

Service RecHandle: 0x10004

Service Class ID List:

"Headset Audio Gateway" (0x1112)

"Generic Audio" (0x1203)

Protocol Descriptor List:

"L2CAP" (0x0100)

"RFCOMM" (0x0003)

Channel: 11

Profile Descriptor List:

"Headset" (0x1108)

Version: 0x0100

Service Name: OBEX Object Push

Service RecHandle: 0x10005

Service Class ID List:

"OBEX Object Push" (0x1105)

Protocol Descriptor List:

"L2CAP" (0x0100)

"RFCOMM" (0x0003)

Channel: 12

"OBEX" (0x0008)

Profile Descriptor List:

"OBEX Object Push" (0x1105)

Version: 0x0100

Service Name: OBEX Phonebook Access Server

Service RecHandle: 0x10006

Service Class ID List:

"Phonebook Access - PSE" (0x112f)

Protocol Descriptor List:

"L2CAP" (0x0100)

"RFCOMM" (0x0003)

Channel: 19

"OBEX" (0x0008)

Profile Descriptor List:

"Phonebook Access" (0x1130)

Version: 0x0100

Service Name: Network service

Service Description: Network service

Service RecHandle: 0x10007

Service Class ID List:

"Network Access Point" (0x1116)

Protocol Descriptor List:

"L2CAP" (0x0100)

PSM: 15

"BNEP" (0x000f)

Version: 0x0100

SEQ16: 800 806

Language Base Attr List:

code_ISO639: 0x656e

encoding: 0x6a

base_offset: 0x100

Profile Descriptor List:

"Network Access Point" (0x1116)

Version: 0x0100

Service Name: Serial Port

Service Description: COM Port

Service Provider: BlueZ

Service RecHandle: 0x10008

Service Class ID List:

"Serial Port" (0x1101)

Protocol Descriptor List:

"L2CAP" (0x0100)

"RFCOMM" (0x0003)

Channel: 16

Language Base Attr List:

code_ISO639: 0x656e

encoding: 0x6a

base_offset: 0x100

Profile Descriptor List:

"Serial Port" (0x1101)

Version: 0x0100

We add SP profile.

We have UART at dev/ttyHS2

Then we can do this:

$ rfcomm connect 0 00:0D:18:00:00:01 16

rfcomm connect 0 00:0D:18:00:00:01 16

Can't connect RFCOMM socket: Invalid exchange

$ rfcomm connect 0 00:0D:18:00:00:01 16

rfcomm connect 0 00:0D:18:00:00:01 16

Can't open RFCOMM device: Permission denied

$ su

su

# rfcomm connect 0 00:0D:18:00:00:01 16

rfcomm connect 0 00:0D:18:00:00:01 16

Connected /dev/rfcomm0 to 00:0D:18:00:00:01 on channel 16

Press CTRL-C for hangup

Connection done!

By using microcom I can send AT commands to ELM327 adapter and can take answers. But diagnostic software can not connect to adapter.

Any help?