title: Android BluetoothDevice connectGatt not working on HTC M8 with Android 6.0
body: <p>I have a BLE app that has hundreds of happy users on a variety of devices. Most of my testing has been done on Nexus devices, but a user reported an issue with HTC M8 so I just bought one. Sure enough, for some reason <code>connectGatt</code> isn't working. It doesn't throw any exceptions and the BluetoothGatt object it returns isn't null. But <code>onConnectionStateChange</code> in the BluetoothGattCallback I pass in is never called.</p>
  
  <p>I found a few reports that some phones needed connectGatt to be called on the UI thread, so I tried that but nothing changed.</p>
  
  <p>Here's the log I get:</p>
  
  <pre><code>D/BluetoothGatt: connect() - device: CE:FA:92:61:A3:4F, auto: false
  D/BluetoothGatt: registerApp()
  D/BluetoothGatt: registerApp() - UUID=f7a1a0e9-0d45-4b71-9457-9adf6ccb4bf8
  D/BluetoothGatt: onClientRegistered() - status=0 clientIf=5
  </code></pre>
  
  <p>Then silence...</p>
  
  <p>Any ideas? Thanks!</p>