This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Failing to connect in crowded spaces with other BLE devices advertising

Other Parts Discussed in Thread: CC2590, CC2592

Hello--

We've got a CC2541-based product here that's now in early production.  It's working great when there's one sensor in a room communicating with an iPad or iPhone, but as soon as we're in a room with lots of other BLE devices, like FitBits, our product has a really hard time forming a connection to smartphone/tablet device.  

Has anyone out there also had this problem?   It's becoming a real issue since many of the demos we give are in a room filled with 100+ more people and just scanning with BT Tool we see at least ten other BLE devices our there.

We're using the BLE stack 1.3.2.  Here are also our connection parameters that I think meet Apple's requirements OK.  Is there anything we can do to make our product more robust, especially in a demo environment?

Thanks!!!
Brian


// Whether to enable automatic parameter update request when a connection is formed
#define DEFAULT_ENABLE_UPDATE_REQUEST         TRUE

#define DEFAULT_DISCOVERABLE_MODE             GAP_ADTYPE_FLAGS_GENERAL

// Slow advertising interval in 625us units
#define DEFAULT_SLOW_ADV_INTERVAL             2056


// Minimum connection interval (units of 1.25ms, 80=100ms) if automatic parameter update request is enabled
#define DEFAULT_DESIRED_MIN_CONN_INTERVAL     24 //30 ms 

// Maximum connection interval (units of 1.25ms, 800=1000ms) if automatic parameter update request is enabled
#define DEFAULT_DESIRED_MAX_CONN_INTERVAL     40 //50 ms

// Slave latency to use if automatic parameter update request is enabled
#define DEFAULT_DESIRED_SLAVE_LATENCY         4

