just
just

Reputation: 2020

How to delete discovered bluetooth devices on ios 7?

I use BeeTee project for discover nearby bluetooth devices. Everything is good, but if it discovered a device its store this somewhere, and i cant find it again. If the device doesnt send bluetooth signal the bluetooth manager write this in log: BTM: lost device "device_name" device_address

How can i delete discovered devices?

Upvotes: 0

Views: 172

Answers (1)

Michael Dorner
Michael Dorner

Reputation: 20185

They are stored in a dictionary:

@property (retain, nonatomic) NSMutableDictionary *currentAvailableDevices;

If you want to delete one of them, you can call the the delegate method

- (void)removeBluetoothDevice:(BluetoothDevice *)bluetoothDevice
{
    [self.currentAvailableDevices removeObjectForKey:bluetoothDevice.address];
    [self.tableView reloadData];
}

But are you sure that this approach makes sense?

Upvotes: 1

Related Questions