question: public boolean connect ( final String address ) { if ( mBluetoothAdapter == null || address == null ) { Log . w ( TAG , "BluetoothAdapter not initialized or unspecified address." ) ; return false ; } if ( mBluetoothDeviceAddress != null && address . equals ( mBluetoothDeviceAddress ) && mBluetoothGatt != null ) { Log . d ( TAG , "Trying to use an existing mBluetoothGatt for connection." ) ; if ( mBluetoothGatt . connect ( ) ) { return true ; } else { return false ; } } final BluetoothDevice device = mBluetoothAdapter . getRemoteDevice ( address ) ; if ( device == null ) { Log . w ( TAG , "Device not found.  Unable to connect." ) ; return false ; } mBluetoothGatt = device . connectGatt ( this , false , mGattCallback ) ; Log . d ( TAG , "Trying to create a new connection." ) ; mBluetoothDeviceAddress = address ; return true ; }
target:  Connects to the GATT server hosted on the Bluetooth LE device.