You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467
  1. const _0x92e0 = ['错误码:', 'FEE7', 'concat', 'sendDataToDevice->', 'data', '发送数据异常', 'code', 'toString', '发送蓝牙指令返回数据异常',
  2. 'slice', '发送esam指令成功', 'connectTimeout', 'errorMessage', 'length', 'exports', 'resolveTLV', 'makeTLV',
  3. 'offBLECharacteristicValueChange', '蓝牙数据发送:', 'Services->', 'log', 'deviceId', 'function',
  4. 'getBLEDeviceServices', 'makeA8SendData', 'stringify', 'value', 'success', 'fail', 'push', '发送蓝牙指令超时', 'then',
  5. 'bufferArrayToHexString', 'makeA5SendData', 'notifyBLECharacteristicValueChange', '监听数据失败', '读取不到Services',
  6. 'services', '连接超时'
  7. ];
  8. const _0xf5c9 = function(_0x92e01f, _0xf5c941) {
  9. _0x92e01f = _0x92e01f - 0x0;
  10. let _0x50d73c = _0x92e0[_0x92e01f];
  11. return _0x50d73c;
  12. };
  13. const dataUtil = require('./DataUtil.js');
  14. module[_0xf5c9('0xe')] = {
  15. 'connectAndInit': connectDevice,
  16. 'disConnect': disconnectDevice,
  17. 'sendAndReceive': sendAndReceive,
  18. 'sendA5Command': sendA5Command
  19. };
  20. const FUNCTION = _0xf5c9('0x16');
  21. var tagServiceUUID = '';
  22. var tagWriteUUID = '';
  23. var tagReadUUID = '';
  24. const androidServiceUUID = '0000fee7-0000-1000-8000-00805f9b34fb';
  25. const androidWriteUUID = '0000fec7-0000-1000-8000-00805f9b34fb';
  26. const androidReadUUID = '0000fec8-0000-1000-8000-00805f9b34fb';
  27. const iosServiceUUID = _0xf5c9('0x1');
  28. const iosWriteUUID = 'FEC7';
  29. const iosReadUUID = 'FEC8';
  30. var connectDeviceId;
  31. var connectCallback;
  32. var connectTimer;
  33. var reconnectTimer;
  34. var transTimer;
  35. var read = ![];
  36. var frame = '';
  37. var frameLen = 0x0;
  38. var frames = new Array();
  39. var framesLen = 0x0;
  40. var dataHandlerCallback;
  41. var sendBufferArray = new Array();
  42. var cmds = new Array();
  43. var sendIndex;
  44. var resendCount = 0x3;
  45. var reconnectCount = 0x0;
  46. function toObject(_0x163b31, _0x2cb0af, _0x2f910b) {
  47. return {
  48. 'code': _0x163b31,
  49. 'data': _0x2cb0af,
  50. 'msg': _0x2f910b
  51. };
  52. }
  53. const codeEnum = {
  54. 'success': 0x3e8,
  55. 'fail': 0xfa0,
  56. 'timeout': 0x7d0,
  57. 'connectTimeout': 0x7d2
  58. };
  59. function connectDevice(_0x51d9b3, _0x15c0b5, _0x297201) {
  60. my[_0xf5c9('0x11')]();
  61. setTimeout(() => {
  62. connectDeviceId = _0x51d9b3[_0xf5c9('0x15')];
  63. connectCallback = _0x15c0b5;
  64. if (typeof connectTimer != undefined) {
  65. clearTimeout(connectTimer);
  66. }
  67. connectTimer = setTimeout(() => {
  68. typeof connectCallback['fail'] == FUNCTION && connectCallback['fail'](toObject(codeEnum[
  69. _0xf5c9('0xb')], undefined, _0xf5c9('0x26')));
  70. }, _0x297201);
  71. my['connectBLEDevice']({
  72. 'deviceId': connectDeviceId,
  73. 'success': _0x1e99d7 => {
  74. getBLEDeviceServices();
  75. },
  76. 'fail': _0x3ba55a => {
  77. if (typeof connectTimer != undefined) {
  78. clearTimeout(connectTimer);
  79. }
  80. typeof connectCallback[_0xf5c9('0x1c')] == FUNCTION && connectCallback[_0xf5c9(
  81. '0x1c')](toObject(codeEnum[_0xf5c9('0x1c')], undefined, '连接失败:' + JSON[
  82. _0xf5c9('0x19')](_0x3ba55a)));
  83. }
  84. });
  85. }, 0x96);
  86. }
  87. function disconnectDevice(_0x129f55) {
  88. my['disconnectBLEDevice']({
  89. 'deviceId': connectDeviceId,
  90. 'success'(_0x4e659d) {
  91. typeof _0x129f55[_0xf5c9('0x1b')] == FUNCTION && _0x129f55['success'](toObject(codeEnum[_0xf5c9(
  92. '0x1b')], _0x4e659d, '断开连接成功'));
  93. },
  94. 'fail'(_0x22025a) {
  95. typeof _0x129f55[_0xf5c9('0x1c')] == FUNCTION && _0x129f55['fail'](toObject(codeEnum['fail'],
  96. _0x22025a, '断开连接失败'));
  97. }
  98. });
  99. }
  100. function getBLEDeviceServices() {
  101. my[_0xf5c9('0x17')]({
  102. 'deviceId': connectDeviceId,
  103. 'success': _0x4c2800 => {
  104. console[_0xf5c9('0x14')](_0xf5c9('0x13'), _0x4c2800);
  105. let _0x5ab723 = ![];
  106. tagServiceUUID = '';
  107. for (let _0x2af1b7 = 0x0; _0x2af1b7 < _0x4c2800[_0xf5c9('0x25')]['length']; _0x2af1b7++) {
  108. let _0x3a301e = _0x4c2800['services'][_0x2af1b7]['serviceId'];
  109. if (_0x3a301e == androidServiceUUID) {
  110. _0x5ab723 = !![];
  111. tagServiceUUID = androidServiceUUID;
  112. break;
  113. }
  114. if (_0x3a301e == iosServiceUUID) {
  115. _0x5ab723 = !![];
  116. tagServiceUUID = iosServiceUUID;
  117. break;
  118. }
  119. }
  120. if (_0x5ab723 == !![]) {
  121. getBLEDeviceCharacteristics();
  122. } else {
  123. if (typeof connectTimer != undefined) {
  124. clearTimeout(connectTimer);
  125. }
  126. typeof connectCallback[_0xf5c9('0x1c')] == FUNCTION && connectCallback[_0xf5c9('0x1c')](
  127. toObject(codeEnum['fail'], undefined, _0xf5c9('0x24')));
  128. }
  129. },
  130. 'fail': _0x40d4c9 => {
  131. if (typeof connectTimer != undefined) {
  132. clearTimeout(connectTimer);
  133. }
  134. typeof connectCallback['fail'] == FUNCTION && connectCallback[_0xf5c9('0x1c')](toObject(
  135. codeEnum[_0xf5c9('0x1c')], undefined, '读取Services失败'));
  136. }
  137. });
  138. }
  139. function getBLEDeviceCharacteristics() {
  140. my['getBLEDeviceCharacteristics']({
  141. 'deviceId': connectDeviceId,
  142. 'serviceId': tagServiceUUID,
  143. 'success': _0x32b130 => {
  144. let _0x28eee5 = ![];
  145. let _0x17a958 = ![];
  146. tagReadUUID = '';
  147. tagWriteUUID = '';
  148. console[_0xf5c9('0x14')]('Characteristics->', _0x32b130);
  149. for (let _0x1ca77b = 0x0; _0x1ca77b < _0x32b130['characteristics']['length']; _0x1ca77b++) {
  150. let _0x4abe38 = _0x32b130['characteristics'][_0x1ca77b]['characteristicId'];
  151. if (_0x4abe38 == androidReadUUID) {
  152. _0x28eee5 = !![];
  153. tagReadUUID = androidReadUUID;
  154. } else if (_0x4abe38 == androidWriteUUID) {
  155. _0x17a958 = !![];
  156. tagWriteUUID = androidWriteUUID;
  157. } else if (_0x4abe38 == iosReadUUID) {
  158. _0x28eee5 = !![];
  159. tagReadUUID = iosReadUUID;
  160. } else if (_0x4abe38 == iosWriteUUID) {
  161. _0x17a958 = !![];
  162. tagWriteUUID = iosWriteUUID;
  163. }
  164. if (_0x28eee5 == !![] && _0x17a958 == !![]) {
  165. break;
  166. }
  167. }
  168. if (_0x28eee5 == !![] && _0x17a958 == !![]) {
  169. notifyBLECharacteristicValueChange();
  170. } else {
  171. if (typeof connectTimer != undefined) {
  172. clearTimeout(connectTimer);
  173. }
  174. typeof connectCallback[_0xf5c9('0x1c')] == FUNCTION && connectCallback['fail'](toObject(
  175. codeEnum['fail'], undefined, '读取不到Characteristics'));
  176. }
  177. },
  178. 'fail': _0x1aa5f4 => {
  179. if (typeof connectTimer != undefined) {
  180. clearTimeout(connectTimer);
  181. }
  182. typeof connectCallback[_0xf5c9('0x1c')] == FUNCTION && connectCallback['fail'](toObject(
  183. codeEnum['fail'], undefined, '读取Characteristics失败'));
  184. }
  185. });
  186. }
  187. function notifyBLECharacteristicValueChange() {
  188. my[_0xf5c9('0x22')]({
  189. 'state': !![],
  190. 'deviceId': connectDeviceId,
  191. 'serviceId': tagServiceUUID,
  192. 'characteristicId': tagReadUUID,
  193. 'success': () => {
  194. if (typeof connectTimer != undefined) {
  195. clearTimeout(connectTimer);
  196. }
  197. setTimeout(() => {
  198. typeof connectCallback[_0xf5c9('0x1b')] == FUNCTION && connectCallback[_0xf5c9(
  199. '0x1b')](toObject(codeEnum['success'], undefined, '连接成功,握手成功'));
  200. }, 0x3e8);
  201. my['onBLECharacteristicValueChange']({
  202. 'success': _0x30bb4a => {
  203. if (read) {
  204. analyticData(_0x30bb4a[_0xf5c9('0x1a')]['toLowerCase']());
  205. }
  206. }
  207. });
  208. },
  209. 'fail': _0x5e6282 => {
  210. if (typeof connectTimer != undefined) {
  211. clearTimeout(connectTimer);
  212. }
  213. typeof connectCallback['fail'] == FUNCTION && connectCallback['fail'](toObject(codeEnum[_0xf5c9(
  214. '0x1c')], undefined, _0xf5c9('0x23')));
  215. }
  216. });
  217. }
  218. function offBLECharacteristicValueChange() {
  219. my['offBLECharacteristicValueChange']();
  220. }
  221. function analyticData(_0x3e5a78) {
  222. console[_0xf5c9('0x14')]('蓝牙数据接收:' + _0x3e5a78);
  223. if (frame[_0xf5c9('0xd')] == 0x0) {
  224. frameLen = parseInt(_0x3e5a78['slice'](0x4, 0x8), 0x10) * 0x2;
  225. }
  226. frame += _0x3e5a78;
  227. if (frame[_0xf5c9('0x9')](0x0, 0x4) != 'fe01') {
  228. frame = '';
  229. frameLen = 0x0;
  230. } else if (frame['length'] > frameLen) {
  231. frame = '';
  232. frameLen = 0x0;
  233. typeof dataHandlerCallback == FUNCTION && dataHandlerCallback(toObject(codeEnum[_0xf5c9('0x1c')], '',
  234. '数据长度越界'));
  235. } else if (frame[_0xf5c9('0xd')] == frameLen) {
  236. let _0x4b2e97 = frame[_0xf5c9('0x9')](0x8, 0xc);
  237. if (_0x4b2e97 === '2712') {
  238. let _0x1453f8 = frame['slice'](0x10);
  239. let _0x206028 = _0x1453f8['slice'](0x8, -0x6);
  240. frame = '';
  241. frameLen = 0x0;
  242. if (frames['length'] == 0x0) {
  243. let _0x15c5e1 = parseInt(_0x206028['slice'](0x4, 0x6), 0x10);
  244. framesLen = _0x15c5e1 - 0x80 + 0x1;
  245. }
  246. frames[_0xf5c9('0x1d')](_0x206028);
  247. if (frames['length'] == framesLen) {
  248. let _0x5e3a98 = !![];
  249. for (let _0xab8645 = 0x0; _0xab8645 < frames[_0xf5c9('0xd')]; _0xab8645++) {
  250. let _0x40bd69 = frames[_0xab8645];
  251. let _0x2c9f45 = 0x0;
  252. for (let _0x3a8918 = 0x1; _0x3a8918 < parseInt(_0x40bd69[_0xf5c9('0xd')] / 0x2) -
  253. 0x1; _0x3a8918++) {
  254. let _0x1e2dcc = parseInt(_0x40bd69['slice'](_0x3a8918 * 0x2, (_0x3a8918 + 0x1) * 0x2), 0x10);
  255. _0x2c9f45 ^= _0x1e2dcc;
  256. }
  257. if (_0x2c9f45 != parseInt(_0x40bd69[_0xf5c9('0x9')](-0x2), 0x10)) {
  258. _0x5e3a98 = ![];
  259. break;
  260. }
  261. }
  262. if (_0x5e3a98 == ![]) {
  263. frames = new Array();
  264. framesLen = 0x0;
  265. typeof dataHandlerCallback == FUNCTION && dataHandlerCallback(toObject(codeEnum[_0xf5c9('0x1c')],
  266. '', 'bcc校验不通过'));
  267. } else {
  268. let _0x33b27d = '';
  269. for (let _0x345bc5 = 0x0; _0x345bc5 < frames[_0xf5c9('0xd')]; _0x345bc5++) {
  270. let _0x49a282 = frames[_0x345bc5];
  271. _0x33b27d += _0x49a282[_0xf5c9('0x9')](0x8, -0x2);
  272. }
  273. frames = new Array();
  274. framesLen = 0x0;
  275. typeof dataHandlerCallback == FUNCTION && dataHandlerCallback(toObject(codeEnum['success'],
  276. _0x33b27d, '成功'));
  277. }
  278. }
  279. } else {
  280. frame = '';
  281. frameLen = 0x0;
  282. }
  283. }
  284. }
  285. function sendAndReceive(_0x232938, _0x172387, _0x2383ba, _0x30b171) {
  286. if (_0x232938 != 0x0 && _0x232938 != 0x1) {
  287. typeof _0x2383ba[_0xf5c9('0x1c')] == FUNCTION && _0x2383ba['fail'](toObject(codeEnum['success'], undefined,
  288. 'type\x20错误'));
  289. return;
  290. }
  291. if (typeof transTimer != undefined) {
  292. clearTimeout(transTimer);
  293. }
  294. transTimer = setTimeout(() => {
  295. typeof _0x2383ba['fail'] == FUNCTION && _0x2383ba[_0xf5c9('0x1c')](toObject(codeEnum['timeout'],
  296. undefined, _0x232938 == 0x0 ? '发送ICC指令超时' : '发送esam指令超时'));
  297. }, _0x30b171);
  298. cmds = _0x172387[_0xf5c9('0x9')]();
  299. var _0x3a5000 = promise(_0x172387, _0x232938);
  300. _0x3a5000 = _0x3a5000[_0xf5c9('0x1f')](_0x3e2371 => {
  301. if (typeof transTimer != undefined) {
  302. clearTimeout(transTimer);
  303. }
  304. if (_0x3e2371 === undefined) {
  305. return;
  306. }
  307. typeof _0x2383ba['success'] == FUNCTION && _0x2383ba['success'](toObject(codeEnum['success'], _0x3e2371,
  308. _0x232938 == 0x0 ? '发送ICC指令成功' : _0xf5c9('0xa')));
  309. }, (_0x423b8f, _0x29d8d8) => {
  310. if (_0x423b8f != undefined) {
  311. if (typeof transTimer != undefined) {
  312. clearTimeout(transTimer);
  313. }
  314. typeof _0x2383ba['fail'] == FUNCTION && _0x2383ba['fail'](toObject(codeEnum[_0xf5c9('0x1c')],
  315. _0x29d8d8, _0x423b8f));
  316. }
  317. });
  318. }
  319. function promise(_0x468151, _0x4d2ff8) {
  320. return new Promise((_0x34c1f8, _0x2da9e1) => {
  321. if (_0x4d2ff8 === 0x0) {
  322. var _0x3b4904 = dataUtil['makeA3SendData']('00', dataUtil['makeTLV'](_0x468151));
  323. } else {
  324. var _0x3b4904 = dataUtil[_0xf5c9('0x18')]('00', dataUtil[_0xf5c9('0x10')](_0x468151));
  325. }
  326. sendDataToDevice(_0x3b4904, _0x26bfbd => {
  327. if (_0x26bfbd['code'] === codeEnum[_0xf5c9('0x1b')]) {
  328. if (_0x26bfbd['data'][_0xf5c9('0x9')](0x2, 0x4) === '00' || _0x26bfbd[_0xf5c9('0x4')][
  329. 'slice'
  330. ](0x2, 0x4) === 'cf') {
  331. let _0xe05ae9 = _0x26bfbd['data']['slice'](0xa);
  332. let _0x209462 = dataUtil[_0xf5c9('0xf')](_0x26bfbd['data']['slice'](0xa));
  333. _0x34c1f8(_0x209462);
  334. } else {
  335. console['log']('TLV指令集有指令执行失败');
  336. let _0x295677 = _0x26bfbd['data']['slice'](0xa);
  337. let _0x41c368 = dataUtil[_0xf5c9('0xf')](_0x26bfbd[_0xf5c9('0x4')][_0xf5c9('0x9')](
  338. 0xa));
  339. _0x2da9e1(_0xf5c9('0x0') + _0x41c368[_0x41c368['length'] - 0x1][_0xf5c9('0x9')](-
  340. 0x4));
  341. }
  342. } else {
  343. console['log'](_0xf5c9('0x5'));
  344. _0x2da9e1(_0x26bfbd['msg']);
  345. }
  346. });
  347. });
  348. }
  349. function sendDataToDevice(_0x11c220, _0xdbb603) {
  350. dataHandlerCallback = _0xdbb603;
  351. sendBufferArray = new Array()[_0xf5c9('0x2')](_0x11c220);
  352. sendIndex = 0x0;
  353. read = !![];
  354. frame = '';
  355. frameLen = 0x0;
  356. frames = new Array();
  357. framesLen = 0x0;
  358. runningSendData();
  359. }
  360. function runningSendData() {
  361. let _0x1cf6e5 = sendBufferArray[sendIndex];
  362. let _0x32342d = dataUtil[_0xf5c9('0x20')](_0x1cf6e5);
  363. console[_0xf5c9('0x14')](_0xf5c9('0x12') + _0x32342d);
  364. my['writeBLECharacteristicValue']({
  365. 'deviceId': connectDeviceId,
  366. 'serviceId': tagServiceUUID,
  367. 'characteristicId': tagWriteUUID,
  368. 'value': _0x1cf6e5,
  369. 'success': function(_0x2fc6f) {
  370. sendIndex++;
  371. resendCount = 0x3;
  372. if (sendIndex < sendBufferArray[_0xf5c9('0xd')]) {
  373. runningSendData();
  374. }
  375. },
  376. 'fail': function(_0x3d2851) {
  377. if (_0x3d2851[_0xf5c9('0xc')]['indexOf']('数据格式错误') != -0x1) {
  378. typeof dataHandlerCallback == FUNCTION && dataHandlerCallback(toObject(codeEnum[_0xf5c9(
  379. '0x1c')], '', '发送的数据格式错误:' + _0x32342d));
  380. } else {
  381. typeof dataHandlerCallback == FUNCTION && dataHandlerCallback(toObject(codeEnum[_0xf5c9(
  382. '0x1c')], '', '发送数据失败:' + JSON['stringify'](_0x3d2851)));
  383. }
  384. }
  385. });
  386. }
  387. function sendA5Command(_0x1fc32c, _0x2ce9f8, _0x1cd591) {
  388. var _0x3eaa69 = setTimeout(() => {
  389. typeof _0x2ce9f8['fail'] == FUNCTION && _0x2ce9f8[_0xf5c9('0x1c')](toObject(codeEnum['fail'], undefined,
  390. _0xf5c9('0x1e')));
  391. }, _0x1cd591);
  392. var _0x1e98c4 = dataUtil['makeA5SendData'](_0x1fc32c['toUpperCase']());
  393. sendDataToDevice(_0x1e98c4, _0xabe804 => {
  394. if (_0x3eaa69 != undefined) {
  395. clearTimeout(_0x3eaa69);
  396. }
  397. console['log'](_0xf5c9('0x3'), JSON['stringify'](_0xabe804));
  398. if (_0xabe804[_0xf5c9('0x6')] === codeEnum['success']) {
  399. if (_0xabe804['data'][_0xf5c9('0x9')](0x0, 0x2) == 'b5' && _0xabe804['data']['slice'](0x2, 0x4) ==
  400. '00') {
  401. let _0x3a72fc = parseInt(_0xabe804[_0xf5c9('0x4')][_0xf5c9('0x9')](0x4, 0x6), 0x10);
  402. typeof _0x2ce9f8[_0xf5c9('0x1b')] == FUNCTION && _0x2ce9f8['success'](toObject(codeEnum[
  403. 'success'], _0xabe804[_0xf5c9('0x4')][_0xf5c9('0x9')](0x6, 0x6 + _0x3a72fc *
  404. 0x2), '成功'));
  405. } else {
  406. typeof _0x2ce9f8['fail'] == FUNCTION && _0x2ce9f8['fail'](toObject(codeEnum[_0xf5c9('0x1c')],
  407. _0xabe804['data'], _0xf5c9('0x8')));
  408. }
  409. } else {
  410. typeof _0x2ce9f8['fail'] == FUNCTION && _0x2ce9f8[_0xf5c9('0x1c')](toObject(codeEnum[_0xf5c9(
  411. '0x1c')], undefined, 'A5指令发送数据失败'));
  412. }
  413. });
  414. }
  415. function openOrCloseAerial(_0x53abde, _0x2bfc73, _0x557cdb) {
  416. if (_0x53abde == undefined || typeof _0x53abde != 'number' || _0x53abde != 0x0 && _0x53abde != 0x1) {
  417. typeof _0x2bfc73['fail'] == FUNCTION && _0x2bfc73['fail'](toObject(0xfa0, undefined, '无效参数'));
  418. } else {
  419. var _0x3aeea4 = setTimeout(() => {
  420. typeof _0x2bfc73[_0xf5c9('0x1c')] == FUNCTION && _0x2bfc73[_0xf5c9('0x1c')](toObject(0x7d0,
  421. undefined, '打开/关闭天线指令超时'));
  422. }, _0x557cdb);
  423. var _0x1299bc = 0x0;
  424. if (_0x53abde === 0x0) {
  425. _0x1299bc = 0x3;
  426. } else {
  427. _0x1299bc = 0x1;
  428. }
  429. let _0x483ee7 = 'C7' + parseInt(_0x1299bc)[_0xf5c9('0x7')](0x10)['padStart'](0x2, '0');
  430. var _0xb5d3ff = dataUtil[_0xf5c9('0x21')](_0x483ee7);
  431. console[_0xf5c9('0x14')](_0xb5d3ff);
  432. sendDataToDevice(_0xb5d3ff, _0x50a3b1 => {
  433. if (_0x3aeea4 != undefined) {
  434. clearTimeout(_0x3aeea4);
  435. }
  436. if (_0x50a3b1['code'] === codeEnum['successCode']) {
  437. if (_0x50a3b1['data']['slice'](0x0, 0x2) == 'b5' && _0x50a3b1[_0xf5c9('0x4')]['slice'](0x2,
  438. 0x4) == '00') {
  439. let _0x146e42 = parseInt(_0x50a3b1[_0xf5c9('0x4')]['slice'](0x4, 0x6), 0x10);
  440. typeof _0x2bfc73[_0xf5c9('0x1b')] == FUNCTION && _0x2bfc73['success'](toObject(codeEnum[
  441. 'successCode'], _0x50a3b1[_0xf5c9('0x4')][_0xf5c9('0x9')](0x6, 0x6 +
  442. _0x146e42 * 0x2), '成功'));
  443. } else {
  444. typeof _0x2bfc73['fail'] == FUNCTION && _0x2bfc73[_0xf5c9('0x1c')](toObject(0xfa0,
  445. _0x50a3b1['data'], _0xf5c9('0x8')));
  446. }
  447. } else {
  448. typeof _0x2bfc73['fail'] == FUNCTION && _0x2bfc73['fail'](toObject(0xfa0, undefined,
  449. '打开/关闭天线失败'));
  450. }
  451. });
  452. }
  453. }