paring with android phone

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

As I understand, when android request 'pairing', connup_callback and conndown_callback are called sequentially.

next, when android request 'connection', connup_callback is called.

is that right?

if so, can i know whether this event is paring or connection  in connup_callback?

0 Likes
1 Solution
Anonymous
Not applicable

To be more specific it should be:

4) connup -> encryption_changed (also callback) -> smp_bond_result

So when you hello_client in Bluetooth Setting in Android to pair, it should automatically connect to the ble device.

View solution in original post

8 Replies
Anonymous
Not applicable

Hello.

Can you elaborate on connup_callback and conndown_callback?

Talking about callbacks in Android or on the BLE device?

James

0 Likes
Anonymous
Not applicable

connup_callback means :  registered by " bleprofile_regAppEvtHandler(BLECM_APP_EVT_LINK_UP

conndown_callback means :  registered by " bleprofile_regAppEvtHandler(BLECM_APP_EVT_LINK_DOWN

0 Likes
Anonymous
Not applicable

using android phone, i connected to BCM92073X app (modified hello_client).


0 Likes
Anonymous
Not applicable

Okay.

From my experience, when you pair with the ble device, conndown_callback does not get called.

When you pair, connup_callback gets called. Then when the pairing is done, smp_bond_result callback gets called.

After the pairing, the ble device will stay connected.

James

0 Likes
Anonymous
Not applicable

If you are seeing conndown_callback when you are trying to pair, it's probably because Android device is not pairing with the ble device properly.

How are you connecting to hello_client?

Using an Andoid app? or just by pairing in the Bluetooth Setting in Android?

James

0 Likes
Anonymous
Not applicable

in the Bluetooth Setting in Android

when i select hello_client(modified), paring is success. (is involved paired devices in android)

and then, Through "auto(wait some seconds)" or "manually select hello_client in paired devices", connection is successed.

at this flow,

which is right?

1) connup ->  smp_bond_result -> connup

2) connup -> smp_bond_result -> conndown -> connup

3 ) connup -> smp_bond_result

4) others... ??

0 Likes
Anonymous
Not applicable

To be more specific it should be:

4) connup -> encryption_changed (also callback) -> smp_bond_result

So when you hello_client in Bluetooth Setting in Android to pair, it should automatically connect to the ble device.

Anonymous
Not applicable

thanks a lot, James

0 Likes