List of usage examples for android.bluetooth BluetoothSocket requestMaximumTxDataLength
public void requestMaximumTxDataLength() throws IOException
From source file:com.googlecode.android_scripting.facade.bluetooth.BluetoothSocketConnFacade.java
/** * Set the current BluetoothSocket LE Data Length value to the maximum supported by this BT * controller. This command suggests to the BT controller to set its maximum transmission packet * size./*from w w w . j av a 2s . c om*/ * @throws Exception */ @Rpc(description = "Request Maximum Tx Data Length") public void bluetoothSocketRequestMaximumTxDataLength() throws IOException { Log.d("bluetoothSocketRequestMaximumTxDataLength"); if (mConnectThread == null) { String connUuid = mConnectThread.getConnUuid(); throw new IOException("bluetoothSocketRequestMaximumTxDataLength: no active connect" + " thread"); } BluetoothSocket socket = mConnectThread.getSocket(); if (socket == null) { throw new IOException("bluetoothSocketRequestMaximumTxDataLength: no active connect" + " socket"); } socket.requestMaximumTxDataLength(); }