Notifications
Clear all

esp32 to esp32 Bluetooth connection problem

5 Posts
3 Users
1 Likes
531 Views
(@osamaghamry)
Member
Joined: 10 months ago
Posts: 3
Topic starter  

hello everyone
i purchased pre tested code from game company
it has connection between the controller and the game with bluetooth esp32 to esp32
after installing every thing good it worked good but i keep loosing the bluetooth connection randomly
and sometimes when the controller starts to move away from the game less than 1 m distance
i tested everything and don't know where's the problem
that's the esp that i use

that video show the problem
from time 1:11

is that even normal or there's problem in the esp ( bad replica )
or there's somthing i need to check
although the code is sold many times from that company and supposed to work better

is it would work better if i treied to let them connect by esp-now better than bluetooth ?

best regards


   
Quote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 3 years ago
Posts: 6988
 

@osamaghamry Bluetooth can be very flaky or not. I have 11 showing on my iPhone at the moment. Some work very reliably, but a few are very flaky. The problem with the esp32  is the power is very low and the antenna very small.

If you have an esp-now option, give it a try, it might be more reliable.

Good luck.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
Sure you can learn to be a programmer, it will take the same amount of time for me to learn to be a Doctor.


   
ReplyQuote
(@davee)
Member
Joined: 3 years ago
Posts: 1691
 

Hi @osamaghamry,

  Sorry, I haven't tested on ESP32, but Bluetooth can generally be very picky about which devices will play nicely together, often due to protocol incompatibities, rather than signal strength. Of course, as you seem to have two devices with commercial software designed to work together, it is reasonable to expect them to play nicely, but expectations and reality sometimes diverge. 😥 

However, as Ron says, the antenna on ESP32 is limited in size, so maybe start by checking signal strength from the board.

I haven't done it before, but just added the "Bluetooth Signal Meter" app to my Android phone and it reported the two nearby Bluetooth devices with signal strength numbers. (I have no connection or knowledge of the App, beyond this 1 minute test ... so as with all apps, you install at your own risk.) (Click 'Scan' at least twice to double check it finds all in range if you don't see what you expect.)

If you have an IPhone, then my Googling suggested it could report the values directly.

--------

Note signal strengths are reported in dBm ... e.g. -50 dBm ... If it is a negative number (which it almost certainly will be at a receiver), then closer to 0 means higher signal strength.

eg if Device A was -50 dBm and device B was -80dBm, then A would be the stronger signal.

( It follows +6dBm would be more than 0dBm, but values this high will refer to transmitter signal levels)

Not a fix, but maybe an indication as to where to look, and if you do a change you can see if the number improves.

Good luck. Sorry it is only an untried hint. Dave

 


   
ReplyQuote
(@osamaghamry)
Member
Joined: 10 months ago
Posts: 3
Topic starter  

@zander thanks so much i'm already trying esp now and too much more reliable

 


   
ReplyQuote
(@osamaghamry)
Member
Joined: 10 months ago
Posts: 3
Topic starter  

@davee thanks for your hint and all that info i apprciate it and i will try it anyway
thanks again


   
DaveE reacted
ReplyQuote