So I\'ve made this app, where I find all BLE Devices with a name. But how can I make one of the specific fields, clickable and automatic connect to the device, so I can star
To connect to the Device first you must perform you BLE scan which (if your using the starter code) runs a callback and add it to a list of found devices.
Add a filter in to only allow the set device you are looking for. As BLE advertises a packet upto 31 bytes you should have some data in here which discerns you device such as manufacturer id or data etc. Or if you are working on a simple project you can programmatically hard code in the device address.
Then when this device is discovered from the scan you can stop your BLE scan and automatically queue a connection request. This will ask for the GATT request to be made and therefore, grant you access to the GATT services and thus characteristics on the device.