#173

  Переглядів 126,309

Andreas Spiess

3 роки тому

So far, we had to use Espressif’s tools to use Bluetooth on the ESP32. Today I will try it with the Arduino IDE. I am curious how it will work. Maybe you come with me on this discovery tour? For sure, we will learn a lot about how Bluetooth low energy, or BLE, works.

In this video we will cover:
- The basics of Bluetooth Low energy
- The different roles of devices
- How we debug BLE connections using our Smartphone
- We will build a notifier and a client
- We will try to fake a Polar H7 Heart Rate monitor (at least, the BLE part
- If we have time, we will have a look at An iTag Chain finder and a Xiaomi Flower care system
- And maybe we will discover some “secret sauces” necessary for a delicious meal?

Links:
BLE services: www.bluetooth.com/specificati...
Neil Kolban Github: github.com/nkolban
Neil Kolban books: leanpub.com/u/kolban
ESP32 Development Board: bit.ly/2sOMR3E

Supporting Material and Blog Page: www.sensorsiot.org
Github: www.github.com/sensorsiot
If you want to support the channel and buy from Banggood use this link to start your shopping: bit.ly/2jAQEf4 (no additional charges for you)
Official Wemos Store: s.click.aliexpress.com/e/jUzBiIq
profile.php?...
spiessa
www.instructables.com/member/...
Please do not try to Email me or invite me on LinkedIn. These communication channels are reserved for my main job
If you want to buy me a coffee: www.paypal.me/AndreasSpiess

КОМЕНТАРІ
Ahmet Basri Altay
Ahmet Basri Altay 6 днів тому
Hello good day. I tried to do a similar work with the esp32 wroom 32u module and the HM-BT4502B module, but without success. As far as I understand, in the code "if (advertisedDevice.haveServiceUUID() && advertisedDevice.isAdvertisingService(serviceUUID)) {" I can't get into this if structure at all. What can I do? Can you help me?
Andreas Spiess
Andreas Spiess 5 днів тому
Unfortunately, I cannot do remote consulting. But I do not think you need BLE on the ESP32 if you use a HM-BT4502B. It works with AT commands.
CallMe RK
CallMe RK 13 днів тому
Haha.. We need more like this.. fun learning.. you gotta be nerd to get those jokes, though.. :)
Andreas Spiess
Andreas Spiess 13 днів тому
We are all nerds on this channel ;-)
Mi ru
Mi ru 4 місяці тому
hi, i know this video is fairly old video but the link to ble service doesnt work anymore as it direct to other page. they remove it probably. i can find the assigned number in their pdf but for the love of me i couldnt find the characteristic of each service. any clue where can i find them?
Andreas Spiess
Andreas Spiess 4 місяці тому
Just use google. The change the address from time-to time...
Radu Horga
Radu Horga 4 місяці тому
Hi! Do you know any method to limit on the server the number of incomming connections (clients) to one? Thank you.
Andreas Spiess
Andreas Spiess 4 місяці тому
I never looked at this topic, so I do not know.
Kinetic
Kinetic 6 місяців тому
@Andreas, the older polar hr straps connect via a low frequency transmission (5khz) called gymlink that is coded, not sure which watch you have, but it looks like this will likely be the case. Like the h10 strap, you'll find the h7 is Bluetooth AND polar proprietary coded transmission, so the watch isn't picking up BLE, it's looking for the polar gymlink transmission at 5khz, that's why you couldn't connect it, you were a couple of MHz off 😁 Not to worry, the polar app phone functions are much better than the watch anyway!
Andreas Spiess
Andreas Spiess 6 місяців тому
I do not know. For sure the watch communicates with my smartphone using BLE.
Kinetic
Kinetic 6 місяців тому
Polar still use 5khz because it makes HR strap useable underwater. ANT+ and BT are 2.4ghz and far too high frequency to penetrate water.
Usman Iqbal
Usman Iqbal 6 місяців тому
Thank you so much for your Efforts! This video was very useful to understand BLE ! Keep making more Video!
Web Developer Ninja
Web Developer Ninja 7 місяців тому
Thanks
Andreas Spiess
Andreas Spiess 7 місяців тому
Welcome!
Wei Ang
Wei Ang 7 місяців тому
Great tutorial! But may I know how to get the two uuid?
Wei Ang
Wei Ang 7 місяців тому
@Andreas Spiess alright, thank you!
Andreas Spiess
Andreas Spiess 7 місяців тому
First link in the video description
Emilio Rubio Garcia
Emilio Rubio Garcia 8 місяців тому
Hi, Have u ever worked on HM-1x BLE 5.0 modules? I am trying to work with HM-18 module with Arduino Mega and it's quite difficult to find info about it. Thank you very much in advance and thank you for your wonderful videos.
Andreas Spiess
Andreas Spiess 7 місяців тому
I never used these modules so far.
Shamsher Ansari
Shamsher Ansari 8 місяців тому
Indeed it is healthy for you running up and down the stairs 😁
Andreas Spiess
Andreas Spiess 8 місяців тому
True!
Enver Haase
Enver Haase 9 місяців тому
Hi Andreas, which board do you select in the Arduino Desktop IDE? I haven't had good success with the www.amazon.de/-/en/gp/product/B071JR9WS9 . So I am now waiting for your exact board type to be delivered.
Andreas Spiess
Andreas Spiess 9 місяців тому
I always use the ESP32 dev board. But for some boards you have to manually press the boot button for upload.
Paul Mooij
Paul Mooij 10 місяців тому
Hi great, movie Check out michealkroll/ble-Shield on github for some extra info Also for fun I did hackathon on similar sensors enjoy ukposts.info/have/v-deo/kYN3lm2shZhpsIE.html
Jairo Reyes
Jairo Reyes 10 місяців тому
Good video, how can I make a simple process a resend some data to the phone? For example, a humidity sensor and a light sensor send data to a device, and then the device sends these data to my phone via Bluetooth. Can a ESP32 be configured as Client and server at the same time? Thanks
Andreas Spiess
Andreas Spiess 10 місяців тому
I never did that.
András Gulis
András Gulis 11 місяців тому
Great tutorial! thanks
Andreas Spiess
Andreas Spiess 10 місяців тому
You are welcome
Aza's Built to Code
Aza's Built to Code 11 місяців тому
4:10 nRF connect app mentioned
Andreas Spiess
Andreas Spiess 11 місяців тому
Yes
Bernard-Charles Barrois
Bernard-Charles Barrois Рік тому
Hi Andreas, Some news ? Did you try the "ESP-NOW" ?
Peter Gamma
Peter Gamma Рік тому
Hello, Andreas Spiess, thank you for your great video. The fact that you had 92.287 views of your video proofs, that you have something interesting to explain. You show an example how to connect a Polar H7 to a smartphone. I m looking for an instructional video how to connect a Polar H7 to Matlab over BLE. Here is the instruction: www.mathworks.com/help/comm/examples/modeling-of-ble-devices-with-heart-rate-profile.html Unfortunately, I did not find an instructional video for it, the closest instructional video is yours. Therefore I ask you as an expert. The Matlab BLE example Model looks very theoretical. Unfortunately, I could not find a practical instruction, and I m new in the field of BLE. Still it would be great to be able to connect a Polar H7 to a PC to Matlab, I could not find another way to do it. What is your view as an expert, when you look at the Matlab BLE model. To you think it is sufficient as a practical instruction to connect for instance a Polar H7 to a PC, or is it only a theoretical model? Peter Gamma, greetings from Switzerland. I accept also answers in Swiss German.
Peter Gamma
Peter Gamma Рік тому
Thank you for your heart, Andreas. I m not connected to Adafruit in any way, but they really have great products. When you take not only one BLE sensor, but two, then your already have a bike computer: learn.adafruit.com/pyloton
Peter Gamma
Peter Gamma Рік тому
@Andreas Spiess Thank you, Andreas. I already found a device which is simpler than the Matlab Model. It is an Arduino like device from Adafruid: learn.adafruit.com/circuitpython-ble-heart-rate-monitor-gizmo?view=all
Andreas Spiess
Andreas Spiess Рік тому
Unfortunately, I do not know Mathlab. So you have to find somebody for that. You should be able to use the same service definitions as shown here.
Yahya Khalid
Yahya Khalid Рік тому
I wanted to ask can i use BLE to transmit realtime data at 200 packets per second? I also have multiple sensors that use multiple serial ports to transmit data. The data on each of ports need to be synchronised i.e. It should transmit data from different serial ports at same time. How would i do that? Thanks a lot!
Andreas Spiess
Andreas Spiess Рік тому
I do not know.
GONELA MANU PRAKASH
GONELA MANU PRAKASH Рік тому
Sir Can we send the multiple sensors data to nRF connect using ESP32 as BLE sever.
GONELA MANU PRAKASH
GONELA MANU PRAKASH Рік тому
@Andreas Spiess thank you sir..😊😊.. If you know in future please let us know Thank you..👍👍
Andreas Spiess
Andreas Spiess Рік тому
I du not know
Nick P
Nick P Рік тому
Thank you so much for this great explanation and showcasing! This really helped me with my project :)
Nick P
Nick P Рік тому
@Andreas Spiess Well I would hurry up but unfortunately the university is closed down at the moment due to the virus.. I am using the time during quarantine to learn how to use BLE to communicate between the different sensors. I'm using the Bluefruit feather by Adafruit which is pretty great for newbies like me :)
Andreas Spiess
Andreas Spiess Рік тому
I assume you have to hurry-up ;-)
Nick P
Nick P Рік тому
@Andreas Spiess I'm currently building a prototype to show users feedback of their handwashing behavior for my master's thesis. I never thought that this could get as relevant as it got now ^^
Andreas Spiess
Andreas Spiess Рік тому
You're very welcome!
romimil1811
romimil1811 Рік тому
If i want that characteristics of BLE in My app that, i only need what instructions to activate? I'm a beginner 🙈
Andreas Spiess
Andreas Spiess Рік тому
BLE is not simple for beginners. You need to experiment and learn a lot :-(
Mauricio Lima
Mauricio Lima Рік тому
Why do your Bluetooth Standard XML files look like beautiful tables? I can only see them with no format at all (tree view) and it's very annoying. Any ideas?
Delta25M
Delta25M Рік тому
@Andreas Spiess ohh for sure! it's not yet finished, i need to get the hardware part working but when I upload it I'll link it!
Andreas Spiess
Andreas Spiess Рік тому
Maybe you share your project on Instructables? It would be fun!
Delta25M
Delta25M Рік тому
@Andreas Spiess Ohh no worries! Your video was VITAL for me to understand how BLE works. Thanks to this I made the program for my ESP32 bike power meter so thank you so much!! Greetings from Argentina
Andreas Spiess
Andreas Spiess Рік тому
I even did not find XML files in this video :-( So, no idea.
Johnson Tea
Johnson Tea Рік тому
Does anyone know what to do if I need better resolution than what is specified in GATT? For example height has resolution in 0.01 meters, but I want 0.001 meter
Andreas Spiess
Andreas Spiess Рік тому
I assume you have to create a custom profile
Aravind K
Aravind K Рік тому
Dear Andreas, I am working on an experiment to send BMP180 sensor data connected to ESP32 to a client application in phone. Are there any recommended service and characterstic uuids that can be used here, or should i use nordic semiconductor uart uuids. Am not clear what uuids would be suitable for this setup. Thanks
Aravind K
Aravind K Рік тому
@Andreas Spiess Thanks Andreas. Will check it out.
Andreas Spiess
Andreas Spiess Рік тому
You find a register of all standard services (including UUIDs) on the internet. Maybe you find one for pressure sensors
Aravind K
Aravind K Рік тому
Dear Andreas, Greetings. I am working on ESP32 module for one of my BLE projects. I used the BLE server sketch that was available in the example sketch of arduino IDE. I tried connecting the server to a android NRF phone client. It worked fine. BLE device name was available within the client. I was also able to read characteristics too, But the same experiment, if i tried executing in my house, the connection does not get established. I also changed the service and characteristics UUID using uuid generator tool. But still no connection. What might be the problem. Kindly suggest.
Aravind K
Aravind K Рік тому
@Andreas Spiess Thanks for your suggestions. Will look into it.
Andreas Spiess
Andreas Spiess Рік тому
I am no BLE specialist. But AFAIK we do not "connect" to a device, we only listen to advertisements. Gadgets stop advertising if they are connected to another device like your smartphone.
seba n
seba n Рік тому
Really, really THANK YOU for your work. Whole work. I learn so much from you.
Andreas Spiess
Andreas Spiess Рік тому
You are welcome!
Jürgen Walter
Jürgen Walter Рік тому
Tolle Videos!
Andreas Spiess
Andreas Spiess Рік тому
Danke!
Fernando Navarro
Fernando Navarro Рік тому
I have found this BLE Device Simulator project www.drjukka.com/blog/wordpress/?p=177 Perhaps could help
Andreas Spiess
Andreas Spiess Рік тому
Interesting project, if you want to work on Windows
Aran_Software_Dept Aran
Aran_Software_Dept Aran Рік тому
hi i dont see "NOTIFIY" message on the serial
Andreas Spiess
Andreas Spiess Рік тому
Unfortunately I cannot do remote debugging :-(
According To Ali
According To Ali Рік тому
Hi Andreas I created a BLE sniffer following your video. However I am facing a weird issue. The BLE sniffer works great for couple of hours then it stops detecting. I read manufacturers address of my iPhone from a microservice I created and store it in a variable array in setup. Then BLE scan and when match (partial) found I do a HTTP post to Home Assistant for greeting message. Problem is when it stops working I have no idea why. Could you please any idea from your experience. Thanks.
Andreas Spiess
Andreas Spiess Рік тому
Unfortunately I cannot do remote debugging. Maybe it has to do with the MAC randomization of the IPhone?
Shlomo Cohen
Shlomo Cohen Рік тому
Hi, I need to put a transmitter on the collar of my dog, so when he barks it would trigger a device in the house. I also need to keep track of the barks on an app on my phone that I will later make. What technology do you recommend? How? Thank you so much.
Andreas Spiess
Andreas Spiess Рік тому
I do not know (I only have a cat and no dog).
Night Wolf Drunker
Night Wolf Drunker Рік тому
i have more than 1 server, Sending GAAT heart-rate measurement, so how can i read them by single client.!!?
Andreas Spiess
Andreas Spiess Рік тому
I do not know enough about BLE :-(
Addidis no
Addidis no Рік тому
epic , ty sir
Andreas Spiess
Andreas Spiess Рік тому
You are welcome!
WagonLoads
WagonLoads Рік тому
I would like to know if the esp32 bluetooth has HID capabilities?
Andreas Spiess
Andreas Spiess Рік тому
Google? github.com/T-vK/ESP32-BLE-Keyboard
Anchorage Tech Solutions
Anchorage Tech Solutions Рік тому
Would like to see if you would update this series by communicating between an Arduino Nano BLE Sense or Adafruit Feather BLE with a RPI 3 or RPi 4? Here is a GitHub link to a gentleman who has also worked on RPi and Arduino communication using BLE github.com/Josh-Weston/ArduinoRPi
Andreas Spiess
Andreas Spiess Рік тому
This is a different way because it does not use the BLE features of the ESP. It uses an additional BLE device. A good thing, but not very much related to this topic.
Renato Trevizan
Renato Trevizan Рік тому
Your video is great! Thank you so much!
Andreas Spiess
Andreas Spiess Рік тому
You are welcome!
Afnan Bashir
Afnan Bashir 2 роки тому
Hi, Have you tried H10 POLAR with your program that you have written (for H7)? for me it does not work. Just says device is there lets connect and then stays there forever.
Andreas Spiess
Andreas Spiess 2 роки тому
No, I did not try.
M VC
M VC 2 роки тому
Mr. Spiess, how did you solved the invalid data syntax : ? in the value data (nRF Connect app)! , the marriage joke was amazing !
Andreas Spiess
Andreas Spiess 2 роки тому
The ESP32 BLE is under constant change. So it is well possible they changed something since the video was done.
M VC
M VC 2 роки тому
@Andreas Spiess yes sir, when you open the app mobile nRF Connect app, you connect your smart phone with BLE to the esp32, and then you can see that it shows information "in the description", in your video, you show numbers and there is not problem, but in my case it shows hex numbers and a message which says " invalid data syntax : 0x0E"
Andreas Spiess
Andreas Spiess 2 роки тому
I do not know what you mean. Can you pls. be a little more elaborate?
Mauricio Figueroa
Mauricio Figueroa 2 роки тому
You mentioned that you had to use espresiffs tools to get it to work, do you have videos covering that??
Andreas Spiess
Andreas Spiess 2 роки тому
No, I only use Arduino
Gonzalo Alonso
Gonzalo Alonso 2 роки тому
Nice work, my friend. Keep exploring, please!
Andreas Spiess
Andreas Spiess 2 роки тому
Thank you!
dilawer mehmood
dilawer mehmood 2 роки тому
Hi andreas spiess I want to make a project using this module(two modules) can you please tell me If we put the module in deep sleep mode and wake it up how long would it take for two esp32 to connect using BLE ?
Andreas Spiess
Andreas Spiess 2 роки тому
I made videos about deep-sleep. But be aware that the ESP does not listen to BLE if in deep sleep.
Heath Ward
Heath Ward 2 роки тому
Would you happen to know of a simpler tutorial that would just turn on a led when a known address is seen and then turns it back offf when the known device leaves? Thanks PS love watching your videos
Heath Ward
Heath Ward 2 роки тому
@Andreas Spiess well i will keep at it :) thank you for your reply. I do love your videos even though they are mostly over my head but i love to watch them and they always give me ideas that take me in fun directions.... thanks again
Andreas Spiess
Andreas Spiess 2 роки тому
BLE seems never to be simple :-( Therefore I do not know a simpler one.
Ankit Rana
Ankit Rana 2 роки тому
Hello Sir can you explain(with practical example) or provide a source to understand ALL about GATT more specifically GATT Declarations, Descriptors(how and where they are used) and in detail about UUID?
Andreas Spiess
Andreas Spiess 2 роки тому
I have a few videos about BLE. Or you search with Google.
The Kaveman
The Kaveman 2 роки тому
I think this is a topic worth continuing with and sharing because it is such a strong communication taking any data from esp32 to a mobile which then can do all sorts of things - communicate easily via - txt - sm- email - to -wifi and easy access to screen display and data storage on phone sd card. Phones are so cheap that is really becomes the interface to use.
The Kaveman
The Kaveman 2 роки тому
@Andreas Spiess I have found it difficult to get my head around the details of BLE programming.
Andreas Spiess
Andreas Spiess 2 роки тому
Maybe I will continue the topic. But only if Espressif did a good job on the library...
Marco Túlio - Analog Channel
Marco Túlio - Analog Channel 2 роки тому
Hello Andreas!! Thanks for sharing!!! could you show us any example using two spe32 (one like a server and another like a client)? Regards, Túlio
Marco Túlio - Analog Channel
Marco Túlio - Analog Channel 2 роки тому
@Andreas Spiess THANK YOU ANDREAS!!! I think you solved my problem!!!
Andreas Spiess
Andreas Spiess 2 роки тому
Maybe you watch the ESPnow video?
Vinicius
Vinicius 2 роки тому
Do you have any news about ESP32 and the BLE Remote Button?? That would be extremely useful, a very small, cheap and wireless button.
Andreas Spiess
Andreas Spiess 2 роки тому
I did not use BLE since then because I was disappointed and I wait till things are fixed.
Julián
Julián 2 роки тому
good tutorial bud! thanks. By the way, someone know an android code example for a ble client?
Andreas Spiess
Andreas Spiess 2 роки тому
:-)
Anton
Anton 2 роки тому
You can also go to chrome://bluetooth-internals/#devices in your chrome browser to debug BLE. I think it has the same feature-set as the app
Andreas Spiess
Andreas Spiess 2 роки тому
Interesting link. Thank you. I will try it next time I work with BLE
PH
PH 2 роки тому
Does BLE from esp32 suffer interference from something like pcb boards? Does BLE use any pin?
Andreas Spiess
Andreas Spiess 2 роки тому
BLE works wirelessly with the same antenna as Wi-Fi. It needs no pins
Adel Shokry
Adel Shokry 3 роки тому
What is the name of the BLE scanner app, Thanks
Adel Shokry
Adel Shokry 3 роки тому
I found it, It's nRF Connect, Thanks for the video.
may nards penales
may nards penales 3 роки тому
sir i have a thesis proposal with using this ble sir can you help me?
Andreas Spiess
Andreas Spiess 3 роки тому
I am a UKpostsr. I answer special questions when I see you tried it hard yourself.
Paulo A
Paulo A 3 роки тому
how to connect an esp32 with bluetooth another esp32 ?
Daniel Metzger
Daniel Metzger Рік тому
@Andreas Spiess oder kä luscht? I think, just configure an es32 as a client and the other one as a server?
Paulo A
Paulo A 3 роки тому
Andreas Spiess Sad :/
Andreas Spiess
Andreas Spiess 3 роки тому
I do not know
Didier Solheid
Didier Solheid 3 роки тому
Hi, Thanks for your great Job! I tried the sample with an ESP32 .. without success : C:\Users\dso\Documents\Arduino\libraries\ESP32_BLE_Arduino-master\src/BLEDevice.h:16:20: fatal error: esp_bt.h: No such file or directory I have a too old ESP32 Library ? Regards
Andreas Spiess
Andreas Spiess 3 роки тому
I would always download a new version. Things move quite fast in the ESP32 environment
Jose Luis Rodriguez de Torres
Jose Luis Rodriguez de Torres 3 роки тому
Hello Mr. Andreas, First, thank you for your videos. They are really usefull. Second, a question related both with Arduino and this bluetooth implementation (and my very limited knowledge). When I connect, I find this: "ESP32 Dev Module, QIO, 80MHz, 4mb (32Mb), 921600" By using the " BLE_server" code in the examples and after compilation/Upload, this is what I get: "Sketch uses 1085933 bytes (82%) of program storage space. Maximum is 1310720 bytes. Global variables use 69056 bytes (23%) of dynamic memory, leaving 225856 bytes for local variables. Maximum is 294912 bytes" I pretended to use ESP32 bluetooth functionality as part of the project but it seems that it leaves no much space for aditional code (18%). If it is so, it is not practical to me (and thers, I suppose), from a practical point of view. My question: I´m I wrong? Can program storage be expanded somehow? If yes, could you please explain, here in in any other video? If it cannot, I will have to find out other alternatives (I guess other people will also have to address this issue). For pure bluetooth functionality I was checking this product. It´s a different approach,, true, out of the Arduino world. www.lairdtech.com/products/bl600-series Thanks in advance,
Andreas Spiess
Andreas Spiess 3 роки тому
BLE is new on the ESP32 and the Arduino IDE and we all hope it will improve. You can do things with the few % left. What's left is probably still more than an Arduino has.
N N
N N 3 роки тому
Hi Mr Spiess, I am not able to change my service UUID and characteristic UUID to custom UUID created from UUID generator. Am able to change my other parameters like set value and blue tooth name . Would you be able to tell me why this happening ?
Andreas Spiess
Andreas Spiess 3 роки тому
I do not know. Did you watch all my BLE videos?
Michele Brunelli
Michele Brunelli 3 роки тому
Have you tried the Flower Care? I'm able to read sensor data but sometimes an error occour. Can you help me?
Andreas Spiess
Andreas Spiess 3 роки тому
No, not since then
Maneco Urquhart
Maneco Urquhart 3 роки тому
great video Andreas!!!
Andreas Spiess
Andreas Spiess 3 роки тому
Thank you!
maheshs11
maheshs11 3 роки тому
Bluetooth jammer with this?
maheshs11
maheshs11 3 роки тому
both work at 2.4ghz and are radio wave
Andreas Spiess
Andreas Spiess 3 роки тому
No
arunbm123
arunbm123 3 роки тому
Very Wonderfull vedio Sir
arunbm123
arunbm123 3 роки тому
ok....which is best chip according to you?
Andreas Spiess
Andreas Spiess 3 роки тому
No. It uses too much power
arunbm123
arunbm123 3 роки тому
can I use ESP32 to develop my own beacons for asset tracking, your Views Please
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks!
weerobot
weerobot 3 роки тому
I cant get Wifi to work ?? I use standard #include ?? DOit board...
Andreas Spiess
Andreas Spiess 3 роки тому
:-)
weerobot
weerobot 3 роки тому
Got it working thanks...must have had the wrong libraries....Arduino IDE was saying too many versions of ...but ok now.
Andreas Spiess
Andreas Spiess 3 роки тому
Should work. Try an example file first.
MrLQKD
MrLQKD 3 роки тому
Andreas, take a look at the Simblee BLE module: www.simblee.com, and the RfDuino: www.rfduino.com
MrLQKD
MrLQKD 3 роки тому
Andreas Spiess Yes, indeed, they are not cheap, unfortunately. All the best!
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for the links. These are good products, however not cheap. I hope, we will come to a similar performance with ESP32 libraries on BLE.
Jorge Teixeira
Jorge Teixeira 3 роки тому
waiting for xiaomi band 2 :D.. continue the nice work i learn so much from you
Andreas Spiess
Andreas Spiess 3 роки тому
Thank you
Bat Steg
Bat Steg 3 роки тому
Any news on BLE Mesh support in ESP32?
Andreas Spiess
Andreas Spiess 3 роки тому
No. Where would this fit? BLE seems to have a limited reach
Bat Steg
Bat Steg 3 роки тому
Here's a link to the NRF Connect Android app mentioned in the video - play.google.com/store/apps/details?id=no.nordicsemi.android.mcp&hl=en
Rana Ankit
Rana Ankit 3 роки тому
PLEASE RESEARCH MORE SIR
Andreas Spiess
Andreas Spiess 3 роки тому
Why?
stupossibleify
stupossibleify 3 роки тому
Andreas, your videos are superb!
Andreas Spiess
Andreas Spiess 3 роки тому
Thank you!
Fernando Marengo Rodriguez, Dr. Eng.
Fernando Marengo Rodriguez, Dr. Eng. 3 роки тому
Great tutorial!! Is there any video about the HM-10 or any other bluetooth 4.0 module? Thanks!!
Andreas Spiess
Andreas Spiess 3 роки тому
Not yet
Timothy Woo
Timothy Woo 3 роки тому
Great video! However, I couldn't get the BLE examples to compile in Arduino IDE. I updated the ESP32 library by using Git GUI and get.exe but it didn't include the library so then I went to Neil Kolban's Github page and downloaded the library and put it in my libraries folder, but the example wasn't listed under "ESP32 Examples" and it didn't compile. It gave a few errors, but this was the first one: "ESP32_BLE_Arduino\src/FreeRTOS.h:46:3: error: 'pthread_mutex_t' does not name a type". Any ideas? Thanks!
Andreas Spiess
Andreas Spiess 3 роки тому
I do not know. But I am glad it worked now!
Timothy Woo
Timothy Woo 3 роки тому
I deleted the ESP32 files and reinstalled and it worked, thanks! I guess the update from Git GUI didn't work?
Timothy Woo
Timothy Woo 3 роки тому
Hmmm the strange part is that I updated the library and it's not there. The ESP32 library for Arduino also doesn't show the libraries in Neil's repo and it only has "SimpleBLE": github.com/espressif/arduino-esp32/tree/master/libraries
Andreas Spiess
Andreas Spiess 3 роки тому
If you just install the ESP32 support bluetooth is already there. No library necessary. Maybe you delete the library. Then it should work. Or you reinstall the ESP32 support.
Hyss
Hyss 3 роки тому
That heart monitor can be fooled by putting some water between it and your skin. No need for excess effort.
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for the tip. Unfortunately too late:-(
Jens Jensen
Jens Jensen 3 роки тому
Another great smartphone util for ble is LightBlue. Bluetooth like usb is incredibly over engineered, and thus have a steep learning curve, but that’s also probably why both of these protocols have persisted for many years!
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for the lightblue tip. Seems also to be a good product!
LeBogo
LeBogo 3 роки тому
Hi, weißt du wie man sich die URL im WiFi server sketch ausgeben lassen kann ? ich habe es mit "Serial.pirntln(currentLine.endsWith());" versucht, aber ohne erfolg. Ich hoffe du kannst mir helfen :)
Andreas Spiess
Andreas Spiess 3 роки тому
Nein, weiss ich leider nicht.
One Penny
One Penny 3 роки тому
Perhaps the watch check the mac address in Polar H7 Heart Rate monitor If you see my example, you can change the bluetooth mac in esp32 and testing again. If you have all services , chars and mac adress I think there is nothing more the watch can check in a fake Polar Monitor.
Andreas Spiess
Andreas Spiess 3 роки тому
It had a much simpler reason (shame on me): The watch did not use BLE, but the Polar proprietary protocol. But you will see an update soon
One Penny
One Penny 3 роки тому
Dear Andreas, you can see my iTag emulator > www.instructables.com/id/ITag-With-an-ESP32-a-Bluetooth-Low-Energy-Button-A/ Hope you can enjoy it, thanks for your videos.
Andreas Spiess
Andreas Spiess 3 роки тому
Thank you for your link. I will try it out.
One Penny
One Penny 3 роки тому
I have done a iTag client or receiver, useful for using the cheap bluetooth buttons in our projects:-)) It is only a PoC but it works ! Thank you for sharing your work. github.com/aknik/ESP32/tree/master/iTag32
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for the link. I was also looking at the one you mention, and for sure will use it for my future work.
Marc Paradis
Marc Paradis 3 роки тому
Andreas, what version of Arduino IDE you have ? Thank you. Marc.
Andreas Spiess
Andreas Spiess 3 роки тому
1.8.5
Andre Muensti
Andre Muensti 3 роки тому
Hello Andreas , as always very good! Is there a possibility (example) for an SPP profile - to send text? RFCOMM protocol
Andreas Spiess
Andreas Spiess 3 роки тому
You will see a video about UART BLE soon
Hans Schenker
Hans Schenker 3 роки тому
Please keep on with BLE! It will have a bright future!
Andreas Spiess
Andreas Spiess 3 роки тому
You can bet on this one. I am very interested and worked nearly the whole week on it...
Bala Kumar G
Bala Kumar G 3 роки тому
Hai...please tell how to make audio frequency oscillator using arduino........
Bala Kumar G
Bala Kumar G 3 роки тому
thank you very much....
Andreas Spiess
Andreas Spiess 3 роки тому
www.arduino.cc/reference/en/language/functions/advanced-io/tone/
Ten Minute Tokyo 2
Ten Minute Tokyo 2 3 роки тому
linux.die.net/man/3/uuid
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for the link. Maybe useful if I leave the predefined UUIDs.
Hasan S
Hasan S 3 роки тому
Have you tried to work on ble with RPI in python? I have a ble rgb bulb, company got out of iot business so no support. I was successful in controlling the basic functions using a python script with RPI3, couldn't figure out the music sync part.. it is a much better interface and with RPI zw it could be in the same cost territory as esp32..
Andreas Spiess
Andreas Spiess 3 роки тому
Python definitively is on the screen here.
Hasan S
Hasan S 3 роки тому
Andreas Spiess yeah that is the end game.. Also micro python in esp32 should support ble soon it's like halfway there.. I am planning to teach a small micropython course and would love to hear your thoughts on the topic.. you have the best analysis for the ESP chips and micropython is probably the best interface (imho) for students so please try to make a video about it..
Hasan S
Hasan S 3 роки тому
Andreas Spiess yeah that is the end game.. Also micro python in esp32 should support ble soon it's like halfway there.. I am planning to teach a small micropython course and would love to hear your thoughts on the topic.. you have the best analysis for the ESP chips and micropython is probably the best interface (imho) for students so please try to make a video about it..
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks! Maybe I have to investigate the possibilities of the RPI. But at the end, of course, we want to use the ESP32...
Christian Fuchs
Christian Fuchs 3 роки тому
Im wondering you dont discover ble with wireshark... github.com/greatscottgadgets/ubertooth/wiki/Capturing-BLE-in-Wireshark
Andreas Spiess
Andreas Spiess 3 роки тому
I used Wireshark for Wi-Fi. But it seems to be different for BLE.
Christian Fuchs
Christian Fuchs 3 роки тому
Andreas Spiess last time i id that my mac was ‚man in the middle‘, so i didnt need add. devices. But i sniffed on wifi, no bt or ble. I guess if one of your ble device can become man in the middle it will work. In other words: wireshark is a amazing tool, maybe u can use that for your purposes.
Andreas Spiess
Andreas Spiess 3 роки тому
AFAIK you need a special device to capture the traffic and I do not have such a device. I ordered now a BLE sniffer from Adafruit and will see where this goes...
Nick Burton
Nick Burton 3 роки тому
Managed to get the UART example working for tx rx. by using the BLE Scanner app on an iPhone. Also got it to pair with a raspberry pi3, didn’t get any farther though. Think there’s a good Python Bluetooth library so might give that a try on the pi3 Always found bluetooth a bit complicated but with the esp-32 it could be very useful for battery powered projects. So probably worth spending a bit more time with it. Thanks again for another great video.
Andreas Spiess
Andreas Spiess 3 роки тому
Maybe I also will go the RPI route. We will see...
ytfp Chris
ytfp Chris 3 роки тому
Good reminder of why I don't muck around with BLE, just not there yet. The only thing that is dissapointing is by the time something is figured out, something new is out.
Andreas Spiess
Andreas Spiess 3 роки тому
Each technology has its "bleeding edge" where only a few join. Hopefully, BLE on the ESP32 will be mainstream soon...
mispeaced
mispeaced 3 роки тому
Polar uses 4 protocols - GymLink (non-coded), GymLink, Wind, Bluetooth. Your FT60 watch is only compatible with GymLink heart rate devices (T31,H1,H2,H7,H10), it doesn't work over BLE. And H7 sensor provides both GymLink+Bluetooth compatibility. So, H7 works over GymLink with your FT60 watch and over Bluetooth with smartphones/esp32/. This info can be found here: support.polar.com/en/support/compatibility_with_my_Polar How do I know that? I also owe H7 + FT4 watch (GymLink only) :) And thanks for another great video!
Andreas Spiess
Andreas Spiess 3 роки тому
You are absolutely right! Thank you for your hint. Saves me time! Now I remember that I had to buy the H7 in addition to the normal sensor a few years ago because I wanted to use it with the iPhone. I am getting old...
Bike Vids
Bike Vids 3 роки тому
Dood what’s a good cheap Android tab that can run the current Android?
Bike Vids
Bike Vids 3 роки тому
Andreas Spiess Mee too, just need to look into dev.
Andreas Spiess
Andreas Spiess 3 роки тому
I am still on IOS ;-)
Sorin N
Sorin N 3 роки тому
Hello Andreas, Congrats for one of the best introductory videos I could find on BLE! There are ble devices allowing discovery and pairing even if they are already paired. Kind of promiscuous, but that's life! :))
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for your info. I did not know that. As I mentioned, I am still scratching at the surface...
0gizmo
0gizmo 3 роки тому
You can generate the UUIDs with this command: BLEUUID((uint16_t)0x2AB3) So you don't need the long numbers.. Source: www.hackster.io/ManniAT/esp32-ble-environmental-gatt-server-14cceb Regarding BLE I can recommend this Book: shop.oreilly.com/product/0636920033011.do
Andreas Spiess
Andreas Spiess 3 роки тому
Thank you for the hint. I used it and it works fine!
Tomasz Durlej
Tomasz Durlej 3 роки тому
Strange, hr sensor should work without sweat.
Andreas Spiess
Andreas Spiess 3 роки тому
My experience is different (at least for the chest bands). The new one builtin in the watches works only with light.
Giampiero Raschetti
Giampiero Raschetti 3 роки тому
It should be interesting some experiment with iBeacon advertising on BLE. There are some examples out there but I did not found anything compiled under the arduino ide.
Andreas Spiess
Andreas Spiess 3 роки тому
I hope, we will come to this topic later on. For the moment, I try to go step-by-step...
Dean Greenhough
Dean Greenhough 3 роки тому
Congratulations on 50k subscribers. Very well deserved and the quality just keeps getting better. You sir are always my number 1 to go to for information first! Eternally grateful and appreciative of your outstanding work. Merry Xmas to all the intelligent people that follow your work and of course to our very own Electronics Father Xmas whom delivers a present every Sunday on the dot 🙏
Andreas Spiess
Andreas Spiess 3 роки тому
Thank you for your continued support. But for this Christmas (because it is a Sunday), I do not plan a video. This is my one week UKposts holiday this year. And I hope, that most people anyway would not have the time to watch my video...
Xano Trevisan Kothe
Xano Trevisan Kothe 3 роки тому
This library is pretty good! Thank's for sharing. BTW: Too much secret sauce in the UUIDs. It reminds me of SNMP OIDs (I hate SNMP).
Andreas Spiess
Andreas Spiess 3 роки тому
:-)
Jorge Macias
Jorge Macias 3 роки тому
To make it work the polar clone you need to hack the company manufacturing data from the advertising package and by this way clone it into the esp32. Is the same if you want to accept your peripherals with the apple ble. I happen to know the company manufacturing data for apple is 4c 00 but for polar you must reverse engineer the polar.
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for your hint. I will stick to this BLE stuff, and eventually will be able to read it...
chegewaras
chegewaras 3 роки тому
I wanted to say something about this vid but i wont because im not maintainer ESP32 BLE library, just someone who can help you with issues. But i want to say about polar, yes you can fake polar H7 device or at least you can use esp32 with this library as heart rate monitor device. If you are interested how to do that, you are welcome to open issue here ->> github.com/nkolban/esp32-snippets/issues
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for the hint about opening issues. I will follow this path.
lamarched21
lamarched21 3 роки тому
Very interesting video. Let us know if you find the answers to your questions.
Andreas Spiess
Andreas Spiess 3 роки тому
I do not think, that this is the last video about BLE...
Richard Mullens
Richard Mullens 3 роки тому
I bought a SHT31 Smart Gadget Development Kit (humidity sensor). Bluetooth is ubiquitous so thanks for prompting me to get it working.
Andreas Spiess
Andreas Spiess 3 роки тому
:-)
Manick N
Manick N 3 роки тому
This is interesting but I have a lot of groundwork before I can understand properly. This is definitely on my watch over list.
Andreas Spiess
Andreas Spiess 3 роки тому
So we are two with lots of learning in front of us ;-)
madrian
madrian 3 роки тому
For reading miflora you can check this: github.com/open-homeautomation/miflora I bought for 0,10$ these BLE tags on Gearbest, I have at least 30 pieces. :D
madrian
madrian 3 роки тому
Haven't tried yet + only the Miflora with rPi3.
Andreas Spiess
Andreas Spiess 3 роки тому
Thanks for the link. Were you able to read the tags with the ESP32?
Steve Groen
Steve Groen 3 роки тому
Many hobbyists would like to remotely control a flex strip of "smart" RGB LEDs with a smart phone and the ESP32 as the controller. The LED strip would be powered by a 5V, 2A supply and not require BLE. Could this be accomplished by basic Bluetooth? Does the Arduino IDE currently support this project? If you could "UKposts" this project I think you would have a hit because so many hobbyists love to play with LEDs.
Andreas Spiess
Andreas Spiess 3 роки тому
You can use BLE for such a device. But most people use Wi-Fi because they use Wi-Fi for their other Home-Automation devices. Maybe I will cover something like that in the future, but now my priority is to understand the protocol itself...
ReanimationXP
ReanimationXP 3 роки тому
He's given you the pieces necessary to implement this, and there are plenty of examples elsewhere.
Anas Omary
Anas Omary 3 роки тому
I came, I liked, I watched. Thnx Andreas
Andreas Spiess
Andreas Spiess 3 роки тому
:-)
opless
opless 3 роки тому
I was hoping you'd take apart the keyfinder widget :-) I'm guessing it's an nRF51 part. Great Video as always Andreas!
Andreas Spiess
Andreas Spiess 3 роки тому
Unfortunately, it is my only one. This channel is not known to take things apart, more to build things. But looking at the numbers of such channels, maybe I will change my opinion ;-)
Introduction to ESP32 - Getting Started
47:57
DroneBot Workshop
Переглядів 615 тис.
Why Formula 1's New CURVED Wing is GENIUS
6:57
Driver61
Переглядів 469 тис.
#370 Raspberry Pi Pico vs ESP32 (-S2) and STM32 Blackpill
15:53
Andreas Spiess
Переглядів 227 тис.
BitBastelei #340 - Bluetooth-Android-Apps für ESP32
31:51
BitBastelei
Переглядів 24 тис.
Create your own App to control an ESP32 (Arduino) with Bluetooth
18:18
mo_thunderz
Переглядів 3,7 тис.
Can I Power This Go Kart with a Used Car Alternator?
26:32
Aging Wheels
Переглядів 153 тис.
#371 RISC-V: How much is open source? Featuring the new ESP32-C3
25:25
Andreas Spiess
Переглядів 123 тис.
ФОГЕЛЬ - БОГАТЫМИ (Lyric Video)
2:46
ФОГЕЛЬ
Переглядів 851 тис.
Кто БЫДЛО? Путин УНИЧТОЖИЛ главу "Эхо Москвы" Венедиктова!
8:12
Политика сегодня: Россия США Украина
Переглядів 2 млн
Зоря - Олександрія. Студія і ПОВНИЙ МАТЧ
2:34:45