{"id":316069,"date":"2021-01-07T21:00:44","date_gmt":"2021-01-07T21:00:44","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=316069"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=316069","title":{"rendered":"Android Bluetooth Low Energy (BLE) \u2014 \u0433\u043e\u0442\u043e\u0432\u0438\u043c \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e, \u0447\u0430\u0441\u0442\u044c #1"},"content":{"rendered":"\n<div class=\"post__text post__text_v2\" id=\"post-content-body\">\n<p>\u0412 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u0433\u043e\u0434 \u044f \u0440\u0430\u0437\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043b Bluetooth Low Energy (<abbr title=\"Bluetooth Low Energy\">BLE<\/abbr>) \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u0434 iOS \u0438 \u044d\u0442\u043e \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u044b\u043c. \u0414\u0430\u043b\u0435\u0435 \u0431\u044b\u043b\u043e \u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0438\u0445 \u043d\u0430 Android\u2026 \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u044d\u0442\u043e \u043c\u043e\u0433\u043b\u043e \u0431\u044b\u0442\u044c \u0441\u043b\u043e\u0436\u043d\u044b\u043c?<\/p>\n<p>\u041c\u043e\u0433\u0443 \u0442\u043e\u0447\u043d\u043e \u0441\u043a\u0430\u0437\u0430\u0442\u044c \u2013 \u044d\u0442\u043e \u0431\u044b\u043b\u043e \u0441\u043b\u043e\u0436\u043d\u0435\u0439, \u0447\u0435\u043c \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u043b, \u043c\u043d\u0435 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0438\u0442\u044c \u043d\u0435\u043c\u0430\u043b\u043e \u0443\u0441\u0438\u043b\u0438\u0439 \u0434\u043b\u044f \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b \u043f\u043e\u0434 Android. \u042f \u0438\u0437\u0443\u0447\u0438\u043b \u043c\u043d\u043e\u0433\u043e \u0441\u0442\u0430\u0442\u0435\u0439 \u0432 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e\u043c \u0434\u043e\u0441\u0442\u0443\u043f\u0435, \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u043a\u0430\u0437\u0430\u043b\u0438\u0441\u044c \u043e\u0448\u0438\u0431\u043e\u0447\u043d\u044b\u043c\u0438, \u043c\u043d\u043e\u0433\u0438\u0435 \u0431\u044b\u043b\u0438 \u043e\u0447\u0435\u043d\u044c \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u043c\u0438 \u0438 \u043f\u043e\u043c\u043e\u0433\u043b\u0438 \u0432 \u0434\u0435\u043b\u0435. \u0412 \u044d\u0442\u043e\u0439 \u0441\u0435\u0440\u0438\u0438 \u0441\u0442\u0430\u0442\u0435\u0439 \u044f \u0445\u043e\u0447\u0443 \u043e\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u0438 \u0432\u044b\u0432\u043e\u0434\u044b, \u0447\u0442\u043e\u0431\u044b \u0432\u044b \u043d\u0435 \u0442\u0440\u0430\u0442\u0438\u043b\u0438 \u0443\u0439\u043c\u0443 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u043d\u0430 \u043f\u043e\u0438\u0441\u043a\u0438 \u043a\u0430\u043a \u044f.<\/p>\n<h3>\u041e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 \u0440\u0430\u0431\u043e\u0442\u044b BLE \u043f\u043e\u0434 Android<\/h3>\n<ul>\n<li>\n<p><strong>Google \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f \u043f\u043e BLE \u043e\u0447\u0435\u043d\u044c \u043e\u0431\u0449\u0430\u044f<\/strong>, \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043d\u0435\u0442 \u0432\u0430\u0436\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u0438\u043b\u0438 \u043e\u043d\u0430 \u0443\u0441\u0442\u0430\u0440\u0435\u043b\u0430, \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439 \u043d\u0435 \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442, \u043a\u0430\u043a \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c BLE. \u042f \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u043b \u043b\u0438\u0448\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u043e\u0432, \u043a\u0430\u043a \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c BLE.&nbsp;<a href=\"https:\/\/www.stkent.com\/2017\/09\/18\/ble-on-android.html\" rel=\"noopener noreferrer nofollow\">\u041f\u0440\u0435\u0437\u0435\u043d\u0442\u0430\u0446\u0438\u044f Stuart Kent<\/a>&nbsp;\u0434\u0430\u0435\u0442 \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b \u0434\u043b\u044f \u0441\u0442\u0430\u0440\u0442\u0430. \u0414\u043b\u044f \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043f\u0440\u043e\u0434\u0432\u0438\u043d\u0443\u0442\u044b\u0445 \u0442\u0435\u043c \u0435\u0441\u0442\u044c \u0445\u043e\u0440\u043e\u0448\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f&nbsp;<a href=\"https:\/\/devzone.nordicsemi.com\/cfs-file\/__key\/communityserver-blogs-components-weblogfiles\/00-00-00-00-04-DZ-1046\/2604.BLE_5F00_on_5F00_Android_5F00_v1.0.1.pdf\" rel=\"noopener noreferrer nofollow\">Nordic<\/a>.<\/p>\n<\/li>\n<li>\n<p><strong>Android BLE API \u044d\u0442\u043e \u043d\u0438\u0437\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438<\/strong>, \u0432 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445 \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043b\u043e\u0435\u0432 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0438 (\u043a\u0430\u043a \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0441\u0434\u0435\u043b\u0430\u043d\u043e \u00ab\u0438\u0437 \u043a\u043e\u0440\u043e\u0431\u043a\u0438\u00bb \u0432 iOS-CoreBluetooth). \u041e\u0431\u044b\u0447\u043d\u043e \u043d\u0443\u0436\u043d\u043e \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c: \u043e\u0447\u0435\u0440\u0435\u0434\u044c \u043a\u043e\u043c\u0430\u043d\u0434, bonding, \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0439, \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0430 \u043e\u0448\u0438\u0431\u043e\u043a \u0438 \u0431\u0430\u0433\u043e\u0432, \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043e\u0442\u043e\u0447\u043d\u044b\u0439 \u0434\u043e\u0441\u0442\u0443\u043f . \u0421\u0430\u043c\u044b\u0435 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438:&nbsp;<a href=\"https:\/\/github.com\/iDevicesInc\/SweetBlue\" rel=\"noopener noreferrer nofollow\">SweetBlue<\/a>,&nbsp;<a href=\"https:\/\/github.com\/Polidea\/RxAndroidBle\" rel=\"noopener noreferrer nofollow\">RxAndroidBle<\/a>&nbsp;\u0438&nbsp;<a href=\"https:\/\/github.com\/NordicSemiconductor\/Android-BLE-Library\" rel=\"noopener noreferrer nofollow\">Nordic<\/a>. \u041d\u0430 \u043c\u043e\u0439 \u0432\u0437\u0433\u043b\u044f\u0434 \u0441\u0430\u043c\u0430\u044f \u043b\u0435\u0433\u043a\u0430\u044f \u0434\u043b\u044f \u0438\u0437\u0443\u0447\u0435\u043d\u0438\u044f &#8212; Nordic,&nbsp;<a href=\"https:\/\/github.com\/weliem\/blessed-android\" rel=\"noopener noreferrer nofollow\">\u0441\u043c. \u0434\u0435\u0442\u0430\u043b\u0438 \u0442\u0443\u0442<\/a>.<\/p>\n<\/li>\n<li>\n<p><strong>\u041f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u0438 \u0434\u0435\u043b\u0430\u044e\u0442 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0432 Android BLE \u0441\u0442\u0435\u043a\u0435<\/strong>&nbsp;\u0438\u043b\u0438 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0437\u0430\u043c\u0435\u043d\u044f\u044e\u0442 \u043d\u0430 \u0441\u0432\u043e\u044e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e. \u0418 \u043d\u0430\u0434\u043e \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043d\u0438\u0446\u0443 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u0440\u0430\u0437\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438. \u0422\u043e \u0447\u0442\u043e \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430 \u043e\u0434\u043d\u043e\u043c \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0435, \u043c\u043e\u0436\u0435\u0442 \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0430 \u0434\u0440\u0443\u0433\u0438\u0445! \u0412 \u0446\u0435\u043b\u043e\u043c \u043d\u0435 \u0432\u0441\u0435 \u0442\u0430\u043a \u043f\u043b\u043e\u0445\u043e, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f Samsung \u0441\u0434\u0435\u043b\u0430\u043d\u0430 \u043b\u0443\u0447\u0448\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0439 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043e\u0442 Google!<\/p>\n<\/li>\n<li>\n<p><strong>\u0412 Android \u0435\u0441\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0445 (\u0438 \u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0445) \u0431\u0430\u0433\u043e\u0432<\/strong>&nbsp;\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u0431\u044b\u0442\u044c \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u043d\u044b, \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0432 \u0432\u0435\u0440\u0441\u0438\u044f\u0445 4,5 \u0438 6. \u0411\u043e\u043b\u0435\u0435 \u043f\u043e\u0437\u0434\u043d\u0438\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u043d\u0430\u043c\u043d\u043e\u0433\u043e \u043b\u0443\u0447\u0448\u0435, \u043d\u043e \u0442\u043e\u0436\u0435 \u0438\u043c\u0435\u044e\u0442 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0435 \u0441\u0431\u043e\u0438 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u0441 <em>\u043e\u0448\u0438\u0431\u043a\u043e\u0439 133<\/em>. \u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043e\u0431 \u044d\u0442\u043e\u043c \u043d\u0438\u0436\u0435.<\/p>\n<\/li>\n<\/ul>\n<p>\u041d\u0435 \u043f\u0440\u0435\u0442\u0435\u043d\u0434\u0443\u044e \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u044f \u0440\u0435\u0448\u0438\u043b \u0432\u0441\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b, \u043d\u043e \u043c\u043d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u0432\u044b\u0439\u0442\u0438 \u043d\u0430 \u00ab\u043f\u0440\u0438\u0435\u043c\u043b\u0435\u043c\u044b\u0439\u00bb \u0443\u0440\u043e\u0432\u0435\u043d\u044c. \u041d\u0430\u0447\u043d\u0435\u043c \u0441\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<h3>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432<\/h3>\n<p>\u041f\u0435\u0440\u0435\u0434 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443 \u0432\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0435\u0433\u043e \u043f\u0440\u043e\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c. \u042d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u043a\u043b\u0430\u0441\u0441\u0430&nbsp;<code>BluetoothLeScanner<\/code>:<\/p>\n<pre><code class=\"java\">BluetoothAdapter adapter = BluetoothAdapter.getDefaultAdapter(); BluetoothLeScanner scanner = adapter.getBluetoothLeScanner();  if (scanner != null) {     scanner.startScan(filters, scanSettings, scanCallback);     Log.d(TAG, \"scan started\"); }  else {     Log.e(TAG, \"could not get scanner object\"); }<\/code><\/pre>\n<p>\u0421\u043a\u0430\u043d\u0435\u0440 \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u043d\u0430\u0439\u0442\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441&nbsp;\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u043c\u0438 <code>filters<\/code>&nbsp;\u0438&nbsp;<code>scanSettings<\/code>, \u043f\u0440\u0438 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u0438\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f&nbsp;<code>scanCallback<\/code>:<\/p>\n<pre><code class=\"java\">private final ScanCallback scanCallback = new ScanCallback() {     @Override     public void onScanResult(int callbackType, ScanResult result) {         BluetoothDevice device = result.getDevice();         \/\/ ...do whatever you want with this found device     }      @Override     public void onBatchScanResults(List&lt;ScanResult&gt; results) {         \/\/ Ignore for now     }      @Override     public void onScanFailed(int errorCode) {         \/\/ Ignore for now     } };<\/code><\/pre>\n<p>\u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u044d\u043a\u0437\u0435\u043c\u043f\u043b\u044f\u0440&nbsp;<code>ScanResult<\/code>&nbsp;, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0435\u0441\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442&nbsp;<code>BluetoothDevice<\/code>, \u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443. \u041d\u043e \u043f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043d\u0430\u0447\u0430\u0442\u044c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c\u0441\u044f, \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043c \u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435,&nbsp;<code>ScanResult<\/code>&nbsp;\u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0445 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u0439 \u043e\u0431 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435:<\/p>\n<ul>\n<li>\n<p><strong>Advertisement data<\/strong>&nbsp;&#8212; \u043c\u0430\u0441\u0441\u0438\u0432 \u0431\u0430\u0439\u0442\u043e\u0432 \u0441 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439 \u043e\u0431 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435, \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0430 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u044d\u0442\u043e \u0438\u043c\u044f \u0438 UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432, \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u0434\u0430\u0442\u044c \u0432&nbsp;<code>filters<\/code>&nbsp;\u0438\u043c\u044f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0438 UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432.<\/p>\n<\/li>\n<li>\n<p><strong>RSSI \u0443\u0440\u043e\u0432\u0435\u043d\u044c<\/strong>&nbsp;&#8212; \u0443\u0440\u043e\u0432\u0435\u043d\u044c \u0441\u0438\u0433\u043d\u0430\u043b\u0430 (\u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0431\u043b\u0438\u0437\u043a\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e).<\/p>\n<\/li>\n<li>\n<p>\u2026 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435, \u0441\u043c. \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044e \u043f\u043e&nbsp;<code>ScanResult<\/code>&nbsp;<a href=\"https:\/\/developer.android.com\/reference\/android\/net\/wifi\/ScanResult\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n<\/li>\n<\/ul>\n<p>\u041f\u043e\u043c\u043d\u0438\u043c \u043f\u0440\u043e \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u044b\u0439 \u0446\u0438\u043a\u043b&nbsp;<code>Activity<\/code>,&nbsp;<code>onScanResult<\/code>&nbsp;\u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043c\u043d\u043e\u0433\u043e\u043a\u0440\u0430\u0442\u043d\u043e \u0434\u043b\u044f \u043e\u0434\u043d\u0438\u0445 \u0438 \u0442\u0435\u0445 \u0436\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432, \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0438&nbsp;<code>Activity<\/code>&nbsp;\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c\u0441\u044f \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e, \u0432\u044b\u0437\u044b\u0432\u0430\u044e \u043b\u0430\u0432\u0438\u043d\u0443 \u0432\u044b\u0437\u043e\u0432\u043e\u0432&nbsp;<code>onScanResult<\/code>.<\/p>\n<h3>\u041d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0435\u043c \u0444\u0438\u043b\u044c\u0442\u0440 \u0434\u043b\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f<\/h3>\n<p>\u0412\u043e\u043e\u0431\u0449\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c <em>null<\/em> \u0432\u043c\u0435\u0441\u0442\u043e \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u0432 \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0432\u0441\u0435 \u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u0438\u043d\u043e\u0433\u0434\u0430 \u044d\u0442\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u043e, \u043d\u043e \u0447\u0430\u0449\u0435 \u0442\u0440\u0435\u0431\u0443\u044e\u0442\u0441\u044f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0441 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u043c \u0438\u043c\u0435\u043d\u0435\u043c \u0438\u043b\u0438 \u043d\u0430\u0431\u043e\u0440\u043e\u043c UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432.<\/p>\n<h4>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u043f\u043e UUID \u0441\u0435\u0440\u0432\u0438\u0441\u0430<\/h4>\n<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0435\u0441\u043b\u0438 \u0432\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0439\u0442\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0439 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u044b \u0430\u0440\u0442\u0435\u0440\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u043d\u044b\u043c UUID: 1810. \u041f\u0440\u0438 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u043c\u043e\u0436\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0432&nbsp;<em>Advertisement data<\/em>&nbsp;UUID \u0441\u0435\u0440\u0432\u0438\u0441, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0445\u0430\u0440\u0430\u043a\u0442\u0435\u0440\u0438\u0437\u0443\u0435\u0442 \u044d\u0442\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e. \u041d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u044d\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0435 \u043d\u0435\u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0435, \u0444\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0441\u0435\u0440\u0432\u0438\u0441\u044b \u043c\u043e\u0433\u0443\u0442 \u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c\u0441\u044f, \u0438\u043b\u0438 \u043f\u043e\u0434\u0434\u0435\u043b\u044b\u0432\u0430\u0442\u044c\u0441\u044f&nbsp;<em>Advertisement data<\/em>&nbsp;\u0434\u0430\u043d\u043d\u044b\u0435, \u0432 \u043e\u0431\u0449\u0435\u043c \u0442\u0443\u0442 \u0435\u0441\u0442\u044c \u0442\u0432\u043e\u0440\u0447\u0435\u0441\u043a\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442.<\/p>\n<p><em>\u041f\u0440\u0438\u043c. \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430: \u043e\u0434\u043d\u043e \u0438\u0437 \u043c\u043e\u0438\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0441\u043e \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u0447\u043d\u043e\u0439 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u043e\u0439, \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043b\u043e \u0441\u043f\u0438\u0441\u043e\u043a UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0432&nbsp;Advertisement data, \u0445\u043e\u0442\u044f \u0432\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438 \u044d\u0442\u043e\u0433\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u043b\u0438 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e.<\/em><\/p>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u043b\u0443\u0436\u0431\u044b \u0441 \u0430\u0440\u0442\u0435\u0440\u0438\u0430\u043b\u044c\u043d\u044b\u043c \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c:<\/p>\n<pre><code class=\"java\">UUID BLP_SERVICE_UUID = UUID.fromString(\"00001810-0000-1000-8000-00805f9b34fb\"); UUID[] serviceUUIDs = new UUID[]{BLP_SERVICE_UUID}; List&lt;ScanFilter&gt; filters = null; if(serviceUUIDs != null) {     filters = new ArrayList&lt;&gt;();     for (UUID serviceUUID : serviceUUIDs) {         ScanFilter filter = new ScanFilter.Builder()                 .setServiceUuid(new ParcelUuid(serviceUUID))                 .build();         filters.add(filter);     } } scanner.startScan(filters, scanSettings, scanCallback);<\/code><\/pre>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0439 UUID (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440&nbsp;<code>1810<\/code>), \u043e\u043d \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f&nbsp;<code>16-bit UUID<\/code>&nbsp;\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0447\u0430\u0441\u0442\u044c\u044e \u0434\u043b\u0438\u043d\u043d\u043e\u0433\u043e&nbsp;<code>128-bit UUID<\/code>&nbsp;(\u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435&nbsp;<code>00001810-000000-1000-8000-000-00805f9b34fb<\/code>). \u041a\u043e\u0440\u043e\u0442\u043a\u0438\u0439 UUID \u044d\u0442\u043e BASE_PART \u0434\u043b\u0438\u043d\u043d\u043e\u0433\u043e UUID, \u0441\u043c. \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e&nbsp;<a href=\"https:\/\/www.bluetooth.com\/specifications\/assigned-numbers\/service-discovery\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n<h4>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u043f\u043e \u0438\u043c\u0435\u043d\u0438<\/h4>\n<p>\u041f\u043e\u0438\u0441\u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0442\u043e\u0447\u043d\u043e\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u0435 \u0438\u043c\u0435\u043d\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043e\u0431\u044b\u0447\u043d\u043e \u044d\u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0432 \u0434\u0432\u0443\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445:<\/p>\n<ul>\n<li>\n<p>\u043f\u043e\u0438\u0441\u043a \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430<\/p>\n<\/li>\n<li>\n<p>\u043f\u043e\u0438\u0441\u043a \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043c\u043e\u0439 \u043d\u0430\u0433\u0440\u0443\u0434\u043d\u044b\u0439 \u043d\u0430\u043f\u0443\u043b\u044c\u0441\u043d\u0438\u043a Polar H7 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u00abPolar H7 391BBB014\u00bb, \u043f\u0435\u0440\u0432\u0430\u044f \u0447\u0430\u0441\u0442\u044c &#8212; \u00abPolar H7\u00bb \u043e\u0431\u0449\u0430\u044f \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0442\u0430\u043a\u0438\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u044d\u0442\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438, \u0430 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u0447\u0430\u0441\u0442\u044c \u00ab391BBB014\u00bb &#8212; \u0443\u043d\u0438\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u0441\u0435\u0440\u0438\u0439\u043d\u044b\u0439 \u043d\u043e\u043c\u0435\u0440. \u042d\u0442\u043e \u043e\u0447\u0435\u043d\u044c \u0440\u0430\u0441\u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u043d\u0430\u044f \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430. \u0415\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u0432\u0441\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u00abPolar H7\u00bb, \u0442\u043e \u0444\u0438\u043b\u044c\u0442\u0440 \u043f\u043e \u0438\u043c\u0435\u043d\u0438 \u0432\u0430\u043c \u043d\u0435 \u043f\u043e\u043c\u043e\u0436\u0435\u0442, \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u0438\u0441\u043a\u0430\u0442\u044c \u043f\u043e\u0434\u0441\u0442\u0440\u043e\u043a\u0443 \u0443 \u0432\u0441\u0435\u0445 \u043e\u0442\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0432&nbsp;<code>ScanResult<\/code>. \u041f\u0440\u0438\u043c\u0435\u0440 \u0441 \u043f\u043e\u0438\u0441\u043a\u043e\u043c&nbsp;<strong>\u0442\u043e\u0447\u043d\u043e<\/strong>&nbsp;\u043f\u043e \u0438\u043c\u0435\u043d\u0438:<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"java\">String[] names = new String[]{\"Polar H7 391BB014\"}; List&lt;ScanFilter&gt; filters = null; if(names != null) {     filters = new ArrayList&lt;&gt;();     for (String name : names) {         ScanFilter filter = new ScanFilter.Builder()                 .setDeviceName(name)                 .build();         filters.add(filter);     } } scanner.startScan(filters, scanSettings, scanCallback);<\/code><\/pre>\n<h4>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u043f\u043e MAC-\u0430\u0434\u0440\u0435\u0441\u0430\u043c.<\/h4>\n<p>\u041e\u0431\u044b\u0447\u043d\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0434\u043b\u044f&nbsp;<strong>\u043f\u0435\u0440\u0435\u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f<\/strong>&nbsp;\u043a \u0443\u0436\u0435 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u043c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u043c. \u041e\u0431\u044b\u0447\u043d\u043e \u043c\u044b \u043d\u0435 \u0437\u043d\u0430\u0435\u043c MAC-\u0430\u0434\u0440\u0435\u0441 \u0434\u0435\u0432\u0430\u0439\u0441\u0430, \u0435\u0441\u043b\u0438 \u043d\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043b\u0438 \u0435\u0433\u043e \u0440\u0430\u043d\u044c\u0448\u0435, \u0438\u043d\u043e\u0433\u0434\u0430 \u0430\u0434\u0440\u0435\u0441 \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442\u0441\u044f \u043d\u0430 \u043a\u043e\u0440\u043e\u0431\u043a\u0435 \u0438\u043b\u0438 \u043d\u0430 \u043a\u043e\u0440\u043f\u0443\u0441\u0435 \u0441\u0430\u043c\u043e\u0433\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u044d\u0442\u043e \u043a\u0430\u0441\u0430\u0435\u0442\u0441\u044f \u043c\u0435\u0434\u0438\u0446\u0438\u043d\u0441\u043a\u0438\u0445 \u043f\u0440\u0438\u0431\u043e\u0440\u043e\u0432. \u0421\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0434\u0440\u0443\u0433\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f, \u043d\u043e \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u0435\u0449\u0435 \u0440\u0430\u0437 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u0440\u0438 \u043e\u0447\u0438\u0441\u0442\u043a\u0435 \u043a\u0435\u0448\u0430 Bluetooth.<\/p>\n<pre><code class=\"java\">String[] peripheralAddresses = new String[]{\"01:0A:5C:7D:D0:1A\"}; \/\/ Build filters list List&lt;ScanFilter&gt; filters = null; if (peripheralAddresses != null) {     filters = new ArrayList&lt;&gt;();     for (String address : peripheralAddresses) {         ScanFilter filter = new ScanFilter.Builder()                 .setDeviceAddress(address)                 .build();         filters.add(filter);     } } scanner.startScan(filters, scanSettings, scanByServiceUUIDCallback);<\/code><\/pre>\n<p>\u0412\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u0432\u044b \u0443\u0436\u0435 \u043f\u043e\u043d\u044f\u043b\u0438, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432 \u0444\u0438\u043b\u044c\u0442\u0440\u0435 UUID, \u0438\u043c\u044f \u0438 MAC-\u0430\u0434\u0440\u0435\u0441 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430. \u0412\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043d\u0435\u043f\u043b\u043e\u0445\u043e, \u043d\u043e \u043d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u044f \u043d\u0435 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u043b \u0442\u0430\u043a\u043e\u0435. \u0425\u043e\u0442\u044f \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0432\u0430\u043c \u044d\u0442\u043e \u043f\u0440\u0438\u0433\u043e\u0434\u0438\u0442\u0441\u044f.<\/p>\n<h3>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 ScanSettings<\/h3>\n<p><code>ScanSettings<\/code> \u043e\u0431\u044a\u044f\u0441\u043d\u044f\u044e\u0442 Android \u043a\u0430\u043a \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430. \u0422\u0430\u043c \u0435\u0441\u0442\u044c \u0440\u044f\u0434 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u0434\u0430\u0442\u044c, \u043d\u0438\u0436\u0435 \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<pre><code class=\"java\">ScanSettings scanSettings = new ScanSettings.Builder()         .setScanMode(ScanSettings.SCAN_MODE_LOW_POWER)         .setCallbackType(ScanSettings.CALLBACK_TYPE_ALL_MATCHES)         .setMatchMode(ScanSettings.MATCH_MODE_AGGRESSIVE)         .setNumOfMatches(ScanSettings.MATCH_NUM_ONE_ADVERTISEMENT)         .setReportDelay(0L)         .build();<\/code><\/pre>\n<h4>ScanMode<\/h4>\n<p>\u0411\u0435\u0437\u0443\u0441\u043b\u043e\u0432\u043d\u043e, \u044d\u0442\u043e \u0441\u0430\u043c\u044b\u0439 \u0432\u0430\u0436\u043d\u044b\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440. \u041e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u043c\u0435\u0442\u043e\u0434 \u0438 \u0432\u0440\u0435\u043c\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0432 Bluetooth \u0441\u0442\u0435\u043a\u0435. \u0422\u0430\u043a\u0430\u044f \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044f \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043c\u043d\u043e\u0433\u043e \u044d\u043d\u0435\u0440\u0433\u0438\u0438 \u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c \u043d\u0430\u0434 \u044d\u0442\u0438\u043c \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u043c, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0440\u0430\u0437\u0440\u044f\u0434\u0438\u0442\u044c \u0431\u0430\u0442\u0430\u0440\u0435\u044e \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0430 \u0431\u044b\u0441\u0442\u0440\u043e. \u0415\u0441\u0442\u044c 4 \u0440\u0435\u0436\u0438\u043c\u0430 \u0440\u0430\u0431\u043e\u0442\u044b, \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e\u043c&nbsp;<a href=\"https:\/\/devzone.nordicsemi.com\/cfs-file\/__key\/communityserver-blogs-components-weblogfiles\/00-00-00-00-04-DZ-1046\/2604.BLE_5F00_on_5F00_Android_5F00_v1.0.1.pdf\" rel=\"noopener noreferrer nofollow\">Nordics<\/a> \u0438 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 <a href=\"https:\/\/developer.android.com\/reference\/android\/bluetooth\/le\/ScanSettings\" rel=\"noopener noreferrer nofollow\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0435\u0439<\/a>:<\/p>\n<ol>\n<li>\n<p><code>SCAN_MODE_LOW_POWER<\/code>. \u0412 \u044d\u0442\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435 Android \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u0442 0.5\u0441, \u043f\u043e\u0442\u043e\u043c \u0434\u0435\u043b\u0430\u0435\u0442 \u043f\u0430\u0443\u0437\u0443 \u043d\u0430 4.5\u0441. \u041f\u043e\u0438\u0441\u043a \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u043d\u044f\u0442\u044c \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0434\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f, \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u0442\u043e\u0433\u043e \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0447\u0430\u0441\u0442\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u043f\u043e\u0441\u044b\u043b\u0430\u0435\u0442 \u043f\u0430\u043a\u0435\u0442 advertisement \u0434\u0430\u043d\u043d\u044b\u0445.<\/p>\n<\/li>\n<li>\n<p><code>SCAN_MODE_BALANCED<\/code>. \u0412\u0440\u0435\u043c\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f: 2\u0441, \u0432\u0440\u0435\u043c\u044f \u043f\u0430\u0443\u0437\u044b: 3\u0441, \u00ab\u043a\u043e\u043c\u043f\u0440\u043e\u043c\u0438\u0441\u0441\u043d\u044b\u0439\u00bb \u0440\u0435\u0436\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u044b.<\/p>\n<\/li>\n<li>\n<p><code>SCAN_MODE_LOW_LATENCY<\/code>. \u0412 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, Android \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u0442 \u043d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e, \u0447\u0442\u043e \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u043e \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u0431\u043e\u043b\u044c\u0448\u0435 \u044d\u043d\u0435\u0440\u0433\u043e\u0437\u0430\u0442\u0440\u0430\u0442, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043f\u043e\u043b\u0443\u0447\u0430\u044e\u0442\u0441\u044f \u043b\u0443\u0447\u0448\u0438\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u0420\u0435\u0436\u0438\u043c \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442 \u0435\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u0441\u0432\u043e\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u043a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u0435\u0435. \u041d\u0435 \u0441\u0442\u043e\u0438\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u043b\u044f \u0434\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<\/li>\n<li>\n<p><code>SCAN_MODE_OPPORTUNISTIC<\/code>. \u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u0431\u0443\u0434\u0443\u0442 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u044b, \u0435\u0441\u043b\u0438 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438! \u0421\u0442\u0440\u043e\u0433\u043e \u0433\u043e\u0432\u043e\u0440\u044f, \u044d\u0442\u043e \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0435 \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u0443\u0435\u0442, \u0447\u0442\u043e \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u0442\u0441\u044f \u0432\u0430\u0448\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e. \u0421\u0442\u0435\u043a Android \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u044d\u0442\u043e\u0442 \u0440\u0435\u0436\u0438\u043c \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u0434\u043e\u043b\u0433\u043e\u0433\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0434\u043b\u044f \u043f\u043e\u043d\u0438\u0436\u0435\u043d\u0438\u044f \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u0432 (\u0441\u043c. \u043d\u0438\u0436\u0435 \u00ab\u041d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435\u00bb).<\/p>\n<\/li>\n<\/ol>\n<h4>Callback Type<\/h4>\n<p>\u042d\u0442\u0430 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0438\u0440\u0443\u0435\u0442 \u043a\u0430\u043a \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f callback \u0441\u043e&nbsp;<code>ScanResult<\/code>&nbsp;\u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0437\u0430\u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u043c\u0438, \u0435\u0441\u0442\u044c 3 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430:<\/p>\n<ol>\n<li>\n<p><code>CALLBACK_TYPE_ALL_MATCHES<\/code>. Callback \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0430\u0437, \u043f\u0440\u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0438 advertisement \u043f\u0430\u043a\u0435\u0442\u0430 \u043e\u0442 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432. \u041d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 &#8212; \u043a\u0430\u0436\u0434\u044b\u0435 200-500\u043c\u0441 \u0431\u0443\u0434\u0435\u0442 \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0441allback, \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0447\u0430\u0441\u0442\u043e\u0442\u044b \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 advertisement \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u043c\u0438.<\/p>\n<\/li>\n<li>\n<p><code>CALLBACK_TYPE_FIRST_MATCH<\/code>. Callback \u0441\u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043e\u0434\u0438\u043d \u0440\u0430\u0437 \u0434\u043b\u044f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u0434\u0430\u0436\u0435 \u0435\u0441\u043b\u0438 \u043e\u043d\u043e \u0434\u0430\u043b\u0435\u0435 \u0431\u0443\u0434\u0435\u0442 \u0441\u043d\u043e\u0432\u0430 \u043f\u043e\u0441\u044b\u043b\u0430\u0442\u044c advertisement \u043f\u0430\u043a\u0435\u0442\u044b.<\/p>\n<\/li>\n<li>\n<p><code>CALLBACK_TYPE_MATCH_LOST<\/code>. Callback \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u043d, \u0435\u0441\u043b\u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d \u043f\u0435\u0440\u0432\u044b\u0439 advertisement \u043f\u0430\u043a\u0435\u0442 \u043e\u0442 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0438 \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0438\u0435 advertisement \u043f\u0430\u043a\u0435\u0442\u044b \u043d\u0435 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u044b. \u041d\u0435\u043c\u043d\u043e\u0433\u043e \u0441\u0442\u0440\u0430\u043d\u043d\u043e\u0435 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435.<\/p>\n<\/li>\n<\/ol>\n<p>\u0412 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u043e\u0431\u044b\u0447\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430&nbsp;<code>CALLBACK_TYPE_ALL_MATCHES<\/code>&nbsp;\u0438\u043b\u0438&nbsp;<code>CALLBACK_TYPE_FIRST_MATCH<\/code>. \u041f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 \u0442\u0438\u043f \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u0441\u043b\u0443\u0447\u0430\u044f. \u0415\u0441\u043b\u0438 \u043d\u0435 \u0437\u043d\u0430\u0435\u0442\u0435 &#8212; \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435&nbsp;<code>CALLBACK_TYPE_ALL_MATCHES<\/code>, \u044d\u0442\u043e \u0434\u0430\u0435\u0442 \u0431\u043e\u043b\u044c\u0448\u0435 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044f \u043f\u0440\u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0438 callback, \u0435\u0441\u043b\u0438 \u0432\u044b \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u043e\u0441\u043b\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043d\u0443\u0436\u043d\u044b\u0445 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u0432 &#8212; \u0444\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u044d\u0442\u043e&nbsp;<code>CALLBACK_TYPE_FIRST_MATCH<\/code>.<\/p>\n<h4>Match mode<\/h4>\n<p>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a Android \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u00ab\u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u044f\u00bb.<\/p>\n<ol>\n<li>\n<p><code>MATCH_MODE_AGGRESSIVE<\/code>. \u0410\u0433\u0440\u0435\u0441\u0441\u0438\u0432\u043d\u043e\u0441\u0442\u044c \u043e\u0431\u0443\u0441\u043b\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u0438\u0441\u043a\u043e\u043c \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430 advertisement \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0434\u0430\u0436\u0435 \u0441\u043e \u0441\u043b\u0430\u0431\u044b\u043c \u0441\u0438\u0433\u043d\u0430\u043b\u043e\u043c.<\/p>\n<\/li>\n<li>\n<p><code>MATCH_MODE_STICKY<\/code>. \u0412 \u043f\u0440\u043e\u0442\u0438\u0432\u043e\u043f\u043e\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c, \u044d\u0442\u043e\u0442 \u0440\u0435\u0436\u0438\u043c \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u0431\u043e\u043b\u044c\u0448\u0435\u0433\u043e \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430 advertisement \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u0438 \u0445\u043e\u0440\u043e\u0448\u0435\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f \u0441\u0438\u0433\u043d\u0430\u043b\u0430 \u043e\u0442 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432.<\/p>\n<\/li>\n<\/ol>\n<p>\u042f \u043d\u0435 \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043b \u044d\u0442\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e, \u043d\u043e \u044f \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e&nbsp;<code>MATCH_MODE_AGGRESSIVE<\/code>, \u044d\u0442\u043e \u043f\u043e\u043c\u043e\u0433\u0430\u0435\u0442 \u0431\u044b\u0441\u0442\u0440\u0435\u0435 \u043d\u0430\u0439\u0442\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430.<\/p>\n<h4>Number of matches<\/h4>\n<p>\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u0441\u043a\u043e\u043b\u044c\u043a\u043e advertisement \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0434\u043b\u044f \u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u044f.<\/p>\n<ol>\n<li>\n<p><code>MATCH_NUM_ONE_ADVERTISEMENT<\/code>. \u041e\u0434\u043d\u043e\u0433\u043e \u043f\u0430\u043a\u0435\u0442\u0430 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e.<\/p>\n<\/li>\n<li>\n<p><code>MATCH_NUM_FEW_ADVERTISEMENT<\/code>. \u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u043d\u0443\u0436\u043d\u043e \u0434\u043b\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u044f.<\/p>\n<\/li>\n<li>\n<p><code>MATCH_NUM_MAX_ADVERTISEMENT<\/code>. \u041c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e advertisement \u0434\u0430\u043d\u043d\u044b\u0445, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u043c\u043e\u0436\u0435\u0442 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0437\u0430 \u043e\u0434\u0438\u043d \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 \u043a\u0430\u0434\u0440.<\/p>\n<\/li>\n<\/ol>\n<p>\u041d\u0435\u0442 \u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0432 \u0442\u0430\u043a\u043e\u043c \u043d\u0438\u0437\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u043e\u043c \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0435. \u0412\u0441\u0435 \u0447\u0442\u043e \u0432\u0430\u043c \u043d\u0430\u0434\u043e &#8212; \u0431\u044b\u0441\u0442\u0440\u043e \u043d\u0430\u0439\u0442\u0438 \u0441\u0432\u043e\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e, \u043e\u0431\u044b\u0447\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u043f\u0435\u0440\u0432\u044b\u0435 2 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430.<\/p>\n<h4>Report delay<\/h4>\n<p>\u0417\u0430\u0434\u0435\u0440\u0436\u043a\u0430 \u0434\u043b\u044f \u0432\u044b\u0437\u043e\u0432\u0430 \u0441allback \u0432 \u043c\u0438\u043b\u043b\u0438\u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445. \u0415\u0441\u043b\u0438 \u043e\u043d\u0430 \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0443\u043b\u044f, Android \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0431\u0438\u0440\u0430\u0442\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 \u044d\u0442\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0438 \u0432\u044b\u0448\u043b\u0435\u0442 \u0438\u0445 \u0441\u0440\u0430\u0437\u0443 \u0432\u0441\u0435 \u0432 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0435&nbsp;<code>onBatchScanResults<\/code>. \u0412\u0430\u0436\u043d\u043e \u043f\u043e\u043d\u0438\u043c\u0430\u0442\u044c \u0447\u0442\u043e&nbsp;<code>onScanResult<\/code>&nbsp;\u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f. \u041e\u0431\u044b\u0447\u043d\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f, \u043a\u043e\u0433\u0434\u0430 \u0435\u0441\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u043e\u0434\u043d\u043e\u0433\u043e \u0442\u0438\u043f\u0430 \u0438 \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0434\u0430\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043e\u0434\u043d\u043e \u0438\u0437 \u043d\u0438\u0445. \u0415\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u0430\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0437\u0434\u0435\u0441\u044c &#8212; \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0434\u043b\u044f \u0432\u044b\u0431\u043e\u0440\u0430, \u044d\u0442\u043e \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e MAC-\u0430\u0434\u0440\u0435\u0441 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0438\u043c\u044f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430).<\/p>\n<p>\u0412\u0430\u0436\u043d\u043e: \u0435\u0441\u0442\u044c&nbsp;<a href=\"https:\/\/devzone.nordicsemi.com\/cfs-file\/__key\/communityserver-blogs-components-weblogfiles\/00-00-00-00-04-DZ-1046\/2604.BLE_5F00_on_5F00_Android_5F00_v1.0.1.pdf\" rel=\"noopener noreferrer nofollow\">\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0439 \u0431\u0430\u0433<\/a>&nbsp;\u0434\u043b\u044f Samsung S6 \/ Samsung S6 Edge, \u043a\u043e\u0433\u0434\u0430 \u0432\u0441\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438\u043c\u0435\u044e\u0442 \u043e\u0434\u0438\u043d \u0438 \u0442\u043e\u0442 \u0436\u0435 RSSI (\u0443\u0440\u043e\u0432\u0435\u043d\u044c \u0441\u0438\u0433\u043d\u0430\u043b\u0430) \u043f\u0440\u0438 \u0437\u0430\u0434\u0435\u0440\u0436\u043a\u0435 \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0443\u043b\u044f.<\/p>\n<h3>\u041a\u0435\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 Android Bluetooth \u0441\u0442\u0435\u043a\u0430<\/h3>\n<p>\u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0432\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0435 \u0441\u043f\u0438\u0441\u043e\u043a BLE \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0438 \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0434\u0430\u043d\u043d\u044b\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u00ab\u043a\u0435\u0448\u0438\u0440\u0443\u044e\u0442\u0441\u044f\u00bb \u0432 Bluetooth \u0441\u0442\u0435\u043a\u0435. \u0422\u0430\u043c \u0445\u0440\u0430\u043d\u0438\u0442\u0441\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f: \u0438\u043c\u044f, MAC-\u0430\u0434\u0440\u0435\u0441, \u0442\u0438\u043f \u0430\u0434\u0440\u0435\u0441\u0430 (\u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0439, \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0439), \u0442\u0438\u043f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 (Classic, Dual, BLE) \u0438 \u0442.\u0434. Android \u043d\u0443\u0436\u043d\u044b \u044d\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0435, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u0441\u044f \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443 \u0431\u044b\u0441\u0442\u0440\u0435\u0435. \u041e\u043d \u043a\u0435\u0448\u0438\u0440\u0443\u0435\u0442 \u0432\u0441\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u0438\u0434\u0438\u0442 \u043f\u0440\u0438 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438. \u0414\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0438\u0437 \u043d\u0438\u0445 \u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0444\u0430\u0439\u043b \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438. \u041a\u043e\u0433\u0434\u0430 \u0432\u044b \u043f\u044b\u0442\u0430\u0435\u0442\u0435\u0441\u044c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443, \u0441\u0442\u0435\u043a Android \u0438\u0449\u0435\u0442 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0444\u0430\u0439\u043b, \u0447\u0442\u043e\u0431\u044b \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f. \u0412\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 &#8212; \u043e\u0434\u043d\u043e\u0433\u043e MAC-\u0430\u0434\u0440\u0435\u0441\u0430 \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0434\u043b\u044f \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443!<\/p>\n<h3>\u041e\u0447\u0438\u0441\u0442\u043a\u0430 \u043a\u0435\u0448\u0430<\/h3>\n<p>Bluetooth \u043a\u0435\u0448, \u043a\u0430\u043a \u0438 \u043b\u044e\u0431\u043e\u0439 \u0434\u0440\u0443\u0433\u043e\u0439, \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0432\u0435\u0447\u043d\u043e, \u0435\u0441\u0442\u044c 3 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0438, \u043a\u043e\u0433\u0434\u0430 \u043e\u043d \u043e\u0447\u0438\u0449\u0430\u0435\u0442\u0441\u044f:<\/p>\n<ol>\n<li>\n<p>\u0412\u044b\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0438 \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0430\u0442\u0435\u043b\u044f Bluetooth<\/p>\n<\/li>\n<li>\n<p>\u041f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0430 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0430<\/p>\n<\/li>\n<li>\n<p>\u041e\u0447\u0438\u0441\u0442\u043a\u0430 \u0434\u0430\u043d\u043d\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f (\u0432 \u0440\u0443\u0447\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0430)<\/p>\n<\/li>\n<\/ol>\n<p>\u042d\u0442\u043e \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043d\u0435\u0443\u0434\u043e\u0431\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0442\u0435\u043b\u0435\u0444\u043e\u043d \u0447\u0430\u0441\u0442\u043e \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u0442\u0441\u044f, \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043c\u043e\u0436\u0435\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c-\u0432\u044b\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0441\u0430\u043c\u043e\u043b\u0435\u0442\u043d\u044b\u0439 \u0440\u0435\u0436\u0438\u043c. \u0415\u0441\u0442\u044c \u0435\u0449\u0435 \u0440\u0430\u0437\u043b\u0438\u0447\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044f\u043c\u0438 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u043e\u0432, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043d\u0430 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0430\u0445 Samsung, \u043a\u0435\u0448 \u043d\u0435 \u043e\u0447\u0438\u0449\u0430\u043b\u0441\u044f \u043f\u0440\u0438 \u0432\u044b\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438 Bluetooth.<\/p>\n<p>\u042d\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442, \u0447\u0442\u043e \u043d\u0435\u043b\u044c\u0437\u044f \u043f\u043e\u043b\u0430\u0433\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u0434\u0430\u043d\u043d\u044b\u0435 \u043e\u0431 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435 \u0438\u0437 BT \u043a\u0435\u0448\u0430. \u0415\u0441\u0442\u044c \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0442\u0440\u044e\u043a, \u043e\u043d \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u0443\u0437\u043d\u0430\u0442\u044c \u0437\u0430\u043a\u0435\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u043e \u043b\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u0438\u043b\u0438 \u043d\u0435\u0442:<\/p>\n<pre><code class=\"java\">\/\/ Get device object for a mac address BluetoothDevice device = bluetoothAdapter.getRemoteDevice(peripheralAddress) \/\/ Check if the peripheral is cached or not int deviceType = device.getType(); if(deviceType == BluetoothDevice.DEVICE_TYPE_UNKNOWN) {     \/\/ The peripheral is not cached } else {     \/\/ The peripheral is cached }<\/code><\/pre>\n<p>\u042d\u0442\u043e \u0432\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442, \u0435\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443 \u043f\u043e\u0437\u0436\u0435, \u043d\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u044f \u0435\u0433\u043e. \u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043e\u0431 \u044d\u0442\u043e\u043c \u043f\u043e\u0437\u0436\u0435.<\/p>\n<h3>\u041d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435?<\/h3>\n<p>\u0412\u043e\u043e\u0431\u0449\u0435 \u0445\u043e\u0440\u043e\u0448\u0430\u044f \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430 \u2013 \u0438\u0437\u0431\u0435\u0433\u0430\u0442\u044c \u043d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e\u0433\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e, \u044d\u0442\u043e \u043e\u0447\u0435\u043d\u044c \u044d\u043d\u0435\u0440\u0433\u043e\u0435\u043c\u043a\u0430\u044f \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044f, \u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0438 \u043b\u044e\u0431\u044f\u0442, \u043a\u043e\u0433\u0434\u0430 \u0431\u0430\u0442\u0430\u0440\u0435\u044f \u0438\u0445 \u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043e\u043b\u0433\u043e. \u0415\u0441\u043b\u0438 \u0432\u0430\u043c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u0440\u0438 \u043f\u043e\u0438\u0441\u043a\u0435 BLE-\u043c\u0430\u044f\u0447\u043a\u043e\u0432, \u0432\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0441 \u043d\u0438\u0437\u043a\u0438\u043c \u043f\u043e\u0442\u0440\u0435\u0431\u043b\u0435\u043d\u0438\u0435\u043c \u0438 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0439\u0442\u0435 \u0432\u0440\u0435\u043c\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043a\u043e\u0433\u0434\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 \u043f\u0435\u0440\u0435\u0434\u043d\u0435\u043c \u043f\u043b\u0430\u043d\u0435 (foreground), \u043b\u0438\u0431\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0439\u0442\u0435 \u0441 \u043f\u0435\u0440\u0435\u0440\u044b\u0432\u0430\u043c\u0438.<\/p>\n<p>\u041f\u043b\u043e\u0445\u0430\u044f \u043d\u043e\u0432\u043e\u0441\u0442\u044c \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e Google \u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0435 \u0432\u0440\u0435\u043c\u044f \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0435\u0442 (\u043d\u0435\u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e) \u043d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435:<\/p>\n<ul>\n<li>\n<p>c Android 8.1&nbsp;<a href=\"https:\/\/stackoverflow.com\/questions\/48077690\/ble-scan-is-not-working-when-screen-is-off-on-android-8-1-0\" rel=\"noopener noreferrer nofollow\">\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0431\u0435\u0437 \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u0432 \u0431\u043b\u043e\u043a\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0432\u044b\u043a\u043b\u044e\u0447\u0435\u043d\u043d\u043e\u043c \u044d\u043a\u0440\u0430\u043d\u0435<\/a>. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435\u0442 \u043d\u0438\u043a\u0430\u043a\u0438\u0445&nbsp;<code>ScanFilters<\/code>, Android \u043f\u0440\u0438\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u043a\u043e\u0433\u0434\u0430 \u044d\u043a\u0440\u0430\u043d \u0432\u044b\u043a\u043b\u044e\u0447\u0435\u043d \u0438 \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u0442, \u043a\u043e\u0433\u0434\u0430 \u044d\u043a\u0440\u0430\u043d \u0441\u043d\u043e\u0432\u0430 \u0431\u0443\u0434\u0435\u0442 \u0432\u043a\u043b\u044e\u0447\u0435\u043d.&nbsp;<a href=\"https:\/\/android.googlesource.com\/platform\/packages\/apps\/Bluetooth\/+\/319aeae6f4ebd13678b4f77375d1804978c4a1e1\" rel=\"noopener noreferrer nofollow\">\u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438 \u043e\u0442 Google.<\/a>&nbsp;\u042d\u0442\u043e \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u043e \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u044d\u043d\u0435\u0440\u0433\u043e\u0441\u0431\u0435\u0440\u0435\u0436\u0435\u043d\u0438\u044f \u043e\u0442 Google.<\/p>\n<\/li>\n<li>\n<p>c Android 7 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 30 \u043c\u0438\u043d\u0443\u0442, \u043f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e Android \u043c\u0435\u043d\u044f\u0435\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043d\u0430&nbsp;<code>SCAN_MODE_OPPORTUNISTIC<\/code>.&nbsp;\u041e\u0447\u0435\u0432\u0438\u0434\u043d\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435, \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0441 \u043f\u0435\u0440\u0438\u043e\u0434\u043e\u043c \u043c\u0435\u043d\u0435\u0435, \u0447\u0435\u043c&nbsp;<a href=\"https:\/\/android-review.googlesource.com\/c\/platform\/packages\/apps\/Bluetooth\/+\/231662\/2\/src\/com\/android\/bluetooth\/gatt\/ScanManager.java\" rel=\"noopener noreferrer nofollow\">30 \u043c\u0438\u043d<\/a>. \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435&nbsp;<a href=\"https:\/\/android-review.googlesource.com\/c\/platform\/packages\/apps\/Bluetooth\/+\/215844\" rel=\"noopener noreferrer nofollow\">commit<\/a>&nbsp;\u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u043c \u043a\u043e\u0434\u0435.<\/p>\n<\/li>\n<li>\n<p>\u0441 Android 7 \u0437\u0430\u043f\u0443\u0441\u043a \u0438 \u043e\u0441\u0442\u0430\u043d\u043e\u0432 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0431\u043e\u043b\u0435\u0435 5 \u0440\u0430\u0437 \u0437\u0430 30 \u0441\u0435\u043a\u0443\u043d\u0434&nbsp;<a href=\"https:\/\/blog.classycode.com\/undocumented-android-7-ble-behavior-changes-d1a9bd87d983\" rel=\"noopener noreferrer nofollow\">\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u043e\u0442\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435<\/a>.<\/p>\n<\/li>\n<\/ul>\n<h3>\u041d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0432 \u0444\u043e\u043d\u0435<\/h3>\n<p>Google \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u0441\u043b\u043e\u0436\u043d\u0438\u043b \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043d\u0430 \u043f\u0435\u0440\u0435\u0434\u043d\u0435\u043c \u043f\u043b\u0430\u043d\u0435. \u0414\u043b\u044f \u0444\u043e\u043d\u043e\u0432\u043e\u0433\u043e \u0440\u0435\u0436\u0438\u043c\u0430 \u0432\u044b \u0441\u0442\u043e\u043b\u043a\u043d\u0435\u0442\u0435\u0441\u044c \u0441 \u0435\u0449\u0435 \u0431\u043e\u043b\u044c\u0448\u0438\u043c\u0438 \u0442\u0440\u0443\u0434\u043d\u043e\u0441\u0442\u044f\u043c\u0438! \u041d\u043e\u0432\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 Android \u0438\u043c\u0435\u044e\u0442 \u043b\u0438\u043c\u0438\u0442\u044b \u043d\u0430 \u0440\u0430\u0431\u043e\u0442\u0443 \u0441\u043b\u0443\u0436\u0431 \u0432 \u0444\u043e\u043d\u043e\u0432\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435, \u043e\u0431\u044b\u0447\u043d\u043e \u043f\u043e\u0441\u043b\u0435 10 \u043c\u0438\u043d\u0443\u0442 \u0440\u0430\u0431\u043e\u0442\u044b, \u0444\u043e\u043d\u043e\u0432\u044b\u0439 \u0441\u0435\u0440\u0432\u0438\u0441 \u043f\u0440\u0435\u043a\u0440\u0430\u0449\u0430\u0435\u0442 \u0441\u0432\u043e\u044e \u0440\u0430\u0431\u043e\u0442\u0443 \u043f\u0440\u0438\u043d\u0443\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e. \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0439 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b:<\/p>\n<ul>\n<li>\n<p>\u041e\u0431\u0441\u0443\u0436\u0434\u0435\u043d\u0438\u0435 \u043d\u0430&nbsp;<a href=\"https:\/\/stackoverflow.com\/questions\/51371372\/beacon-scanning-in-background-android-o\" rel=\"noopener noreferrer nofollow\">StackOverflow<\/a><\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0430\u0442\u044c\u044f&nbsp;<a href=\"http:\/\/www.davidgyoungtech.com\/2017\/08\/07\/beacon-detection-with-android-8\" rel=\"noopener noreferrer nofollow\">David Young<\/a><\/p>\n<\/li>\n<\/ul>\n<h3>\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0439 (permissions)<\/h3>\n<p>\u0415\u0441\u0442\u044c \u0435\u0449\u0435 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u0430\u0436\u043d\u044b\u0445 \u043c\u043e\u043c\u0435\u043d\u0442\u043e\u0432, \u043f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043c\u044b \u0437\u0430\u043a\u043e\u043d\u0447\u0438\u043c \u0441\u0442\u0430\u0442\u044c\u044e. \u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0443\u0436\u043d\u044b \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0435 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u044f (permissions):<\/p>\n<pre><code class=\"xml\">&lt;uses-permission android:name=\"android.permission.BLUETOOTH\" \/&gt; &lt;uses-permission android:name=\"android.permission.BLUETOOTH_ADMIN\" \/&gt; &lt;uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\" \/&gt;<\/code><\/pre>\n<p>\u0423\u0431\u0435\u0434\u0438\u0442\u0435\u0441\u044c, \u0447\u0442\u043e \u0432\u0441\u0435 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u044f \u043e\u0434\u043e\u0431\u0440\u0435\u043d\u044b, \u0438\u043b\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0438\u0442\u0435 \u0438\u0445 \u0443 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f. \u0420\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435&nbsp;<code>ACCESS_COARSE_LOCATION<\/code>&nbsp;Google \u0441\u0447\u0438\u0442\u0430\u0435\u0442 \u00ab\u043e\u043f\u0430\u0441\u043d\u044b\u043c\u00bb \u0438 \u0434\u043b\u044f \u043d\u0435\u0433\u043e \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0441\u043e\u0433\u043b\u0430\u0441\u0438\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f.<\/p>\n<pre><code class=\"java\">private boolean hasPermissions() {     if (Build.VERSION.SDK_INT &gt;= Build.VERSION_CODES.M) {         if (getApplicationContext().checkSelfPermission(Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {             requestPermissions(new String[] { Manifest.permission.ACCESS_COARSE_LOCATION }, ACCESS_COARSE_LOCATION_REQUEST);             return false;         }     }     return true; }<\/code><\/pre>\n<p><em>\u041f\u0440\u0438\u043c. \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430, \u0432 \u043c\u043e\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u0434\u043b\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 BLE \u043f\u043e\u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043b\u043e\u0441\u044c \u0435\u0449\u0435 2 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u044f:&nbsp;<\/em><code>ACCESS_FINE_LOCATION<\/code><em>&nbsp;(\u0434\u043b\u044f API&lt;23) \u0438&nbsp;<\/em><code>ACCESS_BACKGROUND_LOCATION<\/code><em>&nbsp;<\/em><a href=\"https:\/\/stackoverflow.com\/a\/32730190\/2154011\" rel=\"noopener noreferrer nofollow\"><em>\u043e\u0431\u0441\u0443\u0436\u0434\u0435\u043d\u0438\u0435 \u043d\u0430 Stackoverflow<\/em><\/a><em>.<\/em><\/p>\n<p>\u0412 \u0438\u0442\u043e\u0433\u0435 \u043f\u043e\u043b\u043d\u044b\u0439 \u0441\u043f\u0438\u0441\u043e\u043a \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0439 \u0432\u043a\u043b\u044e\u0447\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044e Android10:<\/p>\n<pre><code class=\"xml\">&lt;uses-permission android:name=\"android.permission.BLUETOOTH\" \/&gt; &lt;uses-permission android:name=\"android.permission.BLUETOOTH_ADMIN\" \/&gt; &lt;uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\" \/&gt; &lt;uses-permission android:name=\"android.permission.ACCESS_FINE_LOCATION\" \/&gt; &lt;uses-permission android:name=\"android.permission.ACCESS_BACKGROUND_LOCATION\" \/&gt;<\/code><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0432\u0441\u0435\u0445 \u043d\u0443\u0436\u043d\u044b\u0439 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0439, \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0432\u043a\u043b\u044e\u0447\u0435\u043d Bluetooth, \u0435\u0441\u043b\u0438 \u043d\u0435\u0442 &#8212; \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435&nbsp;<code>Intent<\/code>&nbsp;\u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043d\u0430 \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435:<\/p>\n<pre><code class=\"java\">BluetoothAdapter bluetoothAdapter = BluetoothAdapter.getDefaultAdapter(); if (!bluetoothAdapter.isEnabled()) {     Intent enableBtIntent = new Intent(BluetoothAdapter.ACTION_REQUEST_ENABLE);     startActivityForResult(enableBtIntent, REQUEST_ENABLE_BT); }<\/code><\/pre>\n<\/p>\n<h3>\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/h3>\n<p>\u041c\u044b \u043d\u0430\u0443\u0447\u0438\u043b\u0438\u0441\u044c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 BLE \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u043e\u0433\u043e \u0446\u0438\u043a\u043b\u0430 Activity (Fragment \/ Service), \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0444\u0438\u043b\u044c\u0442\u0440\u044b \u0438 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0442\u0430\u043a\u0436\u0435 \u0443\u0437\u043d\u0430\u043b\u0438 \u0432\u0441\u0435 \u043d\u0443\u0436\u043d\u044b\u0435 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u044f (permissions) \u0434\u043b\u044f \u0443\u0434\u0430\u0447\u043d\u043e\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 \u0440\u0430\u0431\u043e\u0442\u044b Android-Bluetooth \u043a\u0435\u0448\u0430. \u0412 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u043c\u044b \u043f\u043e\u0433\u0440\u0443\u0437\u0438\u043c\u0441\u044f \u0433\u043b\u0443\u0431\u0436\u0435 \u0432 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0438 \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u043c.<\/p>\n<p>\u0421\u043f\u0430\u0441\u0438\u0431\u043e!<\/p>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/536392\/\"> https:\/\/habr.com\/ru\/post\/536392\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text_v2\" id=\"post-content-body\">\n<p>\u0412 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u0433\u043e\u0434 \u044f \u0440\u0430\u0437\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043b Bluetooth Low Energy (<abbr title=\"Bluetooth Low Energy\">BLE<\/abbr>) \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u0434 iOS \u0438 \u044d\u0442\u043e \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u044b\u043c. \u0414\u0430\u043b\u0435\u0435 \u0431\u044b\u043b\u043e \u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0438\u0445 \u043d\u0430 Android\u2026 \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u044d\u0442\u043e \u043c\u043e\u0433\u043b\u043e \u0431\u044b\u0442\u044c \u0441\u043b\u043e\u0436\u043d\u044b\u043c?<\/p>\n<p>\u041c\u043e\u0433\u0443 \u0442\u043e\u0447\u043d\u043e \u0441\u043a\u0430\u0437\u0430\u0442\u044c \u2013 \u044d\u0442\u043e \u0431\u044b\u043b\u043e \u0441\u043b\u043e\u0436\u043d\u0435\u0439, \u0447\u0435\u043c \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u043b, \u043c\u043d\u0435 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0438\u0442\u044c \u043d\u0435\u043c\u0430\u043b\u043e \u0443\u0441\u0438\u043b\u0438\u0439 \u0434\u043b\u044f \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b \u043f\u043e\u0434 Android. \u042f \u0438\u0437\u0443\u0447\u0438\u043b \u043c\u043d\u043e\u0433\u043e \u0441\u0442\u0430\u0442\u0435\u0439 \u0432 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e\u043c \u0434\u043e\u0441\u0442\u0443\u043f\u0435, \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u043a\u0430\u0437\u0430\u043b\u0438\u0441\u044c \u043e\u0448\u0438\u0431\u043e\u0447\u043d\u044b\u043c\u0438, \u043c\u043d\u043e\u0433\u0438\u0435 \u0431\u044b\u043b\u0438 \u043e\u0447\u0435\u043d\u044c \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u043c\u0438 \u0438 \u043f\u043e\u043c\u043e\u0433\u043b\u0438 \u0432 \u0434\u0435\u043b\u0435. \u0412 \u044d\u0442\u043e\u0439 \u0441\u0435\u0440\u0438\u0438 \u0441\u0442\u0430\u0442\u0435\u0439 \u044f \u0445\u043e\u0447\u0443 \u043e\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u0438 \u0432\u044b\u0432\u043e\u0434\u044b, \u0447\u0442\u043e\u0431\u044b \u0432\u044b \u043d\u0435 \u0442\u0440\u0430\u0442\u0438\u043b\u0438 \u0443\u0439\u043c\u0443 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u043d\u0430 \u043f\u043e\u0438\u0441\u043a\u0438 \u043a\u0430\u043a \u044f.<\/p>\n<h3>\u041e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 \u0440\u0430\u0431\u043e\u0442\u044b BLE \u043f\u043e\u0434 Android<\/h3>\n<ul>\n<li>\n<p><strong>Google \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f \u043f\u043e BLE \u043e\u0447\u0435\u043d\u044c \u043e\u0431\u0449\u0430\u044f<\/strong>, \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043d\u0435\u0442 \u0432\u0430\u0436\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u0438\u043b\u0438 \u043e\u043d\u0430 \u0443\u0441\u0442\u0430\u0440\u0435\u043b\u0430, \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439 \u043d\u0435 \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442, \u043a\u0430\u043a \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c BLE. \u042f \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u043b \u043b\u0438\u0448\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u043e\u0432, \u043a\u0430\u043a \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c BLE.&nbsp;<a href=\"https:\/\/www.stkent.com\/2017\/09\/18\/ble-on-android.html\" rel=\"noopener noreferrer nofollow\">\u041f\u0440\u0435\u0437\u0435\u043d\u0442\u0430\u0446\u0438\u044f Stuart Kent<\/a>&nbsp;\u0434\u0430\u0435\u0442 \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b \u0434\u043b\u044f \u0441\u0442\u0430\u0440\u0442\u0430. \u0414\u043b\u044f \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043f\u0440\u043e\u0434\u0432\u0438\u043d\u0443\u0442\u044b\u0445 \u0442\u0435\u043c \u0435\u0441\u0442\u044c \u0445\u043e\u0440\u043e\u0448\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f&nbsp;<a href=\"https:\/\/devzone.nordicsemi.com\/cfs-file\/__key\/communityserver-blogs-components-weblogfiles\/00-00-00-00-04-DZ-1046\/2604.BLE_5F00_on_5F00_Android_5F00_v1.0.1.pdf\" rel=\"noopener noreferrer nofollow\">Nordic<\/a>.<\/p>\n<\/li>\n<li>\n<p><strong>Android BLE API \u044d\u0442\u043e \u043d\u0438\u0437\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438<\/strong>, \u0432 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445 \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043b\u043e\u0435\u0432 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0438 (\u043a\u0430\u043a \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0441\u0434\u0435\u043b\u0430\u043d\u043e \u00ab\u0438\u0437 \u043a\u043e\u0440\u043e\u0431\u043a\u0438\u00bb \u0432 iOS-CoreBluetooth). \u041e\u0431\u044b\u0447\u043d\u043e \u043d\u0443\u0436\u043d\u043e \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c: \u043e\u0447\u0435\u0440\u0435\u0434\u044c \u043a\u043e\u043c\u0430\u043d\u0434, bonding, \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0439, \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0430 \u043e\u0448\u0438\u0431\u043e\u043a \u0438 \u0431\u0430\u0433\u043e\u0432, \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043e\u0442\u043e\u0447\u043d\u044b\u0439 \u0434\u043e\u0441\u0442\u0443\u043f . \u0421\u0430\u043c\u044b\u0435 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438:&nbsp;<a href=\"https:\/\/github.com\/iDevicesInc\/SweetBlue\" rel=\"noopener noreferrer nofollow\">SweetBlue<\/a>,&nbsp;<a href=\"https:\/\/github.com\/Polidea\/RxAndroidBle\" rel=\"noopener noreferrer nofollow\">RxAndroidBle<\/a>&nbsp;\u0438&nbsp;<a href=\"https:\/\/github.com\/NordicSemiconductor\/Android-BLE-Library\" rel=\"noopener noreferrer nofollow\">Nordic<\/a>. \u041d\u0430 \u043c\u043e\u0439 \u0432\u0437\u0433\u043b\u044f\u0434 \u0441\u0430\u043c\u0430\u044f \u043b\u0435\u0433\u043a\u0430\u044f \u0434\u043b\u044f \u0438\u0437\u0443\u0447\u0435\u043d\u0438\u044f &#8212; Nordic,&nbsp;<a href=\"https:\/\/github.com\/weliem\/blessed-android\" rel=\"noopener noreferrer nofollow\">\u0441\u043c. \u0434\u0435\u0442\u0430\u043b\u0438 \u0442\u0443\u0442<\/a>.<\/p>\n<\/li>\n<li>\n<p><strong>\u041f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u0438 \u0434\u0435\u043b\u0430\u044e\u0442 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0432 Android BLE \u0441\u0442\u0435\u043a\u0435<\/strong>&nbsp;\u0438\u043b\u0438 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0437\u0430\u043c\u0435\u043d\u044f\u044e\u0442 \u043d\u0430 \u0441\u0432\u043e\u044e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e. \u0418 \u043d\u0430\u0434\u043e \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043d\u0438\u0446\u0443 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u0440\u0430\u0437\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438. \u0422\u043e \u0447\u0442\u043e \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430 \u043e\u0434\u043d\u043e\u043c \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0435, \u043c\u043e\u0436\u0435\u0442 \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0430 \u0434\u0440\u0443\u0433\u0438\u0445! \u0412 \u0446\u0435\u043b\u043e\u043c \u043d\u0435 \u0432\u0441\u0435 \u0442\u0430\u043a \u043f\u043b\u043e\u0445\u043e, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f Samsung \u0441\u0434\u0435\u043b\u0430\u043d\u0430 \u043b\u0443\u0447\u0448\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0439 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043e\u0442 Google!<\/p>\n<\/li>\n<li>\n<p><strong>\u0412 Android \u0435\u0441\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0445 (\u0438 \u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0445) \u0431\u0430\u0433\u043e\u0432<\/strong>&nbsp;\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u0431\u044b\u0442\u044c \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u043d\u044b, \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0432 \u0432\u0435\u0440\u0441\u0438\u044f\u0445 4,5 \u0438 6. \u0411\u043e\u043b\u0435\u0435 \u043f\u043e\u0437\u0434\u043d\u0438\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u043d\u0430\u043c\u043d\u043e\u0433\u043e \u043b\u0443\u0447\u0448\u0435, \u043d\u043e \u0442\u043e\u0436\u0435 \u0438\u043c\u0435\u044e\u0442 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u044b\u0435 \u0441\u0431\u043e\u0438 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u0441 <em>\u043e\u0448\u0438\u0431\u043a\u043e\u0439 133<\/em>. \u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043e\u0431 \u044d\u0442\u043e\u043c \u043d\u0438\u0436\u0435.<\/p>\n<\/li>\n<\/ul>\n<p>\u041d\u0435 \u043f\u0440\u0435\u0442\u0435\u043d\u0434\u0443\u044e \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u044f \u0440\u0435\u0448\u0438\u043b \u0432\u0441\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b, \u043d\u043e \u043c\u043d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u0432\u044b\u0439\u0442\u0438 \u043d\u0430 \u00ab\u043f\u0440\u0438\u0435\u043c\u043b\u0435\u043c\u044b\u0439\u00bb \u0443\u0440\u043e\u0432\u0435\u043d\u044c. \u041d\u0430\u0447\u043d\u0435\u043c \u0441\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<h3>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432<\/h3>\n<p>\u041f\u0435\u0440\u0435\u0434 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443 \u0432\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0435\u0433\u043e \u043f\u0440\u043e\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c. \u042d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u043a\u043b\u0430\u0441\u0441\u0430&nbsp;<code>BluetoothLeScanner<\/code>:<\/p>\n<pre><code class=\"java\">BluetoothAdapter adapter = BluetoothAdapter.getDefaultAdapter(); BluetoothLeScanner scanner = adapter.getBluetoothLeScanner();  if (scanner != null) {     scanner.startScan(filters, scanSettings, scanCallback);     Log.d(TAG, \"scan started\"); }  else {     Log.e(TAG, \"could not get scanner object\"); }<\/code><\/pre>\n<p>\u0421\u043a\u0430\u043d\u0435\u0440 \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u043d\u0430\u0439\u0442\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441&nbsp;\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u043c\u0438 <code>filters<\/code>&nbsp;\u0438&nbsp;<code>scanSettings<\/code>, \u043f\u0440\u0438 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u0438\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f&nbsp;<code>scanCallback<\/code>:<\/p>\n<pre><code class=\"java\">private final ScanCallback scanCallback = new ScanCallback() {     @Override     public void onScanResult(int callbackType, ScanResult result) {         BluetoothDevice device = result.getDevice();         \/\/ ...do whatever you want with this found device     }      @Override     public void onBatchScanResults(List&lt;ScanResult&gt; results) {         \/\/ Ignore for now     }      @Override     public void onScanFailed(int errorCode) {         \/\/ Ignore for now     } };<\/code><\/pre>\n<p>\u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u044d\u043a\u0437\u0435\u043c\u043f\u043b\u044f\u0440&nbsp;<code>ScanResult<\/code>&nbsp;, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0435\u0441\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442&nbsp;<code>BluetoothDevice<\/code>, \u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0443. \u041d\u043e \u043f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043d\u0430\u0447\u0430\u0442\u044c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c\u0441\u044f, \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043c \u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435,&nbsp;<code>ScanResult<\/code>&nbsp;\u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0445 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u0439 \u043e\u0431 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435:<\/p>\n<ul>\n<li>\n<p><strong>Advertisement data<\/strong>&nbsp;&#8212; \u043c\u0430\u0441\u0441\u0438\u0432 \u0431\u0430\u0439\u0442\u043e\u0432 \u0441 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439 \u043e\u0431 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435, \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0430 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u044d\u0442\u043e \u0438\u043c\u044f \u0438 UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432, \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u0434\u0430\u0442\u044c \u0432&nbsp;<code>filters<\/code>&nbsp;\u0438\u043c\u044f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0438 UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432.<\/p>\n<\/li>\n<li>\n<p><strong>RSSI \u0443\u0440\u043e\u0432\u0435\u043d\u044c<\/strong>&nbsp;&#8212; \u0443\u0440\u043e\u0432\u0435\u043d\u044c \u0441\u0438\u0433\u043d\u0430\u043b\u0430 (\u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0431\u043b\u0438\u0437\u043a\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e).<\/p>\n<\/li>\n<li>\n<p>\u2026 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435, \u0441\u043c. \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044e \u043f\u043e&nbsp;<code>ScanResult<\/code>&nbsp;<a href=\"https:\/\/developer.android.com\/reference\/android\/net\/wifi\/ScanResult\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n<\/li>\n<\/ul>\n<p>\u041f\u043e\u043c\u043d\u0438\u043c \u043f\u0440\u043e \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u044b\u0439 \u0446\u0438\u043a\u043b&nbsp;<code>Activity<\/code>,&nbsp;<code>onScanResult<\/code>&nbsp;\u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043c\u043d\u043e\u0433\u043e\u043a\u0440\u0430\u0442\u043d\u043e \u0434\u043b\u044f \u043e\u0434\u043d\u0438\u0445 \u0438 \u0442\u0435\u0445 \u0436\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432, \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0438&nbsp;<code>Activity<\/code>&nbsp;\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c\u0441\u044f \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e, \u0432\u044b\u0437\u044b\u0432\u0430\u044e \u043b\u0430\u0432\u0438\u043d\u0443 \u0432\u044b\u0437\u043e\u0432\u043e\u0432&nbsp;<code>onScanResult<\/code>.<\/p>\n<h3>\u041d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0435\u043c \u0444\u0438\u043b\u044c\u0442\u0440 \u0434\u043b\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f<\/h3>\n<p>\u0412\u043e\u043e\u0431\u0449\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c <em>null<\/em> \u0432\u043c\u0435\u0441\u0442\u043e \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u0432 \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0432\u0441\u0435 \u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u0438\u043d\u043e\u0433\u0434\u0430 \u044d\u0442\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u043e, \u043d\u043e \u0447\u0430\u0449\u0435 \u0442\u0440\u0435\u0431\u0443\u044e\u0442\u0441\u044f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0441 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u043c \u0438\u043c\u0435\u043d\u0435\u043c \u0438\u043b\u0438 \u043d\u0430\u0431\u043e\u0440\u043e\u043c UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432.<\/p>\n<h4>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u043f\u043e UUID \u0441\u0435\u0440\u0432\u0438\u0441\u0430<\/h4>\n<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0435\u0441\u043b\u0438 \u0432\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0439\u0442\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0439 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u044b \u0430\u0440\u0442\u0435\u0440\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u043d\u044b\u043c UUID: 1810. \u041f\u0440\u0438 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u043c\u043e\u0436\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0432&nbsp;<em>Advertisement data<\/em>&nbsp;UUID \u0441\u0435\u0440\u0432\u0438\u0441, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0445\u0430\u0440\u0430\u043a\u0442\u0435\u0440\u0438\u0437\u0443\u0435\u0442 \u044d\u0442\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e. \u041d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u044d\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0435 \u043d\u0435\u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0435, \u0444\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0441\u0435\u0440\u0432\u0438\u0441\u044b \u043c\u043e\u0433\u0443\u0442 \u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c\u0441\u044f, \u0438\u043b\u0438 \u043f\u043e\u0434\u0434\u0435\u043b\u044b\u0432\u0430\u0442\u044c\u0441\u044f&nbsp;<em>Advertisement data<\/em>&nbsp;\u0434\u0430\u043d\u043d\u044b\u0435, \u0432 \u043e\u0431\u0449\u0435\u043c \u0442\u0443\u0442 \u0435\u0441\u0442\u044c \u0442\u0432\u043e\u0440\u0447\u0435\u0441\u043a\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442.<\/p>\n<p><em>\u041f\u0440\u0438\u043c. \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430: \u043e\u0434\u043d\u043e \u0438\u0437 \u043c\u043e\u0438\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0441\u043e \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u0447\u043d\u043e\u0439 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u043e\u0439, \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043b\u043e \u0441\u043f\u0438\u0441\u043e\u043a UUID \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0432&nbsp;Advertisement data, \u0445\u043e\u0442\u044f \u0432\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0438 \u044d\u0442\u043e\u0433\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u043b\u0438 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e.<\/em><\/p>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u043b\u0443\u0436\u0431\u044b \u0441 \u0430\u0440\u0442\u0435\u0440\u0438\u0430\u043b\u044c\u043d\u044b\u043c \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c:<\/p>\n<pre><code class=\"java\">UUID BLP_SERVICE_UUID = UUID.fromString(\"00001810-0000-1000-8000-00805f9b34fb\"); UUID[] serviceUUIDs = new UUID[]{BLP_SERVICE_UUID}; List&lt;ScanFilter&gt; filters = null; if(serviceUUIDs != null) {     filters = new ArrayList&lt;&gt;();     for (UUID serviceUUID : serviceUUIDs) {         ScanFilter filter = new ScanFilter.Builder()                 .setServiceUuid(new ParcelUuid(serviceUUID))                 .build();         filters.add(filter);     } } scanner.startScan(filters, scanSettings, scanCallback);<\/code><\/pre>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0439 UUID (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440&nbsp;<code>1810<\/code>), \u043e\u043d \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f&nbsp;<code>16-bit UUID<\/code>&nbsp;\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0447\u0430\u0441\u0442\u044c\u044e \u0434\u043b\u0438\u043d\u043d\u043e\u0433\u043e&nbsp;<code>128-bit UUID<\/code>&nbsp;(\u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435&nbsp;<code>00001810-000000-1000-8000-000-00805f9b34fb<\/code>). \u041a\u043e\u0440\u043e\u0442\u043a\u0438\u0439 UUID \u044d\u0442\u043e BASE_PART \u0434\u043b\u0438\u043d\u043d\u043e\u0433\u043e UUID, \u0441\u043c. \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e&nbsp;<a href=\"https:\/\/www.bluetooth.com\/specifications\/assigned-numbers\/service-discovery\" rel=\"noopener noreferrer nofollow\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n<h4>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u043f\u043e \u0438\u043c\u0435\u043d\u0438<\/h4>\n<p>\u041f\u043e\u0438\u0441\u043a \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0442\u043e\u0447\u043d\u043e\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0435\u043d\u0438\u0435 \u0438\u043c\u0435\u043d\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043e\u0431\u044b\u0447\u043d\u043e \u044d\u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0432 \u0434\u0432\u0443\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445:<\/p>\n<ul>\n<li>\n<p>\u043f\u043e\u0438\u0441\u043a \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430<\/p>\n<\/li>\n<li>\n<p>\u043f\u043e\u0438\u0441\u043a \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043c\u043e\u0439 \u043d\u0430\u0433\u0440\u0443\u0434\u043d\u044b\u0439 \u043d\u0430\u043f\u0443\u043b\u044c\u0441\u043d\u0438\u043a Polar H7 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u00abPolar H7 391BBB014\u00bb, \u043f\u0435\u0440\u0432\u0430\u044f \u0447\u0430\u0441\u0442\u044c &#8212; \u00abPolar H7\u00bb \u043e\u0431\u0449\u0430\u044f \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0442\u0430\u043a\u0438\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u044d\u0442\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438, \u0430 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u0447\u0430\u0441\u0442\u044c \u00ab391BBB014\u00bb &#8212; \u0443\u043d\u0438\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u0441\u0435\u0440\u0438\u0439\u043d\u044b\u0439 \u043d\u043e\u043c\u0435\u0440. \u042d\u0442\u043e \u043e\u0447\u0435\u043d\u044c \u0440\u0430\u0441\u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u043d\u0430\u044f \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430. \u0415\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u0432\u0441\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 \u00abPolar H7\u00bb, \u0442\u043e \u0444\u0438\u043b\u044c\u0442\u0440 \u043f\u043e \u0438\u043c\u0435\u043d\u0438 \u0432\u0430\u043c \u043d\u0435 \u043f\u043e\u043c\u043e\u0436\u0435\u0442, \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u0438\u0441\u043a\u0430\u0442\u044c \u043f\u043e\u0434\u0441\u0442\u0440\u043e\u043a\u0443 \u0443 \u0432\u0441\u0435\u0445 \u043e\u0442\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u0432&nbsp;<code>ScanResult<\/code>. \u041f\u0440\u0438\u043c\u0435\u0440 \u0441 \u043f\u043e\u0438\u0441\u043a\u043e\u043c&nbsp;<strong>\u0442\u043e\u0447\u043d\u043e<\/strong>&nbsp;\u043f\u043e \u0438\u043c\u0435\u043d\u0438:<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"java\">String[] names = new String[]{\"Polar H7 391BB014\"}; List&lt;ScanFilter&gt; filters = null; if(names != null) {     filters = new ArrayList&lt;&gt;();     for (String name : names) {         ScanFilter filter = new ScanFilter.Builder()                 .setDeviceName(name)                 .build();         filters.add(filter);     } } scanner.startScan(filters, scanSettings, scanCallback);<\/code><\/pre>\n<h4>\u0421\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 \u043f\u043e MAC-\u0430\u0434\u0440\u0435\u0441\u0430\u043c.<\/h4>\n<p>\u041e\u0431\u044b\u0447\u043d\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0434\u043b\u044f&nbsp;<strong>\u043f\u0435\u0440\u0435\u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f<\/strong>&nbsp;\u043a \u0443\u0436\u0435 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u043c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u043c. \u041e\u0431\u044b\u0447\u043d\u043e \u043c\u044b \u043d\u0435 \u0437\u043d\u0430\u0435\u043c MAC-\u0430\u0434\u0440\u0435\u0441 \u0434\u0435\u0432\u0430\u0439\u0441\u0430, \u0435\u0441\u043b\u0438 \u043d\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043b\u0438 \u0435\u0433\u043e \u0440\u0430\u043d\u044c\u0448\u0435, \u0438\u043d\u043e\u0433\u0434\u0430 \u0430\u0434\u0440\u0435\u0441 \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442\u0441\u044f \u043d\u0430 \u043a\u043e\u0440\u043e\u0431\u043a\u0435 \u0438\u043b\u0438 \u043d\u0430 \u043a\u043e\u0440\u043f\u0443\u0441\u0435 \u0441\u0430\u043c\u043e\u0433\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u044d\u0442\u043e \u043a\u0430\u0441\u0430\u0435\u0442\u0441\u044f \u043c\u0435\u0434\u0438\u0446\u0438\u043d\u0441\u043a\u0438\u0445 \u043f\u0440\u0438\u0431\u043e\u0440\u043e\u0432. \u0421\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0434\u0440\u0443\u0433\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f, \u043d\u043e \u0432 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u0435\u0449\u0435 \u0440\u0430\u0437 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u0440\u0438 \u043e\u0447\u0438\u0441\u0442\u043a\u0435 \u043a\u0435\u0448\u0430 Bluetooth.<\/p>\n<pre><code class=\"java\">String[] peripheralAddresses = new String[]{\"01:0A:5C:7D:D0:1A\"}; \/\/ Build filters list List&lt;ScanFilter&gt; filters = null; if (peripheralAddresses != null) {     filters = new ArrayList&lt;&gt;();     for (String address : peripheralAddresses) {         ScanFilter filter = new ScanFilter.Builder()                 .setDeviceAddress(address)                 .build();         filters.add(filter);     } } scanner.startScan(filters, scanSettings, scanByServiceUUIDCallback);<\/code><\/pre>\n<p>\u0412\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u0432\u044b \u0443\u0436\u0435 \u043f\u043e\u043d\u044f\u043b\u0438, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432 \u0444\u0438\u043b\u044c\u0442\u0440\u0435 UUID, \u0438\u043c\u044f \u0438 MAC-\u0430\u0434\u0440\u0435\u0441 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430. \u0412\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043d\u0435\u043f\u043b\u043e\u0445\u043e, \u043d\u043e \u043d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u044f \u043d\u0435 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u043b \u0442\u0430\u043a\u043e\u0435. \u0425\u043e\u0442\u044f \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0432\u0430\u043c \u044d\u0442\u043e \u043f\u0440\u0438\u0433\u043e\u0434\u0438\u0442\u0441\u044f.<\/p>\n<h3>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 ScanSettings<\/h3>\n<p><code>ScanSettings<\/code> \u043e\u0431\u044a\u044f\u0441\u043d\u044f\u044e\u0442 Android \u043a\u0430\u043a \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430. \u0422\u0430\u043c \u0435\u0441\u0442\u044c \u0440\u044f\u0434 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u0434\u0430\u0442\u044c, \u043d\u0438\u0436\u0435 \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<pre><code class=\"java\">ScanSettings scanSettings = new ScanSettings.Builder()         .setScanMode(ScanSettings.SCAN_MODE_LOW_POWER)         .setCallbackType(ScanSettings.CALLBACK_TYPE_ALL_MATCHES)         .setMatchMode(ScanSettings.MATCH_MODE_AGGRESSIVE)         .setNumOfMatches(ScanSettings.MATCH_NUM_ONE_ADVERTISEMENT)         .setReportDelay(0L)         .build();<\/code><\/pre>\n<h4>ScanMode<\/h4>\n<p>\u0411\u0435\u0437\u0443\u0441\u043b\u043e\u0432\u043d\u043e, \u044d\u0442\u043e \u0441\u0430\u043c\u044b\u0439 \u0432\u0430\u0436\u043d\u044b\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440. \u041e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u043c\u0435\u0442\u043e\u0434 \u0438 \u0432\u0440\u0435\u043c\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0432 Bluetooth \u0441\u0442\u0435\u043a\u0435. \u0422\u0430\u043a\u0430\u044f \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044f \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043c\u043d\u043e\u0433\u043e \u044d\u043d\u0435\u0440\u0433\u0438\u0438 \u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c \u043d\u0430\u0434 \u044d\u0442\u0438\u043c \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u043c, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0440\u0430\u0437\u0440\u044f\u0434\u0438\u0442\u044c \u0431\u0430\u0442\u0430\u0440\u0435\u044e \u0442\u0435\u043b\u0435\u0444\u043e\u043d\u0430 \u0431\u044b\u0441\u0442\u0440\u043e. \u0415\u0441\u0442\u044c 4 \u0440\u0435\u0436\u0438\u043c\u0430 \u0440\u0430\u0431\u043e\u0442\u044b, \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e\u043c&nbsp;<a href=\"https:\/\/devzone.nordicsemi.com\/cfs-file\/__key\/communityserver-blogs-components-weblogfiles\/00-00-00-00-04-DZ-1046\/2604.BLE_5F00_on_5F00_Android_5F00_v1.0.1.pdf\" rel=\"noopener noreferrer nofollow\">Nordics<\/a> \u0438 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 <a href=\"https:\/\/developer.android.com\/reference\/android\/bluetooth\/le\/ScanSettings\" rel=\"noopener noreferrer nofollow\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0435\u0439<\/a>:<\/p>\n<ol>\n<li>\n<p><code>SCAN_MODE_LOW_POWER<\/code>. \u0412 \u044d\u0442\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435 Android \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u0442 0.5\u0441, \u043f\u043e\u0442\u043e\u043c \u0434\u0435\u043b\u0430\u0435\u0442 \u043f\u0430\u0443\u0437\u0443 \u043d\u0430 4.5\u0441. \u041f\u043e\u0438\u0441\u043a \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u043d\u044f\u0442\u044c \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0434\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f, \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u0442\u043e\u0433\u043e \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0447\u0430\u0441\u0442\u043e \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u043f\u043e\u0441\u044b\u043b\u0430\u0435\u0442 \u043f\u0430\u043a\u0435\u0442 advertisement \u0434\u0430\u043d\u043d\u044b\u0445.<\/p>\n<\/li>\n<li>\n<p><code>SCAN_MODE_BALANCED<\/code>. \u0412\u0440\u0435\u043c\u044f \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f: 2\u0441, \u0432\u0440\u0435\u043c\u044f \u043f\u0430\u0443\u0437\u044b: 3\u0441, \u00ab\u043a\u043e\u043c\u043f\u0440\u043e\u043c\u0438\u0441\u0441\u043d\u044b\u0439\u00bb \u0440\u0435\u0436\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u044b.<\/p>\n<\/li>\n<li>\n<p><code>SCAN_MODE_LOW_LATENCY<\/code>. \u0412 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, Android \u0441\u043a\u0430\u043d\u0438\u0440\u0443\u0435\u0442 \u043d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e, \u0447\u0442\u043e \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u043e \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u0431\u043e\u043b\u044c\u0448\u0435 \u044d\u043d\u0435\u0440\u0433\u043e\u0437\u0430\u0442\u0440\u0430\u0442, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043f\u043e\u043b\u0443\u0447\u0430\u044e\u0442\u0441\u044f \u043b\u0443\u0447\u0448\u0438\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u0420\u0435\u0436\u0438\u043c \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442 \u0435\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u0441\u0432\u043e\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e \u043a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u0435\u0435. \u041d\u0435 \u0441\u0442\u043e\u0438\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u043b\u044f \u0434\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<\/li>\n<li>\n<p><code>SCAN_MODE_OPPORTUNISTIC<\/code>. \u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u0431\u0443\u0434\u0443\u0442 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u044b, \u0435\u0441\u043b\u0438 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438! \u0421\u0442\u0440\u043e\u0433\u043e \u0433\u043e\u0432\u043e\u0440\u044f, \u044d\u0442\u043e \u0432\u043e\u043e\u0431\u0449\u0435 \u043d\u0435 \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u0443\u0435\u0442, \u0447\u0442\u043e \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u0442\u0441\u044f \u0432\u0430\u0448\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e. \u0421\u0442\u0435\u043a Android \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u044d\u0442\u043e\u0442 \u0440\u0435\u0436\u0438\u043c \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u0434\u043e\u043b\u0433\u043e\u0433\u043e \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0434\u043b\u044f \u043f\u043e\u043d\u0438\u0436\u0435\u043d\u0438\u044f \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u0432 (\u0441\u043c. \u043d\u0438\u0436\u0435 \u00ab\u041d\u0435\u043f\u0440\u0435\u0440\u044b\u0432\u043d\u043e\u0435 \u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435\u00bb).<\/p>\n<\/li>\n<\/ol>\n<h4>Callback Type<\/h4>\n<p>\u042d\u0442\u0430 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0438\u0440\u0443\u0435\u0442 \u043a\u0430\u043a \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f callback \u0441\u043e&nbsp;<code>ScanResult<\/code>&nbsp;\u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0437\u0430\u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u043c\u0438, \u0435\u0441\u0442\u044c 3 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430:<\/p>\n<ol>\n<li>\n<p><code>CALLBACK_TYPE_ALL_MATCHES<\/code>. Callback \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0430\u0437, \u043f\u0440\u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0438 advertisement \u043f\u0430\u043a\u0435\u0442\u0430 \u043e\u0442 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432. \u041d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 &#8212; \u043a\u0430\u0436\u0434\u044b\u0435 200-500\u043c\u0441 \u0431\u0443\u0434\u0435\u0442 \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0441allback, \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0447\u0430\u0441\u0442\u043e\u0442\u044b \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 advertisement \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u043c\u0438.<\/p>\n<\/li>\n<li>\n<p><code>CALLBACK_TYPE_FIRST_MATCH<\/code>. Callback \u0441\u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043e\u0434\u0438\u043d \u0440\u0430\u0437 \u0434\u043b\u044f \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u0434\u0430\u0436\u0435 \u0435\u0441\u043b\u0438 \u043e\u043d\u043e \u0434\u0430\u043b\u0435\u0435 \u0431\u0443\u0434\u0435\u0442 \u0441\u043d\u043e\u0432\u0430 \u043f\u043e\u0441\u044b\u043b\u0430\u0442\u044c advertisement \u043f\u0430\u043a\u0435\u0442\u044b.<\/p>\n<\/li>\n<li>\n<p><code>CALLBACK_TYPE_MATCH_LOST<\/code>. Callback \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u043d, \u0435\u0441\u043b\u0438<\/p>\n<\/li>\n<\/ol>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-316069","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/316069","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=316069"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/316069\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=316069"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=316069"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=316069"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}