![]() ![]() It allows anyone with an Esp32 at their disposal to develop aplications that can trigger events based on the distance between the Esp32 module and the other device it is connected to *(in my case I used an Android Smartphone (Nexus 5x)). The reason I went with using Bluetooth Classic over Bluetooth Low Energy is that of range, BT Classic having a much bigger range at which it can operate at, unlike BLE (at least that's what I've read).īoth Bluetooth Modes have their ups and downs so it's up to you what's the best option, depending on your project terms, the range of operability and the battery consumption aspects, etc. With all of that being said I am sharing here the progress I've made to try and make this task a bit more easy on those who wanted to use this technology and to improve it and play with it. There are, however, some tutorials and there is some documentation for Bluetooth Low Energy (BLE) which you may find by doing a simple Google Search using the apropriate keywords. ![]() Var characteristics = service.When I started working at this Application (about 1 month ago) there was not too much documentation if any at all, in regards to meassuring distance via Bluetooth Classic (BT) for the Esp32. Read and write characteristics # // Reads all characteristics Var subscription = ((results) ') Ĭonnect to a device # // Connect to the deviceĭiscover services # List services = await device.discoverServices() Usage # Obtain an instance # FlutterBluePlus flutterBlue = FlutterBluePlus.instance įlutterBlue.startScan(timeout: Duration(seconds: 4)) The BluetoothDevice object is then used to directly interact with characteristics and descriptors. Once connected to a device, the BluetoothDevice object can discover services ( BluetoothService), characteristics ( BluetoothCharacteristic), and descriptors ( BluetoothDescriptor). ![]() Using the FlutterBluePlus instance, you can scan for and connect to nearby devices ( BluetoothDevice). Cross-Platform Bluetooth LE #įlutterBluePlus aims to offer the most from both platforms (iOS and Android). This package must be tested on a real device. Note: this plugin is continuous work from FlutterBlue since maintaince stoped. FlutterBluePlus is a bluetooth plugin for Flutter, a new app SDK to help developers build modern multi-platform apps. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |