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.

what is the connection parameter use for keyboard is the best?

Other Parts Discussed in Thread: CC2541

Hello TI engineer!

I use cc2541 for keyboard.  And I can't find the good connection parameter for all the os (Android, IOS, MAC OSX, windows10);

the defalut HIDEmuKbd, the connection parameter is  below; I call this parameter is 8-8-50-500 for easy say;

// Minimum connection interval (units of 1.25ms) if automatic parameter update request is enabled
#define DEFAULT_DESIRED_MIN_CONN_INTERVAL 8

// Maximum connection interval (units of 1.25ms) if automatic parameter update request is enabled

#define DEFAULT_DESIRED_MAX_CONN_INTERVAL 8

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

// Supervision timeout value (units of 10ms) if automatic parameter update request is enabled
#define DEFAULT_DESIRED_CONN_TIMEOUT 500

But when the keyboard link my android phone, the key input is good, but my APP send data (this data is defined by my self) to keyboard by bluetooth, the keyboard get the data very slow (about delay 1second);  

And this parameter setting when I link Mac osx, the link will be disconnect after few miniute (not the IDLE_TIMEOUT happen);

When I use 10-15-4-500 for  connection parameter, I find that link windows 10, the current is very BIG about 8MA (is 200uA in Android);

When I disable the parameter update used below way; I find that delayed about 200ms linked MAC OSX when input words, And I fell very Uncomfortable when i input words, so this parameter can't use for keyboard.  And I try some connection parameter to test, but can't find the useful connection connection parameter!

#define DEFAULT_ENABLE_UPDATE_REQUEST         FALSE

(hid.c) 

if ( updateConnParams )
{
// GAPRole_SetParameter( GAPROLE_PARAM_UPDATE_REQ, sizeof( uint8 ), &updateConnParams );
// updateConnParams = FALSE;
}

SO what is the best  connection parameter for all os (Android, IOS, MAC OSX, Windows10)???

 

Thanks! 

  • Hello,

    For iOS/OSX, you need to refer to the Apple BT Accessory Guide. HID devices are permitted to request a faster conn interval, up to 11.25ms. For a keyboard, usually 11.25ms - 15ms is ideal with max Slave Latency.

    You should probably take a BLE air sniffer trace to confirm that the interval is what you expect and Slave Latency is enabled. Sometimes you'll have to fiddle with the settings to get a good match as Android and possibly Windows have different BLE controllers that are not always consistent.

    Best wishes
  • Thanks for reply!
    1: TI the keyboard demo HIDEmuKbd. set connection interval 8 * 1.25 = 10ms. big than 11.25ms. why?
    2: sorry, I can't find OSX the BT Accessory Guide. And also Windows spec. Can you help me?

    Thanks!
  • Hi,

    You can find the Apple guide by doing a web search (e.g., google) for "Apple Bluetooth accessory design guide".

    The default conn intervals in the Preferred Connection Parameters & Conn Update Request are configurable - you can select the values that work for the intended Central system(s). Obviously, using a faster conn interval reduces delay, but anything in the 10-15ms should be ok for normal keyboard operation. In the end, you'll need to experiment / test with your HW / SW setup to make sure it works as per expectation.

    Best wishes

  • HI JXS,

    Thanks! But I from China and can't use google, HHHaa, This I will use my way to search.....

    I find another BUG about Connection Parameters; I use windows7 and CSR Harmony Wireless Software Stack. Use TI HIDEmuKbd(1.4.1b) demo to connect windows7, and they connect correct, the currest is also OK(about 30uA)! But when I reset my keyboard(HIDEmuKbd), the current is 2MA, find that the first connect UPDATE_REQUEST event is done; but when I reset keyboard the UPDATE_REQUEST event is timeout, SO the current is 2MA; This Bug is alos appear on my another andoid phone(nubia android 5.0), And have not found on other machines; Are you meet this BUG, And what's the reason?
  • I get the same results when I "Baidu'd it" ;)
    www.baidu.com/s

    What does "update request timeout" mean? Did the Master not respond? A BLE air sniffer trace would be helpful for understanding what is happening.

    Best wishes