diff --git a/FMRecord/src/com/codeaurora/fmrecording/FMRecordingService.java b/FMRecord/src/com/codeaurora/fmrecording/FMRecordingService.java
index a5e899c..62f4a94 100644
--- a/FMRecord/src/com/codeaurora/fmrecording/FMRecordingService.java
+++ b/FMRecord/src/com/codeaurora/fmrecording/FMRecordingService.java
@@ -259,7 +259,10 @@
 
         }
         mSampleFile = null;
-        File sampleDir = Environment.getExternalStorageDirectory();
+        File sampleDir = new File(Environment.getExternalStorageDirectory().getAbsolutePath() +"/FMRecording");
+
+        if(!(sampleDir.mkdirs() || sampleDir.isDirectory()))
+            return false;
 
         try {
              mSampleFile = File.createTempFile("FMRecording", ".3gpp", sampleDir);
@@ -309,9 +312,12 @@
                          Log.d(TAG, "Maximum file size/duration reached, stopping the recording");
                          stopRecord();
                      }
-                     // Show the toast.
-                     Toast.makeText(FMRecordingService.this, R.string.FMRecording_reach_size_limit,
-                               Toast.LENGTH_LONG).show();
+                     if (what == MediaRecorder.MEDIA_RECORDER_INFO_MAX_FILESIZE_REACHED) {
+                         // Show the toast.
+                         Toast.makeText(FMRecordingService.this,
+                                        R.string.FMRecording_reach_size_limit,
+                                        Toast.LENGTH_LONG).show();
+                     }
                  }
              }
              // from MediaRecorder.OnErrorListener
diff --git a/fmapp2/res/values-zh-rCN/strings.xml b/fmapp2/res/values-zh-rCN/strings.xml
index 76936b7..d32c0cd 100644
--- a/fmapp2/res/values-zh-rCN/strings.xml
+++ b/fmapp2/res/values-zh-rCN/strings.xml
@@ -115,5 +115,6 @@
     <string name="chanl_spacing">信道间隔</string>
     <string name="set">设置</string>
     <string name="cancel">取消</string>
-	<string name="rt_plus_tags">标签</string>
+    <string name="rt_plus_tags">标签</string>
+    <string name="user_defind_band_msg">请输入有效的频段范围 76.0 - 108.0</string>
 </resources>
diff --git a/fmapp2/res/values/strings.xml b/fmapp2/res/values/strings.xml
index 146866a..a2bf1d4 100644
--- a/fmapp2/res/values/strings.xml
+++ b/fmapp2/res/values/strings.xml
@@ -263,5 +263,6 @@
     <string name="band_sweep_choose">Choose Band Sweep Method</string>
     <string name="set">Set</string>
     <string name="cancel">Cancel</string>
+    <string name="user_defind_band_msg">Enter Freq from range 76.0 - 108.0</string>
 
 </resources>
diff --git a/fmapp2/src/com/caf/fmradio/FMRadioService.java b/fmapp2/src/com/caf/fmradio/FMRadioService.java
index a218893..565537f 100644
--- a/fmapp2/src/com/caf/fmradio/FMRadioService.java
+++ b/fmapp2/src/com/caf/fmradio/FMRadioService.java
@@ -1735,6 +1735,12 @@
       if (isFmRecordingOn())
       {
           stopRecording();
+          try {
+               Thread.sleep(300);
+          } catch (Exception ex) {
+               Log.d( LOGTAG, "RunningThread InterruptedException");
+               return;
+          }
       }
       AudioManager audioManager = (AudioManager) getSystemService(Context.AUDIO_SERVICE);
       if(audioManager != null)
diff --git a/fmapp2/src/com/caf/fmradio/HorizontalNumberPicker.java b/fmapp2/src/com/caf/fmradio/HorizontalNumberPicker.java
index ac886bb..505097f 100644
--- a/fmapp2/src/com/caf/fmradio/HorizontalNumberPicker.java
+++ b/fmapp2/src/com/caf/fmradio/HorizontalNumberPicker.java
@@ -1600,7 +1600,11 @@
         for (int i = 0; i < mSelectorIndices.length; i++) {
             int selectorIndex = current + (i - mSelectorMiddleItemIndex);
             if (mWrapSelectorWheel) {
-                selectorIndex = getWrappedSelectorIndex(selectorIndex);
+                try {
+                    selectorIndex = getWrappedSelectorIndex(selectorIndex);
+                } catch(RuntimeException e) {
+                    e.printStackTrace();
+                }
             }
             mSelectorIndices[i] = selectorIndex;
             ensureCachedScrollSelectorValue(mSelectorIndices[i]);
@@ -1622,7 +1626,11 @@
         }
         // Wrap around the values if we go past the start or end
         if (mWrapSelectorWheel) {
-            current = getWrappedSelectorIndex(current);
+            try {
+                current = getWrappedSelectorIndex(current);
+            } catch(RuntimeException e) {
+                e.printStackTrace();
+            }
         }
         int previous = mValue;
         setValue(current);
diff --git a/fmapp2/src/com/caf/fmradio/Settings.java b/fmapp2/src/com/caf/fmradio/Settings.java
index d64621b..03f88c1 100644
--- a/fmapp2/src/com/caf/fmradio/Settings.java
+++ b/fmapp2/src/com/caf/fmradio/Settings.java
@@ -317,7 +317,8 @@
                   setBandSummary(summaryBandItems.length - 1);
                   clearStationList();
                }else {
-                  displayToast(USR_BAND_MSG);
+                  Toast.makeText(this, getString(R.string.user_defind_band_msg),
+                                                            Toast.LENGTH_SHORT).show();
                }
            }else if(key.equals(USER_DEFINED_BAND_MAX_KEY)) {
                String valStr = mUserBandMaxPref.getText();
@@ -336,7 +337,8 @@
                   setBandSummary(summaryBandItems.length - 1);
                   clearStationList();
                }else {
-                  displayToast(USR_BAND_MSG);
+                  Toast.makeText(this, getString(R.string.user_defind_band_msg),
+                                                            Toast.LENGTH_SHORT).show();
                }
           }else {
               if(mRxMode) {
