KW36: OnConnectionState change query

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

KW36: OnConnectionState change query

449 Views
skalyan2
Contributor IV

Hi,

Is it possible like after physical,logical link and profiles gets connected between kw36 and another bluetooth device  gets connected, Can the connected peer device(not KW36) disconnect its GATT profile connection ? 

If it can disconnect, i have small query :

-->When the link gets disconnected, we will get "gConnEvtDisconnected_c" , similarly will NXP kw36 ble stack will provide any event to application when gatt profile gets disconnected ? 

0 Kudos
3 Replies

365 Views
estephania_mart
NXP TechSupport
NXP TechSupport

Hello ,

Sorry it is not quite clear which it's your question, could you please help me clarify ? Also, could you provide more details on what are you trying to achieve so I can try to understand in a better way your application?

Regards,

Estephania

0 Kudos

365 Views
skalyan2
Contributor IV

Hi Estephania,

I have one third party android mobile application which behaves like:

Once the android mobile app(acts as Central) initiates a connect request to KW36 (Peripheral) and after that android phone initiates a ATT discovery and once it has discovered all the services,characteristics , after that in the third party android application UI, i could see the pop up  "GATT disconnected". 

My requirement is that i need to get this gatt disconnected event in KW36 , is it possible ? 

Will KW36 will know that third party mobile application GATT is disconnected? 

Please get back if you got my requirement?

Thanks 

Sai Kalyan

0 Kudos

365 Views
estephania_mart
NXP TechSupport
NXP TechSupport

Hello,

Sorry for the late reply, we have been under a great load of work.

I can't really guarantee what it's happening in the third party application, still, when developing with Bluetooth LE in Android as far as my investigations went, there are two ways to disconnect a device with two different methods, so I'm not sure which one your mobile application uses.

I believe that what you will need to do or are trying to do it's to create your custom profile, and you are more likely to be looking for the unsubscribe functions in the SDK.

You can check for example the heart rate sensor example and look for the battery service, in the battery_service.c you will find a function called Bas_Unsubscribe.

Could you please check it and let me know if that it's helpful for you ?

Regards,

Estephania

0 Kudos