Kaynağa Gözat

UFO不发送RF重连教具

chaooo 1 yıl önce
ebeveyn
işleme
49c163c7b9
2 değiştirilmiş dosya ile 5 ekleme ve 3 silme
  1. 4 2
      src/pages/games/play/index.vue
  2. 1 1
      src/utils/connection.js

+ 4 - 2
src/pages/games/play/index.vue

@@ -463,7 +463,10 @@ export default {
       wx.setKeepScreenOn({
         keepScreenOn: true,
       });
-      $this.$connection.sendAutoConnectRf(true, Math.round($this.total_time / 60));
+      let $toy_sn = ble_store.getters.getToySn().toUpperCase();
+      if(!$toy_sn.includes("UF")){
+        $this.$connection.sendAutoConnectRf(true, Math.round($this.total_time / 60));
+      }
       $this.$connection.notifyDatas($this);
       setTimeout(() => {
         // 获取LED灯状态并设置
@@ -477,7 +480,6 @@ export default {
       }, 500);
       setTimeout(() => {
         // 获取教具类型 发送陀螺仪开关指令
-        let $toy_sn = ble_store.getters.getToySn().toUpperCase();
         if ($toy_sn.includes("SW") || $toy_sn.includes("KL") || $toy_sn.includes("SC")) {
           // 设置教具为无运动状态 AA CC 03 00 00 00 34 CKS
           $this.$connection.SendMotionOrder("01");

+ 1 - 1
src/utils/connection.js

@@ -205,7 +205,7 @@ export default {
   },
 
   /**
-   * 自动发送RF重连
+   * 自动发送RF重连教具
    * @param  {Boolean} isOn    是否打开重连功能
    * @param timeOut 有效时间
    * AA CC 03 00 01 0a d0 21