What is the other side of the socket in android

I am transferring a GB device to ICS and have had problems with Bluetooth.

The problem occurs when the native method, connectNative, tries to connect to the socket created to listen to the Call Audio stream.

the socket is created in the file

android_bluetooth_BluetoothSocket.cpp

using

socket(PF_BLUETOOTH, SOCK_SEQPACKET, BTPROTO_SCO)

But when the connectNative function is called, it throws an error - 93 - The protocol is not supported.

The exception reported in the framework is as follows:
Bluetooth HS/HF: BEFORE mOutgoingSco.connect()
BluetoothSocket.cpp: --> INSIDE connectNative IN android_bluetooth_BluetoothSocket.cpp
BluetoothSocket.cpp: connectNative
BluetoothSocket.cpp: --> TYPE_SCO_WBS | TYPE_SCO
BluetoothSocket.cpp: ...connect(161, SCO) = 93 (errno 93)
BluetoothSocket.cpp: --> INSIDE connectNative ABOUT TO THROW jniThrowIOException(env, errno);
Bluetooth HS/HF: BluetoothSocket could not connect
Bluetooth HS/HF: IOException - Printing StackTrace
System.err: java.io.IOException: Protocol not supported
System.err:     at android.bluetooth.BluetoothSocket.connectNative(Native Method)
System.err:     at android.bluetooth.BluetoothSocket.connect(BluetoothSocket.java:233)
System.err:     at com.android.phone.BluetoothHandsfree$ScoSocketConnectThread.run(BluetoothHandsfree.java:476)

From what part of the Android code will the socket be heard and written to?

+3
source share

All Articles