title: Reading RSSI value of connected Bluetooth Low Energy device in Android Studio
body: <p>I am working on a BLE project in Android Studio and would like to read the RSSI value of a device which I have already connected to. So far I was able to discover new devices via LE Scan and get their RSSI from there. However, once I connect to a device I can no longer run a scan and get the RSSI.</p>
  
  <p>This is the code for discovering new devices before connecting to one of them. Not sure how relevant it is to my question though:</p>
  
  <pre><code>private BluetoothAdapter.LeScanCallback mLeScanCallback =
          new BluetoothAdapter.LeScanCallback() {
  
      @Override
      public void onLeScan(final BluetoothDevice device,final int rssi, byte[] scanRecord) {
          runOnUiThread(new Runnable() {
              @Override
              public void run() {
                  mLeDeviceListAdapter.addDevice(device, rssi);
                  //mLeDeviceListAdapter.notifyDataSetChanged();
                  try {
                      mLeDeviceListAdapter.notifyDataSetChanged();
                  } catch (Exception e) {
                      e.printStackTrace();
                  }
              }
          });
      }
  };
  </code></pre>
  
  <p>Thanks in advance</p>