(global["webpackJsonp"] = global["webpackJsonp"] || []).push([["BLEPages/child/L01A"],{

/***/ 280:
/*!*********************************************************************************************!*\
  !*** E:/qiaocongli/小程序/品传/成人版小程序/adultDeviceApp/main.js?{"page":"BLEPages%2Fchild%2FL01A"} ***!
  \*********************************************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(wx, createPage) {

var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 4);
__webpack_require__(/*! uni-pages */ 26);
var _vue = _interopRequireDefault(__webpack_require__(/*! vue */ 25));
var _L01A = _interopRequireDefault(__webpack_require__(/*! ./BLEPages/child/L01A.vue */ 281));
// @ts-ignore
wx.__webpack_require_UNI_MP_PLUGIN__ = __webpack_require__;
createPage(_L01A.default);
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/wx.js */ 1)["default"], __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */ 2)["createPage"]))

/***/ }),

/***/ 281:
/*!**************************************************************************!*\
  !*** E:/qiaocongli/小程序/品传/成人版小程序/adultDeviceApp/BLEPages/child/L01A.vue ***!
  \**************************************************************************/
/*! no static exports found */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./L01A.vue?vue&type=template&id=03f0358f&scoped=true& */ 282);
/* harmony import */ var _L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./L01A.vue?vue&type=script&lang=js& */ 284);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/* harmony import */ var _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/runtime/componentNormalizer.js */ 31);

var renderjs




/* normalize component */

var component = Object(_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__["default"])(
  _L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"],
  _L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__["render"],
  _L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"],
  false,
  null,
  "03f0358f",
  null,
  false,
  _L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__["components"],
  renderjs
)

component.options.__file = "BLEPages/child/L01A.vue"
/* harmony default export */ __webpack_exports__["default"] = (component.exports);

/***/ }),

/***/ 282:
/*!*********************************************************************************************************************!*\
  !*** E:/qiaocongli/小程序/品传/成人版小程序/adultDeviceApp/BLEPages/child/L01A.vue?vue&type=template&id=03f0358f&scoped=true& ***!
  \*********************************************************************************************************************/
/*! exports provided: render, staticRenderFns, recyclableRender, components */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_17_0_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--17-0!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/template.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-uni-app-loader/page-meta.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./L01A.vue?vue&type=template&id=03f0358f&scoped=true& */ 283);
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "render", function() { return _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_17_0_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__["render"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_17_0_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_17_0_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__["recyclableRender"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "components", function() { return _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_17_0_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_template_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_uni_app_loader_page_meta_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_template_id_03f0358f_scoped_true___WEBPACK_IMPORTED_MODULE_0__["components"]; });



/***/ }),

/***/ 283:
/*!*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--17-0!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/template.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-uni-app-loader/page-meta.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!E:/qiaocongli/小程序/品传/成人版小程序/adultDeviceApp/BLEPages/child/L01A.vue?vue&type=template&id=03f0358f&scoped=true& ***!
  \*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
/*! exports provided: render, staticRenderFns, recyclableRender, components */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "render", function() { return render; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return staticRenderFns; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
var components
var render = function () {
  var _vm = this
  var _h = _vm.$createElement
  var _c = _vm._self._c || _h
}
var recyclableRender = false
var staticRenderFns = []
render._withStripped = true



/***/ }),

/***/ 284:
/*!***************************************************************************************************!*\
  !*** E:/qiaocongli/小程序/品传/成人版小程序/adultDeviceApp/BLEPages/child/L01A.vue?vue&type=script&lang=js& ***!
  \***************************************************************************************************/
/*! no static exports found */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!./node_modules/babel-loader/lib!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--13-1!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./L01A.vue?vue&type=script&lang=js& */ 285);
/* harmony import */ var _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
 /* harmony default export */ __webpack_exports__["default"] = (_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_vue_loader_lib_index_js_vue_loader_options_D_HBuilderX_3_6_4_20220922_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_style_js_L01A_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default.a); 

/***/ }),

