Excellent work, we are waiting for you to create the video where it connects, sends data and also receives data. I am working on a project with an Arduino Mega and an HM-10 Bluetooth BLE module and this video and the following are very helpful to me. Thank you very much and blessings to your entire family.
We would be very grateful if you could make a video about flutter_blue_plus this week. After adding the get package, I cannot import it. The same pattern applies to the flutter_blue package.
Sir, I was trying to follow your youtube to tryout the BLE coding in flutter! I have running into some issues please help: 1. both flutter_blue and flutter_blue_plus should work? I noticed there are some discrepancies in the code snippets on your website, not sure, which one that I should follow; 2. If I am using the flutter_blue_plus package, I got build error, complaining to this line of code in main.dart : "FlutterBluePlus flutterBlue = FlutterBluePlus.instance;" the msg reads: "This expression has a type of 'void' so its value can't be used. Try checking to see if you're using the correct API; there might be a function or call that returns void you didn't expect. Also check type parameters and variables which might also be void." Please help..., Thanks...
Would like to see connect to a ble peripheral and read data in to a service and characteristics. And My main hard stop for now is how I can keep the connection active and keep receiving data in the app.
It is not workin in my case plus you didn't show complete library of your main.dart in video and the website has two code and sinnepts which is not like how professionals make videos for beginners.
@@ProtoCodersPoint import 'package:flutter_ble/ble_controller.dart is the first error it says flutter_ble is not compatible with dart 3.0.0 or above it tried to reduce the environment also but that didn't work. Second you have two procedure of your website one using flutter_blue_plus and other is flutter_blue . Flutter_blue have complete source code ( which didn't work for me ) second have not complete source code which i can copy paste and see the results to be honest i didn't use flutter_blue before so don't know how to follow those snippets and source code has the error i mentioned.
i have donbe the same exact code in flutter in android Studio Interface but I'm facing Bluetooth privilege issues since it doesn't allow for third-party apps. Any recommendations?
hello my friend, you're luckier than me, your some devices are discovered at least. I can't discover any devices around me. Could you plz send me your flutter project to compare with myself? Maybe I couldn't see some points in this video.
i copied the code you provided. the app is working but when i click scan, no bluetooth devices is shown. Permission has been added and all... ? any idea ?
Pub failed to delete entry because it was in use by another process. This may be caused by a virus scanner or having a file in the directory open in another application. When running the yaml file, it looks like this, please tell me how to fix it
Once you push enter, it will install the package Flutter_blue, but it will keep giving you that warning, but the App should run, if not, try to restart your pc.
Hey hi!! I don't know whether you have resolved the issue or not. But this problem can be solved by running your android studio or visual studio as administrator. Hope it helps someone✨
Excellent work, we are waiting for you to create the video where it connects, sends data and also receives data. I am working on a project with an Arduino Mega and an HM-10 Bluetooth BLE module and this video and the following are very helpful to me. Thank you very much and blessings to your entire family.
Agreed, really want to see a video on connecting and sending/receiving data!
We would be very grateful if you could make a video about flutter_blue_plus this week. After adding the get package, I cannot import it. The same pattern applies to the flutter_blue package.
Thank you for the wonderful video sir it is very useful for me and my team
Welcome 🤗, if you want tutorial on any topic comment down 😁
Sir, I was trying to follow your youtube to tryout the BLE coding in flutter! I have running into some issues please help: 1. both flutter_blue and flutter_blue_plus should work? I noticed there are some discrepancies in the code snippets on your website, not sure, which one that I should follow; 2. If I am using the flutter_blue_plus package, I got build error, complaining to this line of code in main.dart : "FlutterBluePlus flutterBlue = FlutterBluePlus.instance;" the msg reads: "This expression has a type of 'void' so its value can't be used.
Try checking to see if you're using the correct API; there might be a function or call that returns void you didn't expect. Also check type parameters and variables which might also be void." Please help..., Thanks...
Thank you, waiting a video on how to connect to bluetooth
glad to hear it was helpful for you, will upload the next video as soon as possible
Would like to see connect to a ble peripheral and read data in to a service and characteristics.
And My main hard stop for now is how I can keep the connection active and keep receiving data in the app.
How to transfer text or data, after connected multi device, can you help me ?
not working scan results is empty
It is not workin in my case plus you didn't show complete library of your main.dart in video and the website has two code and sinnepts which is not like how professionals make videos for beginners.
The complete source code is given in my website
Can you tell you exactly what issue you are facing ( show the error log )
@@ProtoCodersPoint
import 'package:flutter_ble/ble_controller.dart is the first error it says flutter_ble is not compatible with dart 3.0.0 or above it tried to reduce the environment also but that didn't work.
Second you have two procedure of your website one using flutter_blue_plus and other is flutter_blue
. Flutter_blue have complete source code ( which didn't work for me ) second have not complete source code which i can copy paste and see the results to be honest i didn't use flutter_blue before so don't know how to follow those snippets and source code has the error i mentioned.
how fetch the services and characteristics data from BLE and show to mobile screen ??
please make video for this.
Sure will be uploaded soon
will this work for ios app as well?
Instance feature is deprecated error showing,what i should do now
i have donbe the same exact code in flutter in android Studio Interface but I'm facing Bluetooth privilege issues since it doesn't allow for third-party apps. Any recommendations?
hi sir.When will you upload connect and data sharing part
can we show the names of the devices??? also CONNECT them... to get thier mac adfress etc
Yes we can
How to do ota update over ble in flutter
how to connect specific ble device . Please make a video
There is a video on that to on channel
All the bluetooth devices are discovering, but ESP32 BLE device is not showing what can i do??
hello my friend, you're luckier than me, your some devices are discovered at least. I can't discover any devices around me. Could you plz send me your flutter project to compare with myself? Maybe I couldn't see some points in this video.
i copied the code you provided. the app is working but when i click scan, no bluetooth devices is shown. Permission has been added and all... ? any idea ?
This video is for BLE devices not to scab normal Bluetooth devices like earphone, laptop or any other
This will just show the BLE DEVICES
@@ProtoCodersPoint thanks, i will redo it with a ble devices. what would you suggest to use if i want to work with claissic bluetooth ?
The code that you gave in the web site is not working.
Pub failed to delete entry because it was in use by another process.
This may be caused by a virus scanner or having a file
in the directory open in another application. When running the yaml file, it looks like this, please tell me how to fix it
Once you push enter, it will install the package Flutter_blue, but it will keep giving you that warning, but the App should run, if not, try to restart your pc.
Hey hi!! I don't know whether you have resolved the issue or not. But this problem can be solved by running your android studio or visual studio as administrator. Hope it helps someone✨
how to connect to a bluetooth low energy
But isn't flutter blue deprecated? When i try to run app it gives a warning of it using deprecated API
In place of flutter_blue
You can use flutter_blue_plus
The code syntax will be same…
@@ProtoCodersPoint hi, I tried the code as you suggested but it is not showing me any nearby devices, I debugged everything the scanner is starting properly and everything is fine but not devices are being shown, can you please help me? (Also I wanted to know does flutter blue plus show classic devices as well as ble devices?)
Here is my code (it is one page only) to scan and list the nearby devices.
/// Code starts
code for the screen:
import 'dart:developer';
import 'package:flutter/material.dart';
import 'package:flutter_blue/flutter_blue.dart';
import 'package:lottery/widgets/snackbar_widget.dart';
import 'package:permission_handler/permission_handler.dart';
class FBPlusScreen extends StatefulWidget {
const FBPlusScreen({super.key});
@override
State createState() => _FBPlusScreenState();
}
class _FBPlusScreenState extends State {
FlutterBlue flutterBlue = FlutterBlue.instance;
Future scanDevices() async {
var blePermission = await Permission.bluetooth.status;
var bleConperm = await Permission.bluetoothConnect.status;
var bleScanperm = await Permission.bluetoothScan.status;
log("bluetooth status: $blePermission, bluetooth connect status: $bleConperm, scanning permission: $bleScanperm");
showCustomSnackbar(context, "Success",
"bluetooth status: $blePermission, bluetooth connect status: $bleConperm, scanning permission: $bleScanperm");
if (blePermission.isDenied) {
log("in req permission case");
if (await Permission.bluetoothScan.request().isGranted) {
if (await Permission.bluetoothConnect.request().isGranted) {
flutterBlue.startScan();
await Future.delayed(const Duration(seconds: 10));
flutterBlue.stopScan();
}
}
} else {
// if permissions are granted
log("in granted permission case");
flutterBlue.startScan();
await Future.delayed(const Duration(seconds: 10));
flutterBlue.stopScan();
showCustomSnackbar(context, "Success", "${getScanResults.toString()}");
}
}
Stream get getScanResults => flutterBlue.scanResults;
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: const Text("BLE eg"),
),
body: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
const SizedBox(
height: 15,
),
StreamBuilder(
stream: getScanResults,
builder: (context, snapshot) {
if (snapshot.hasData) {
// Access the scan results from the snapshot.data
List scanResults = snapshot.data!;
return ListView.builder(
shrinkWrap: true,
itemCount: scanResults.length,
itemBuilder: (context, index) {
final data = scanResults[index];
return Card(
elevation: 2,
child: ListTile(
title: Text(data.device.name),
subtitle: Text(data.device.id.id),
trailing: Text(data.rssi.toString()),
),
);
},
);
} else {
return const Center(
child: Text("No Device Found"),
);
}
}),
ElevatedButton(
onPressed: () => scanDevices(), child: const Text("Scan")),
const SizedBox(
height: 15,
),
],
),
),
);
}
}
///Code ends
///Logs start
Main error here it shows could not find callback wrapper
logs:
D/EGL_emulation( 6763): app_time_stats: avg=115.66ms min=5.03ms max=1708.82ms count=18
[log] bluetooth status: PermissionStatus.granted, bluetooth connect status: PermissionStatus.granted, scanning permission: PermissionStatus.granted
D/BluetoothAdapter( 6763): isLeEnabled(): ON
[log] in granted permission case
2
[log] Scan results received: []
D/BluetoothLeScanner( 6763): onScannerRegistered() - status=0 scannerId=4 mScannerId=0
3
[log] Scan results received: []
D/EGL_emulation( 6763): app_time_stats: avg=96.04ms min=7.35ms max=1922.53ms count=26
2
D/BluetoothAdapter( 6763): isLeEnabled(): ON
D/BluetoothLeScanner( 6763): could not find callback wrapper
D/EGL_emulation( 6763): app_time_stats: avg=510.39ms min=4.62ms max=7495.73ms count=15
///Logs end
yes sir please make a video on how to connect to bluetooth
Sure soon video will be uploaded 🤗
The available devices do not appear :( Help meee pls
Could you solve it another way?
try turning on location
@@folaemmanuel7719 thank you bro
Getting namespace error while using this library
Share the error on my email
Let me check
@@ProtoCodersPoint and your email?
@@ProtoCodersPoint how can i get you email
I've got the same error, did you find a solution?
@@timo-vincenttenhagen3282 open build.gradle file of library and add namespace
its not working
Have you added the Bluetooth permission in androidManifest.xml file ?