cordova-plugin-ble-central | Bluetooth Low Energy Central plugin | Networking library
kandi X-RAY | cordova-plugin-ble-central Summary
kandi X-RAY | cordova-plugin-ble-central Summary
This plugin enables communication between a phone and Bluetooth Low Energy (BLE) peripherals. The plugin provides a simple JavaScript API for iOS and Android. Advertising information is returned when scanning for peripherals. Service, characteristic, and property info is returned when connecting to a peripheral. All access is via service and characteristic UUIDs. The plugin manages handles internally. Simultaneous connections to multiple peripherals are supported. This plugin isn't intended for scanning beacons. Try cordova-plugin-ibeacon for iBeacons. If you want to create Bluetooth devices, try cordova-plugin-ble-peripheral. See the examples for ideas on how this plugin can be used.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Command entry point
- Refresh the device cache
- Helper method to register a Bluetooth device
- Request the priority priority of the device
- Handle connection state change
- Register a notification callback for the given service
- Returns a JSON representation of a BluetoothGatt object
- Process commands
- Invoked when a request is granted
- Connect to bluetooth device
- Check for low energy devices
- Attempts to auto - connect to the device
- On a descriptor write
- Completes the subscribed descriptor
- This method is called when a characteristic has changed
- Creates the sequence result
- From interface GATT
- Reads the L2Cap data from the Bluetooth socket
- Called when a characteristic is read
- Handles a characteristic write
- Handles a read request
- This method is called when a mobile device is enabled
- This method is called when the MPU is received
cordova-plugin-ble-central Key Features
cordova-plugin-ble-central Examples and Code Snippets
Community Discussions
Trending Discussions on cordova-plugin-ble-central
QUESTION
I use cordova-plugin-ble-central plugin for my Cordova application. It connects to an ESP32 board using BT. In case I use sequence:
...ANSWER
Answered 2021-Oct-23 at 18:54No this can generally not be done reliably, at least not on Android. See the full explanation in my answer here https://stackoverflow.com/a/43482099.
QUESTION
One month ago Google Play Console rejected my latest update and said that it is not compliant with the location in the background policies. More precisely, the google email reports " If your app is not eligible to access location in the background or does not meet requirements for accessing location in the background, please remove the permission from your manifest and in-app functionality."
I used the background location permission for scanning BLE in ionic app (https://github.com/don/cordova-plugin-ble-central ).
I removed the background location permission (ACCESS_BACKGROUND_LOCATION) from cordova plugin because, after some test, is effectively not really necessary. However, are necessary other location permission (ACCESS_FINE_LOCATION, ACCESS_COARSE_LOCATION) so I would like to know if is equally necessary to display a prominent disclosure through a pop-up alert before my app’s location runtime permission.
I tried to send an issue ticket to google developer support on April 14th, but I have not received a reply.
...ANSWER
Answered 2021-May-04 at 20:57If you target Android API version 28 or lower, ACCESS_FINE_LOCATION and ACCESS_COARSE_LOCATION implicitly implies background location permission and you must hence follow all the rules for that.
If you target Android API version 29 or higher and do not have ACCESS_BACKGROUND_LOCATION in your manifest, you will automatically comply to Google Play's background policies (since you are then not affected by them).
QUESTION
I have an issue with sequence order when reading data from ble. This issue is referenced here
The version 1.2.4 of cordova-plugin-ble-central has a new parameter to get the sequence order and leave a chance to the client to reorder the packet. The PR is here. So the callback has a second parameter that is the sequence number:
...ANSWER
Answered 2020-Aug-17 at 14:39The ionic wrapper emitted only the data array. I pushed a merged request to ionic-native repository here. Now the version 5.28.0 emit an array with at index 0 the data and at index 1 the sequence order
QUESTION
I'm trying to use my Raspberry Pi 3B to communicate with a BLE enabled device which dosen't require a PIN.
I first tried with Ionic on iOS using cordova BLE central (https://github.com/don/cordova-plugin-ble-central), which worked as expected, here is the exchanged packets :
iOS (PacketLogger)
...ANSWER
Answered 2020-Jun-07 at 07:46This looks to be happening because pairing is not supported on the Raspberry Pi. You can resolve this through a combination of btmgmt and bluetoothctl commands:-
QUESTION
Using @ionic-native/ble
I'm able to scan and discover a BLE device which has manufacturer specific data.
According to the lib (https://github.com/don/cordova-plugin-ble-central#ios-1) here is the way to get this data
...ANSWER
Answered 2020-May-19 at 18:13You can try the following :
QUESTION
I used ionic-native/google-maps in my ionic 4 app. The map div is visible, functional and draggable when I enter the page unless I have set something of the elements on the map.
When I click a button to set visibility of some Markers and Circles, they become visible/invisible successfully but the gesture of the map is not working normally. I can only scroll the map upwards, but failed to scroll it to other directions and also tilt, rotate and zoom the map unless I leave from the page and enter into the page again. Here is my code:
page.html
...ANSWER
Answered 2020-Jan-21 at 07:57Here is the solution:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install cordova-plugin-ble-central
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page