v1.1.3
bluetoothadapter
एक फ्लटर प्लगइन जो **केवल एंड्रॉइड के लिए** ब्लूटूथ एडाप्टर की सुविधाओं को उजागर करता है।
22लाइक 6330-दिन डाउनलोड40Pub अंक
प्लेटफ़ॉर्म डेटा नहीं
GeekyAnts/flutter-bluetooth-adapter open-source repository details.
यह अंग्रेज़ी मूल स्नैपशॉट है। नवीनतम सामग्री GitHub पर देखें।
A Flutter plugin to expose the features of Bluetooth Adapter for Android only.
The primary purpose of this project was to communicate between flutter and Rasburry Pie using Bluetooth.
For a full example please check /example folder. Here are only the most important parts of the code to illustrate how to use the library.
//Initiatinng the bluetooth adapter
Bluetoothadapter flutterbluetoothadapter = Bluetoothadapter();
//Listening to the connection status listener
String _connectionStatus = "NONE";
StreamSubscription _btConnectionStatusListener =flutterbluetoothadapter.connectionStatus().listen((dynamic status) {
setState(() {
_connectionStatus = status.toString();
});
});
//Listening to the recieved messages
String _recievedMessage;
StreamSubscription _btReceivedMessageListener = flutterbluetoothadapter.receiveMessages().listen((dynamic newMessage) {
setState(() {
_recievedMessage = newMessage.toString();
});
});
List<BtDevice> devices = await flutterbluetoothadapter.getDevices();
await flutterbluetoothadapter.getDevice(deviceAddress);
await flutterbluetoothadapter.startServer();
flutterbluetoothadapter.startClient(devices.indexOf(element), true);
flutterbluetoothadapter.sendMessage(messageString);
await flutterbluetoothadapter.checkBluetooth(); //returns bool
flutterbluetoothadapter.initBlutoothConnection(uuid);
निर्भरता सूची 2 आइटम
{"sdk":"flutter"}{"sdk":"flutter"}उपयोग के अनुसार छाँटें, गतिविधि की तुलना करें और अपनाने से पहले मूल प्रोजेक्ट की आवश्यकताएँ जाँचें।
“A repository is the most basic element of GitHub.”
GitHub Docs — About repositories ↗