This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

No BLE_GATTS_EVT_RW_AUTHORIZE_REQUEST with bt_gatt_write

hi, 

I am using Running Speed and Cadence Service structure, when i raise a write command (bt_gatt_write) from the client I was expecting a BLE_GATTS_EVT_RW_AUTHORIZE_REQUEST to occur. However no flag is raised on the server side. 

Can anyone tell me what am I missing?

Parents
  • Hi

    Are you sure that authorization is enabled in your application? Where authorization isn't needed, you'll get a BLE_GATTS_EVT_WRITE event instead, and the characteristic value has already been updated and contains the value provided by the peer.

    If authorization is required you should get a BLE_GATTS_EVT_RW_AUTHORIZE_REQUEST event. Authorization is set by setting auth_required = 1 in your application.

    Best regards,

    Simon

Reply
  • Hi

    Are you sure that authorization is enabled in your application? Where authorization isn't needed, you'll get a BLE_GATTS_EVT_WRITE event instead, and the characteristic value has already been updated and contains the value provided by the peer.

    If authorization is required you should get a BLE_GATTS_EVT_RW_AUTHORIZE_REQUEST event. Authorization is set by setting auth_required = 1 in your application.

    Best regards,

    Simon

Children
Related