-
Notifications
You must be signed in to change notification settings - Fork 118
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Hey
I wonder, is it possible to create firmsoftware on android, to make it behave like AirTag.
At the moment I'm trying to experiment with android.bluetooth.le.BluetoothLeAdvertiser, but not sure that if it's right direction and it's capable of doing so.
Here is my snippet, any comments, guidances, ideas would be helpful.
Thanks!
// manufacturerData is similar to
// https://github.com/positive-security/find-you/blob/ab7a3a9eaa4559d34fcdf37142729bef3ae38a36/Firmware/Microbit_v1/offline-finding/main.c#L32
val settings = AdvertiseSettings.Builder()
.setAdvertiseMode(AdvertiseSettings.ADVERTISE_MODE_LOW_LATENCY)
.setConnectable(false)
.setTxPowerLevel(AdvertiseSettings.ADVERTISE_TX_POWER_HIGH)
.build()
val manufacturerData = createManufacturerData()
val data: AdvertiseData = AdvertiseData.Builder()
.setIncludeDeviceName(false)
.addManufacturerData(0x004C, manufacturerData)
.build()
try {
bluetoothLeAdvertiser?.startAdvertising(settings, data, advertiseCallback)
} catch (e: Throwable) {
Log.e(TAG, "SecurityException: ${e.message}")
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request