title: speech to text in hindi for android
body: <p>I'm using following code and send locale for hindi but still speech to text gives result in English.</p>
  
  <p>I want that result must be in hindi </p>
  
  <pre><code> /**
       * Showing google speech input dialog
       */
      private void promptSpeechInput() {
          Locale locale;
          if (android.os.Build.VERSION.SDK_INT &gt;= android.os.Build.VERSION_CODES.LOLLIPOP) {
              locale = (Locale.forLanguageTag("hin"));
          } else {
              locale = (new Locale("hin"));
          }
          Intent intent = new Intent(RecognizerIntent.ACTION_RECOGNIZE_SPEECH);
          intent.putExtra(RecognizerIntent.EXTRA_LANGUAGE_MODEL,
                  RecognizerIntent.LANGUAGE_MODEL_FREE_FORM);
          intent.putExtra(RecognizerIntent.EXTRA_LANGUAGE, locale);
          intent.putExtra(RecognizerIntent.EXTRA_PROMPT,
                  getString(R.string.speech_not_supported));
          try {
              startActivityForResult(intent, REQ_CODE_SPEECH_INPUT);
          } catch (ActivityNotFoundException a) {
              Toast.makeText(getApplicationContext(),
                      getString(R.string.otp_send_dynamic_msg),
                      Toast.LENGTH_SHORT).show();
          }
      }
  </code></pre>