/***/ 285:
/*!**********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** ./node_modules/babel-loader/lib!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--13-1!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib??vue-loader-options!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!E:/qiaocongli/小程序/品传/成人版小程序/adultDeviceApp/BLEPages/child/L01A.vue?vue&type=script&lang=js& ***!
  \**********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(uni) {

var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 4);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 11));
var _vuex = __webpack_require__(/*! vuex */ 30);
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
var myTime;
var _default = {
  data: function data() {
    return {
      text: "",
      height: "",
      weight: "",
      imp: 0,
      type: 1,
      uuid1: "",
      uuid2: "",
      uuid3: "",
      macAddr: "",
      deviceId: "",
      serviceId: "",
      Unload: false,
      pageNav: false,
      stopblue: true,
      isConnection: 0 //是否连接成功
    };
  },

  computed: _objectSpread(_objectSpread({}, (0, _vuex.mapState)(["user", "isConnected", "isBluetoothTyle", "appTheme"])), {}, {
    info: function info() {
      return this.user;
    }
  }),
  onUnload: function onUnload() {
    var that = this;
    if (!that.Unload) {
      that.stopBluetoothDevicesDiscovery(); //取消蓝牙搜索
      clearTimeout(myTime);
      that.closeBLEConnection();
      that.closeBluetoothAdapter();
      uni.switchTab({
        url: "/pages/index/index"
      });
      console.log("测量页返回1");
    }
  },
  onLoad: function onLoad(options) {
    var that = this;
    // 导航栏颜色
    uni.setNavigationBarColor({
      frontColor: '#ffffff',
      backgroundColor: this.appTheme
    });
    // 
    that.text = "";
    if (options && options.deviceId) {
      that.deviceId = options.deviceId;
      that.closeBLEConnection();
      that.closeBluetoothAdapter();
      that.openBluetoothAdapter();
    }
    that.onBLEConnectionStateChange();
    uni.onBluetoothAdapterStateChange(function (res) {
      that.$store.commit("changeBluetooth", res.available);
    });
  },
  watch: {
    isConnected: function isConnected() {
      var that = this;
      if (!that.isConnected) {
        that.handleBack();
        that.isConnection = 2;
      }
    },
    isBluetoothTyle: function isBluetoothTyle() {
      var that = this;
      if (!that.isBluetoothTyle) {
        that.handleBack();
        that.isConnection = 2;
      }
    },
    stopblue: function stopblue() {
      var that = this;
      if (!that.stopblue) {
        console.log("停止成功", that.weight, that.imp);
        if (that.imp == 0) {
          uni.showModal({
            title: '提示',
            content: "体脂测量失败，是否保存本次测量结果？",
            cancelText: "放弃",
            confirmText: "保存",
            success: function success(res) {
              if (res.confirm) {
                that.imp = 0;
                that.handleGetMeasure();
              } else {
                that.Unload = true;
                that.startBluetoothDeviceDiscovery();
                that.closeBLEConnection();
                that.closeBluetoothAdapter();
                uni.switchTab({
                  url: "/pages/index/index"
                });
              }
            }
          });
        } else {
          that.handleGetMeasure();
        }
      }
    }
  },
  methods: {
    // 初始化蓝牙
    openBluetoothAdapter: function openBluetoothAdapter() {
      var that = this;
      that.text = "";
      that.stopblue = true;
      uni.openBluetoothAdapter({
        success: function success(e) {
          that.isConnection = 0;
          that.startBluetoothDeviceDiscovery();
        },
        fail: function fail(e) {
          that.isConnection = 2;
          that.$tools.msg("请确定设备是开机状态、手机蓝牙权限已打开！");
        }
      });
    },
    // 开始搜寻附近的蓝牙外围设备
    startBluetoothDeviceDiscovery: function startBluetoothDeviceDiscovery() {
      var that = this;
      uni.startBluetoothDevicesDiscovery({
        allowDuplicatesKey: false,
        interval: 100,
        //上报设备的间隔
        services: [],
        success: function success(res) {
          that.isConnection = 0;
          that.onBluetoothDeviceFound();
        },
        fail: function fail(res) {
          that.isConnection = 2;
          that.$tools.msg("请确定设备是开机状态、手机蓝牙权限已打开！");
        }
      });
    },
    /**
     * 发现外围设备
     */
    onBluetoothDeviceFound: function onBluetoothDeviceFound() {
      var that = this;
      that.isConnection = 0;
      uni.onBluetoothDeviceFound(function (res) {
        res.devices.forEach(function (device) {
          if (!device.name && !device.localName) {
            return;
          }
          if (device.name.indexOf("FitTrack") !== -1 || device.name.indexOf("SWAN") !== -1) {
            clearTimeout(myTime);
            var buff = device.advertisData.slice(2, 8);
            device.mac = new Uint8Array(buff); // 保存广播数据中的mac地址，这是由于iOS不直接返回mac地址
            var tempMac = Array.from(device.mac);
            tempMac.reverse();
            device.macAddr = that.$tools.ab2hex(tempMac, ':').toUpperCase();
            if (device.deviceId.indexOf(that.deviceId) != -1 || device.macAddr.indexOf(that.deviceId) != -1) {
              that.stopBluetoothDevicesDiscovery();
              that.macAddr = device.macAddr;
              that.deviceId = device.deviceId;
              that.createBLEConnection();
              return;
            }
          }
        });
      });
      that.handleMyTime();
    },
    handleMyTime: function handleMyTime() {
      var that = this;
      myTime = setTimeout(function () {
        if (!that.macAddr) {
          clearTimeout(myTime);
          that.Unload = true;
          that.isConnection = 2;
          that.closeBLEConnection();
          that.closeBluetoothAdapter();
        }
      }, 20000);
    },
    /**
     * 停止搜索蓝牙设备
     */
    stopBluetoothDevicesDiscovery: function stopBluetoothDevicesDiscovery() {
      uni.stopBluetoothDevicesDiscovery({
        success: function success(e) {
          console.log("停止搜索蓝牙设备", e);
        }
      });
    },
    // 监听蓝牙连接状态
    onBLEConnectionStateChange: function onBLEConnectionStateChange() {
      var that = this;
      uni.onBLEConnectionStateChange(function (res) {
        console.log("监听蓝牙连接状态", res.connected);
        if (!res.connected) {
          that.Unload = true;
          that.isConnection = 2;
          clearTimeout(myTime);
          that.closeBLEConnection();
          that.closeBluetoothAdapter();
        }
        that.$store.commit("changeConnected", res.connected);
      });
    },
    // 连接蓝牙
    createBLEConnection: function createBLEConnection() {
      var that = this;
      uni.createBLEConnection({
        deviceId: that.deviceId,
        success: function success(res) {
          that.isConnection = 0;
          that.getBLEDeviceServices();
        },
        fail: function fail(res) {
          that.isConnection = 2;
          console.log("设备连接失败，请重新连接", res);
        }
      });
    },
    /**
     * 获取设备的UUID
     */
    getBLEDeviceServices: function getBLEDeviceServices() {
      var serviceList = [];
      var that = this;
      uni.getBLEDeviceServices({
        deviceId: that.deviceId,
        success: function success(res) {
          console.log("获取设备的UUID成功", res);
          serviceList = res.services;
          for (var i = 0; i < serviceList.length; i++) {
            var service = serviceList[i];
            if (service.uuid.indexOf("FFB0") != -1) {
              that.isConnection = 1;
              that.serviceId = service.uuid;
              that.getBLEDeviceCharacteristics();
              console.log("设备的FFB0的serviceId： " + that.serviceId);
              break;
            }
          }
        },
        fail: function fail(res) {
          console.log('获取设备的UUID失败:', res);
        }
      });
    },
    /**
     * 获取指定服务的特征值
     */
    getBLEDeviceCharacteristics: function getBLEDeviceCharacteristics() {
      var characteristicsList = [];
      var that = this;
      uni.getBLEDeviceCharacteristics({
        deviceId: that.deviceId,
        serviceId: that.serviceId,
        success: function success(res) {
          console.log("服务的特征值成功", res);
          for (var i = 0; i < res.characteristics.length; i++) {
            var item = res.characteristics[i];
            if (item.uuid.indexOf('FFB1') != -1) {
              that.uuid1 = item.uuid; //下发数据
            } else if (item.uuid.indexOf('FFB2') != -1) {
              that.uuid2 = item.uuid; //监听数据
              that.notifyBLECharacteristicValue();
            } else if (item.uuid.indexOf('FFB3') != -1) {
              that.uuid3 = item.uuid; //写入设置
            }
          }
        },

        fail: function fail(res) {
          console.log('获取特征值失败:', JSON.stringify(res));
        }
      });
    },
    /**
     * 开启订阅特征值
     * read: true, //读,write: true, //写,notify: true, //广播
     */
    notifyBLECharacteristicValue: function notifyBLECharacteristicValue() {
      var that = this;
      uni.notifyBLECharacteristicValueChange({
        state: true,
        // 启用 notify 功能
        deviceId: that.deviceId,
        serviceId: that.serviceId,
        characteristicId: that.uuid2,
        success: function success(res) {
          uni.onBLECharacteristicValueChange(function (res) {
            var value = that.$tools.ab2hex(res.value, "");
            var type = value.substring(4, 6);
            console.log("数据", value);
            if (value.substring(12, 14) == "ce") {
              that.text = "您的实时体重是：" + parseInt(value.substring(4, 8), 16) / 10 + 'kg';
            }
            if (value.substring(12, 14) == "ca") {
              that.weight = parseInt(value.substring(4, 8), 16) / 10 + 'kg';
              that.text = "您的稳定体重是：" + parseInt(value.substring(4, 8), 16) / 10 + 'kg';
            }
            if (type == 'fd') {
              //阻抗
              if (value.substring(6, 8) == "01") {
                that.imp = parseInt(value.substring(8, 12), 16);
                that.handleGetMeasure();
              }
              if (value.substring(6, 8) == "ff") {
                that.imp = 0;
              }
            }
            if (type == "fe") {
              if (value.substring(6, 8) == "10") {
                console.log("测量完成", that.weight, that.imp);
                that.stopblue = false;
              }
            }
          });
        },
        fail: function fail(res) {
          console.log("测量失败", res.value);
        }
      });
    },
    // 保存测量结果 
    handleGetMeasure: function handleGetMeasure() {
      var that = this;
      that.$model.getmeasure({
        weight: that.weight,
        imp: that.imp,
        ecode: that.macAddr,
        height: that.info.height,
        familyid: that.info.familyid
      }).then(function (res) {
        if (res.code == 0) {
          that.$tools.msg("测量成功");
          that.$store.dispatch("getUserInfo", {
            familyid: that.info.familyid
          });
          that.$store.dispatch("getResult", {
            birthday: that.info.birthday,
            familyid: that.info.familyid,
            height: that.info.height,
            sex: that.info.sex
          });
        } else {
          console.log("测量失败", res.message);
          that.$tools.msg(res.message);
        }
        that.Unload = true;
        setTimeout(function () {
          that.closeBLEConnection();
          that.closeBluetoothAdapter();
          uni.switchTab({
            url: "/pages/index/index"
          });
        }, 200);
      });
    },
    handleBack: function handleBack() {
      var that = this;
      that.Unload = true;
      clearTimeout(myTime);
      that.stopBluetoothDevicesDiscovery(); //取消蓝牙搜索
      that.closeBLEConnection();
      that.closeBluetoothAdapter();
    },
    /**
     * 断开蓝牙模块
     */
    closeBluetoothAdapter: function closeBluetoothAdapter() {
      var that = this;
      uni.closeBluetoothAdapter({
        success: function success(res) {
          console.log('蓝牙模块关闭成功');
        }
      });
    },
    /**
     * 断开蓝牙连接
     */
    closeBLEConnection: function closeBLEConnection() {
      var that = this;
      uni.closeBLEConnection({
        deviceId: that.deviceId,
        success: function success(res) {
          console.log('断开蓝牙连接成功');
        }
      });
    }
  }
};
exports.default = _default;
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */ 2)["default"]))

/***/ })

},[[280,"common/runtime","common/vendor"]]]);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/BLEPages/child/L01A.js.map