I'm creating a ble central device that receives instructions via UART on which device to connect to and which UUID to write to.
I'm able to connect to a peripheral device. But all the examples for central require to run ble_db_discovery_evt_register(UUID) and then handles are assigned to peer_db.
i got sd_ble_gattc_char_value_by_uuid_read to work fine. but now i need to write to characteristic UUID. this requires DB to be setup with handles etc. Is there any way to dynamically assign handles to peer_db without hard coding those values?
I just need a strategy of how to go about discovering and adding handles to the DB without hard coding like that:
hope that makes sense
thanks