// Supervision timeout value (units of 10ms, 1000=10s) if automatic parameter update request is enabled
#define DEFAULT_DESIRED_CONN_TIMEOUT          600


  • >> our product has a really hard time forming a connection to smartphone/tablet device
    Just to clarify, it is the smartphone/tablet which creates the connection; your product periodically sends out advertisements "hey, look at me, I'm connectable". Connectability is maximized by maximizing advertisements.

    Try setting advertising interval to from 2056 to something like 160; thereby advertising every 100 msecs instead of every 1.3 seconds.

    Also, make sure you set the GAP parameter GAPROLE_ADVERT_OFF_TIME to something small (e.g.100), but greater than 0.

    You could also try putting your device in limited discovery mode rather than general discovery mode.  That may or may not have an effect, depends on smartphone firmware.

    Also, suggest you use the sniffer to determine whether the problem is creating the connection or maintaining the connection; different sets of parameters apply.

    In short, your device should be easily connectable and should have no trouble maintaining connections, even in the presence of dozens of other BLE devices :)

    .

  • Hi Richard,


    Thanks!   Yup.  Totally understand that we're advertising here.   We have an always-on device and to save power, we we are only sending ever 1.3sec or something like that, over and over.   It works great when that's the only device in the room.  But goodness, it really has difficulties connecting when in a room with several other devices.


    We made one change here as an experiment.  We increased the the frequency of the advertisements as you pointed out to 100ms.  Yes, it connects faster again, when in an isolated environment, but we still see poor connection results in a crowded space.  It's really hit or miss.


    I tried using the TI RF Sniffer program to see if we could capture a trace, but was overwhelmed with data and have yet to figure out how to filter on the mac address of our specific device.  Note that again, in an isolated environment, I do see the advertisements broadcasting at 100ms intervals.  Any pointers there?

    With regards to the GAPROLE_ADVERT_OFF_TIME  parameter.  Doesn't this only affect Limited advertising implementations?

    Thank you again kindly for your response and thoughts.

    Cheers,
    Brian

  • Ah... I was just able to capture a failure condition here when there were other devices in the same room.


    See attached screenshots from the sniffer.  Also, the PSD file is attached. 

    A connect seems to form, but then we just get lots of Empty PDU packets and then eventually the connection disconnects.

    Thanks!

    Brian

    2860.fail01292013.psd

  • Here's also a working trace in comparison.

    6036.working0129.psd

  • Hi Brian,

    Your sniff capture shows that the connection is made, but during the connection there seem to be many retries and not much data.

    I tried a rough throughput test here with 2540 Peripheral device and a laptop with Bluegiga dongle as the Central device. I tried several test scenarios:
    1. Central and Peripheral 5 feet apart with no other devices advertising
    2. Central and Peripheral 5 feet apart with 60 other devices advertising, the 60 other devices were 20 feet away from Central
    3. Central and Peripheral 25 feet apart with no other devices advertising
    4. Central and Peripheral 25 feet apart with 60 other devices advertising, the 60 other devices were right next to Central

    As expected, the throughput was better at close range, but the presence of the 60 other BLE peripheral devices had no apparent effect on throughput.

    Richard

  • Hi Richard,


    You're awesome.  Thank you for running that test, and my apologies for the long delay getting back.  

    We also ran a similar test and things worked fine.  I think we figured out where we see a failure: it's in a room filled with laptops, like at a conference, with lots of WiFi activity.  Our device failed to connect over and over, like 8 or 9 times out of 10 tries.   But as soon as we stepped outside for a walk about 100ft away from the room, our device connected just fine.  It seems like the WiFi in the room was overwhelming our device. 


    Could that be?  How might we be able to confirm this.  I'm wondering what we might be able to do be more robust?  Is it just a matter of signal strength in such a situation?


    Thanks for any thoughts...


    Best,
    Brian

  • I don't know that anything can be done in software about Wifi interference.  My impression is that Bluetooth interferes with Wifi more than the other way around.

    Antenna design must play a role, but that's way outside my expertise.

  • one of the videos in this page http://focus.ti.com/docs/training/catalog/events/event.jhtml?sku=OLT313004

    shows a picture of the 40 channels, 3 adv channel and 37 data channel, the 3 adv channles are selected to be with less interference from wifi, but the 37 data channel might have severe interference from wifi.

    in the case posted with many strong wifi signals of laptos, severe interference might  block all the data channels, so that connection events, which are carried in the data channels, will be suppressed by wifi signals, and connection not easy to setup and easy to lost. 

    http://wireless.kernel.org/en/users/Documentation/Bluetooth-coexistence

  • Hey guys,

    Thanks for all the responses on this.  Wow.  I think we might just be up against a wall here in terms of interference.   Here's a quick screenshot we took using MetaGeek's Channelyzer.   With this Wifi background our sensor is still working fine.  I'll post a screenshot of when it's not working shortly, but I'll bet it's a lot more crowded.

    Are there any things we could do in terms of the connection parameters that might make the connection more robust in a crowded space?  Also, would adding a CC2590 front end help, by essentially making our signal stronger the WiFi around us?   Other ideas?    We're going to be up on stage in front of a very large audience shortly, full of people on laptops… and trying to figure out how to make the demo rock the house.

    Thanks all,

    Brian

  • Hi Brian,

    Brian Krejcarek said:
     Also, would adding a CC2590 front end help, by essentially making our signal stronger the WiFi around us?

    Yes, but have a look at CC2592 instead, http://www.ti.com/product/cc2592

    Best Regards.

    Joakim 

  • Cheers.  Thanks Joakim.


    What are the key differences between the CC2590 and CC2592?  Doesn't seem DigiKey or Mouser are even stocking the CC2592 yet.

    Hopefully we can crank the power up on this to push aside WiFi... not in production, just a one time demo.

    Thanks!

    Brian

  • Hi Brian,

    CC2592 got RTM'ed a couple of days ago, so it's our latest range extender solution. The specifics you'll find in the respective datasheet although CC2592 is generally the newer and better option in terms of performace.

    Best Regards

    Joakim