title: NumberFormatException: For input string: "5,2"
body: <p>Please help me with this issue. I am adding code snippet and crash log here.</p>
  
  <p>Code:</p>
  
  <pre><code>if (rssi &lt;= -30 &amp;&amp; rssi &gt;= -90) {
      double len = ((rssi + 20) * -1) / 10.0;
      DecimalFormat decimalFormat = new DecimalFormat("#.##");
      float twoDigitsF = Float.valueOf(decimalFormat.format(len));
      return String.valueOf(twoDigitsF);
  }
  </code></pre>
  
  <p>I am getting the exception at the line</p>
  
  <pre><code>float twoDigitsF = Float.valueOf(decimalFormat.format(len));
  </code></pre>
  
  <p>Here I am attaching my logs</p>
  
  <pre><code>Fatal Exception: java.lang.NumberFormatException: For input string: "5,2"
         at java.lang.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1306)
         at java.lang.Float.valueOf(Float.java:424)
         at com.app.package.utils.Util.getRange(Util.java:26)
         at com.app.package.DriverActivity.scanDone(SampleActivity.java:982)
         at com.app.package.DriverActivity.access$1300(SampleActivity.java:126)
         at com.app.package.DriverActivity$11.onScanned(SampleActivity.java:913)
         at com.appchannel.bluetooth.BHelper$1.run(BHelper.java:67)
         at android.os.Handler.handleCallback(Handler.java:751)
         at android.os.Handler.dispatchMessage(Handler.java:95)
         at android.os.Looper.loop(Looper.java:154)
         at android.app.ActivityThread.main(ActivityThread.java:6317)
         at java.lang.reflect.Method.invoke(Method.java)
         at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:872)
         at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:762)
  </code></pre>
  
  <p><strong>I got this log from Crashlytics. I am not able to reproduce this issue on my device.</strong> </p>