Questions tagged [cbcentralmanager]

CBCentralManager is an object used by CoreBluetooth on OS X and iOS to manage peripheral devices.

CBCentralManager is an object used by CoreBluetooth on OS X and iOS to manage peripheral devices. On CBCentralManager, you can find the following methods:

Initializing a Central Manager

– initWithDelegate:queue:

– initWithDelegate:queue:options:

Establishing or Canceling Connections with Peripherals

– connectPeripheral:options:

– cancelPeripheralConnection:

Retrieving Lists of Peripherals

– retrieveConnectedPeripheralsWithServices:

– retrievePeripheralsWithIdentifiers:

– retrieveConnectedPeripherals Deprecated in iOS 7.0

– retrievePeripherals: Deprecated in iOS 7.0

Scanning or Stopping Scans of Peripherals

– scanForPeripheralsWithServices:options:

– stopScan

Monitoring Properties

state property

delegate property

235 questions
0
votes
1 answer

EverTime Call didDisconnectPeripheral

Good Morning, this is Pavan, I have doubts in corebluetooth. I am using the bluetooth LE device. i wrote the sample code in Using core bluetooth frameworking in objective c , I got the bluetooth name, UUID, RRSI value. I used central manager,…
0
votes
1 answer

Assertion failure in CBPeripheralManager respondToRequest:withResult

When my iOS (peripheral) starts advertising, I instantly re-run my app, at this point, my computer (central) was in middle of subscribing to a characteristic and writing to it. Once my peripheral app finishes launching, something goes wrong…
0
votes
0 answers

LGBluetooth Scan in background or CBCentralManager scan in background

I am working on BLE Apps where i need to scan the device in Background mode. While debugging i found that it scan for the device but the discovery of devices is not called and returned. Everything works fine in Foreground Mode. Why can't my app scan…
0
votes
1 answer

iOS: How to set up iOS device to serve as a Bluetooth keyboard?

I want an iOS device to tell the world it is a keyboard, and when people pair with it, it will be able to send keystrokes. Based on a forum article, it appears I need to provide 4 services: 1800 (device info), 180f (battery), 1812 (input device),…
0
votes
1 answer

CBCentralManagerOptionShowPowerAlertKey AlertView / Alert Controller OK Button

In the app, I am creating a video player with a 'remote control' with two different iOS devices using Bluetooth Low Energy (BLE), where one device is the video player and the other is sending messages to play, pause, rewind, etc. Here I have the…
0
votes
0 answers

UITextView getting blocked because peripheral:didUpdateValueForCharacteristic: getting called very fast

I am trying to show data in UITextView by appending data coming from peripheral:didUpdateValueForCharacteristic:error:. In this case peripheral:didUpdateValueForCharacteristic:error: is getting called very frequently, due to which UITextView…
0
votes
1 answer

Unable to get CBcharacteristics value in didUpdateNotificationStateForCharacteristic

I am having a BLE device to which I am successfully connected. In this case whenever I send a string "GET DATA" to the BLE device, the device will respond by sending a certain response back to me. I am using didDiscoverCharacteristicsForService to…
0
votes
0 answers

ble peripheral disconnected in background after some time

I am using background fetch mode in plist . when we connect the peripheral to device its working in background for few moment but after 10-15 minute its automatically disconnect. I want my peripheral is always connect . which method is called when…
0
votes
0 answers

didConnectPeripheral not called.?

Iam Working on BLE project, I got a sample project which is in this link. So when i run on my Device(iPhone 5C), -(void) centralManager:(CBCentralManager *)central didDiscoverPeripheral:(CBPeripheral *)peripheral …
cdon
  • 264
  • 1
  • 13
0
votes
0 answers

CoreBluetooth - Writing data from Central to Peripheral

I referred Sample app provided by Apple for CoreBluetooth and I succeeded in sending Data from Peripheral to Central, Now I need to write Data from Central to Peripheral. After Googling i found that It can be done using [_discoveredPeripheral…
0
votes
1 answer

Failing To Discover Bluetooth LE Service Advertisement in iOS

I have created two iOS apps; one a Bluetooth LE peripheral that advertises a service, and one a Bluetooth LE central that scans for the advertised service. The peripheral is running on my iPhone5s, and the central is running on my iPad Mini. I…
JeffB6688
  • 3,782
  • 5
  • 38
  • 58
0
votes
1 answer

Swift class function not being called

I have the following class written in Swift: import UIKit import CoreBluetooth class vaBean: CBCentralManager, CBCentralManagerDelegate { func centralManagerDidUpdateState(central: CBCentralManager!) { println("didUpdateState") switch…
Roo
  • 259
  • 1
  • 3
  • 15
0
votes
1 answer

iOS Core Bluetooth (LE): App crash when handling different views

I have two views: One central TableView where all the discovered devices appear and one detailView which loads when the user selects to connect to one of the discovered devices. It works until the following point: Discovering devices Connect to…
0
votes
1 answer

CBCentral fails to find peripheral's service unless bluetooth is restarted

I have two apps talking through CoreBluetooth, iOS and Today Extension (peripheral) and OSX (central). 1 - Setup process (iOS app x OSX app): They connect, exchange data that is stored and disconnect. 2 - App's main feature usage (iOS Today…
Lee Andrew
  • 798
  • 7
  • 28
0
votes
1 answer

iOS 8 and ble CBCentralManager not working

I have an iOS app that is connecting to a device using a ble. iOS 7 is working. After upgrading to iOS 8, the CBCentralManager is not finding any peripherals. case CBCentralManagerStatePoweredOn: { NSDictionary *options =…
cgty
  • 1