• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

Multiple BLE Client Connections

Q&A Forum › Category: ESP32 › Multiple BLE Client Connections
0 Vote Up Vote Down
dragon541 asked 6 years ago

I have a couple questions about BLE.
First, is it possible to setup the ability to have multiple BLE client connections to the same server? For example, for the BLE client/server project. Can (or how do) I set it up to respond to two clients instead of one?
Second, what is the distance that can be achieved with BLE between client and server?
Third, how do you setup communications between an ESP32 client and an Raspberry Pi 3 or do BLE using a RPI? This might be off topic but I’m think about a bigger project I have of using my RPI, which already produces a display for my calendar and the weather for the next week, along with some news headlines, but having it recieve info about the actual current temperature outside would be really nice. The closest current “local” weather condition reading is from a station three cities and several miles away from me. Not really local.

3 Answers
0 Vote Up Vote Down
Rui Santos Staff answered 6 years ago

Hello!

  1. Unfortunately when a BLE client establishes a connection with a BLE server, the BLE client stops the advertising… With the current BLE implementation it’s a 1 to 1 communication. They are working on implementing more BLE features including BLE Mesh: https://github.com/espressif/esp-idf/issues/819
  2. BLE and Bluetooth classic are meant for short range communication. I’ve found it very reliable for 5 to 10 meteres distance. After that, you’ll get it disconnected and inaccurate results. I always recommend testing, because it depends in your area/workspace (walls, wireless noise, etc)
  3. Why do you plan to use BLE for that? For the low power consumption?
0 Vote Up Vote Down
dragon541 answered 6 years ago

I really didn’t know how else to do it. It seems kind of a waste to use LoRa for a 2-3 meter distance. With ESP32 I could put into deep sleep for 5 minutes, wake up, get readings and send them to the client (then to the RPI to update the display), then put it back to sleep.  With the low power consumption I could use the solar panels to charge the battery, and even with a couple weeks of rain and overcast skies (I live pretty far north of the equator so it’s cloudy and overcast several weeks at a time), I think it will work well. But I have that gap to jump between the sensors (server) and the receiver (client -> RPI -> display). Even with the LoRa, I’d still have to figure out how to get the data into the RPI. I’m open to suggestions.

0 Vote Up Vote Down
Rui Santos Staff answered 6 years ago

If your ESP32 is mostly in deep sleep, you could use MQTT with Wi-Fi. I think it’s a very reliable method to publish data to your Pi. Wi-Fi will use more battery, but if it’s only a couple of requests per hour and you use a solar panel to charge the batteries, it should still last for months or years.

Note: for lower power applications, you should always use a bare ESP32 chip with a custom PCB. The LoRa project that I show in the course lasts indefinitely, because it’s more than enough to re-charge the battery. But if I used Wi-Fi and made requests every 10 minutes, it would have a similar performance.

To ensure your battery never runs out of energy, you can use a battery with more capacity and a solar panel that provides more current to re-charge the battery faster.

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025
  • [eBook Updated] Learn ESP32 with Arduino IDE eBook – Version 3.2 April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.