central- peripheral connection

Hi all

I have an issue regarding central- peripheral connection.( using  nRF52832)

In the past I developed a peripheral device using SDK 11.

In order to manufacture it- I’ve also developed a “tester” using a ble_central example.

The tester’s job was to:

   Search the tested peripheral advertisement , connect to it(+PASSKEY),

   read & write a characteristics.( read & write: to test some peripheral HW)

All was working fine, till the SDK11 peripheral doesn’t work properly with new cellphones .

So I’ve redeveloped the peripheral using SDK17

Trying to connect SDK11 central to SDK17 peripheral results:

  Central searches & finds  the peripheral, connecting to it (if 1st time- then requesting the PASSKEY) .

  reading from a characteristic results in data length =0 .

So I rewrote the central (SDK17) ,starting with ..\examples\\ble_central\ble_app_hrs_c .

As of now : the central searches & finds the peripheral.

Then I use sd_ble_gap_connect to try to connect.

 

I have a LED in the peripheral

It goes on in ble_evt_handler()  if p_ble_evt->header.evt_id== BLE_GAP_EVT_CONNECTED

Goes off  if == BLE_GAP_EVT_DISCONNECTED

According to that LED- a connection for a very short time is made, than disconnects.

The peripheral has a PASSKEY but nowhere in the central does anyone requests it:

That is: never (p_ble_evt->header.evt_id)== BLE_GAP_EVT_AUTH_KEY_REQUEST

So I never get the chance to use sd_ble_gap_auth_key_reply to set a PASSKEY

It seems that the problem is before the PASSKEY

What needs to be done?

Thanks

Yona

Parents Reply Children
No Data
Related