diff --git a/fmapp2/src/com/caf/fmradio/FMRadioService.java b/fmapp2/src/com/caf/fmradio/FMRadioService.java
index 879678d..b855197 100644
--- a/fmapp2/src/com/caf/fmradio/FMRadioService.java
+++ b/fmapp2/src/com/caf/fmradio/FMRadioService.java
@@ -3676,6 +3676,12 @@
           if (mCallbacks != null) {
               try {
                   mCallbacks.getStationParamCb(val, status);
+                  if (mReceiver != null && mReceiver.isCherokeeChip()) {
+                      synchronized(mEventWaitLock) {
+                          mEventReceived = true;
+                          mEventWaitLock.notify();
+                      }
+                  }
               } catch (RemoteException e) {
                   e.printStackTrace();
               }
@@ -3909,9 +3915,12 @@
       return frequencyString;
    }
    public int getRssi() {
-      if (mReceiver != null)
-          return mReceiver.getRssi();
-      else
+      if (mReceiver != null) {
+          mEventReceived = false;
+          int rssi = mReceiver.getRssi();
+          waitForFWEvent();
+          return rssi;
+      } else
           return Integer.MAX_VALUE;
    }
    public int getIoC() {
@@ -3937,9 +3946,12 @@
           mReceiver.setHiLoInj(inj);
    }
    public int getSINR() {
-      if (mReceiver != null)
-          return mReceiver.getSINR();
-      else
+      if (mReceiver != null) {
+          mEventReceived = false;
+          int sinr = mReceiver.getSINR();;
+          waitForFWEvent();
+          return sinr;
+      } else
           return Integer.MAX_VALUE;
    }
    public boolean setSinrSamplesCnt(int samplesCnt) {
diff --git a/helium/radio_helium_hal.c b/helium/radio_helium_hal.c
index b7951f3..1480b72 100644
--- a/helium/radio_helium_hal.c
+++ b/helium/radio_helium_hal.c
@@ -418,8 +418,8 @@
     }
     ALOGE("hci_cc_station_rsp: val =%x, status = %x", val, status);
 
-    hal->jni_cb->fm_get_station_param_cb(val, status);
     clear_all_bit(station_param_mask_flag);
+    hal->jni_cb->fm_get_station_param_cb(val, status);
 }
 
 static void hci_cc_dbg_param_rsp(char *ev_buff)
