FAQ Database Discussion Community


Bluetooth connections on iOS

android,ios,bluetooth,android-bluetooth,ios-bluetooth
We're trying to observe when Bluetooth devices are connected and disconnected from an iPhone. We essentially want to react (not necessarily in the foreground) when certain devices of interest connect. In Android you can receive the ACL_CONNECTED and ACL_DISCONNECTED actions. What is the equivalent to this behavior on iOS? I...

Windows Phone 8.1 Connect to Pebble via Bluetooth Rfcomm

c#,bluetooth,windows-phone-8.1,pebble-watch
I have a problem when I trying to connect with pebble watch via bluetooth. This is my code: var serviceId = Guid.Parse("00001101-0000-1000-8000-00805F9B34FB").ToString("B"); PeerFinder.Start(); PeerFinder.AlternateIdentities["Bluetooth:Paired"] = ""; var pairedDevices = await PeerFinder.FindAllPeersAsync(); PeerInformation selectedPeer = pairedDevices[0]; var streamSocket = new StreamSocket(); await streamSocket.ConnectAsync(selectedPeer.HostName, serviceId); Also in manifest: <Capabilities> <Capability Name="internetClientServer"...

Start bluetooth adapter without pop up

java,android,bluetooth,android-bluetooth
How can we start the bluetooth adapter in background without the validation popup ? normal way : Intent enableBtIntent = new Intent(BluetoothAdapter.ACTION_REQUEST_ENABLE); context.startActivityForResult(enableBtIntent, 1); context.sendBroadcast(enableBtIntent); ...

Handle Android Bluetooth LE Disconnect Notification

java,android,eclipse,bluetooth
I have finished developing an Android app that connects to a Bluetooth LE (Low Energy, 4.0) Pedometer. Everything works great except I am not handling disconnection scenarios at all and I want to make sure I am. I want to make sure that if the user turns off the smartphone...

Converting a String from Byte array to int

java,android,bluetooth,arduino
I've been googling all night for this problem since it is my first time to use arduino and android. My question is, how can I convert the variable data *String to int? I've been getting NumberFormatException whenever I do: int pulse = Integer.ParseInt(data); My objective here is to be able...

Problems with check if GPS, and bluetooth is activated

java,android,bluetooth,gps
I have some problems with a check if user has turned on bluetooth, and gps. If the GPS is turned off the "OK" icon allways display status as the gps is activated. If the bluetooth is turned on the "OK" icon will show. But not the "notOK" icon when it's...

HDP android implementation

android,bluetooth,android-bluetooth,bluez
I`m trying to link my Android phone(xperia sp) with installed HDP app(sink) to laptop with Ubuntu 14 and Antidote(sample_bt_agent). HDP application: https://android.googlesource.com/platform/development/+/512ea9b6f8cc75ec74a7ab8d1c38dec201667f1e/samples/BluetoothHDP Antidote: http://oss.signove.com/index.php/Antidote:_IEEE_11073-20601_stack And there is an error on Ubuntu: connection initiation error: No matching MDEP found And debug message from Eclipse ADT: Method "CreateChannel" with signature "os" on...

How do Bluetooth SDP and UUIDs work? (specifically for Android)

android,bluetooth
My understanding is that the SDP is a list of UUIDs that other devices can fetch. According to this PDF from MIT, "A more general way to think of SDP is as an information database." Does this mean I can add multiple values to SDP? Since Android has BluetoothDevice.fetchUuidsWithSdp(), how...

Why are my object's fields set to default after deserializing with objectInputStream.readObject()?

java,android,bluetooth
In Java, I have a simple class with three public (primitive) fields like so: public class MyObject implements Serializable { public volatile float x, y, z; public MyObject() { this(0, 0, 0); } public MyObject(float x, float y, float z) { this.x = x; this.y = y; this.z = z;...

Why does Android Wear bluetooth disconnect after some time - btm_sec_disconnected?

android,bluetooth,android-wear
I am developing an android app for android wear Android Wear 4.4W. I'm debugging the app directly via usb in the smartwatch (that's how I want it - no companion app on the phone). The app receives bluetooth messages every 10ms. After 10-20s, this error is thrown - 01-01 21:10:22.683...

App Hanging on “let SKView as! SKView” (Swift)

ios,swift,bluetooth,xcode6
I am trying to create a SpriteKit based game, and am trying to establish basic bluetooth connectivity before I continue, however my game is crashing while segueing from the menu to the GameScene, and I am getting a "Could not cast value of type 'UIView' to 'SKView'" error. My Game...

Bluetooth: how to send large files

bluetooth
I need to make an Android application that sends large files (100-500 KB) over Bluetooth. It is very important to preserve the integrity of the data, avoid any corruption of the files sent. Please should I implement my own protocol? Is there a suitable profile that I can use? (it...

Can I use the Android Bluetooth API on regular Linux distros?

android,linux,bluetooth,android-bluetooth
Is it possible to use the Android Bluetooth API on a regular Linux distribution (eg Ubuntu, or Raspbian) ? My reasons for wanting to do this are: Java is a language I'm very comfortable with The Android API looks very comprehensive with support for Bluetooth LE. I may wish to...

Ble Scan service of a device without connecting to it

java,bluetooth,bluetooth-lowenergy,device,android-bluetooth
I want to scan some device with BLE. I only want to show my device, so for know I get the name of the device and if it is the good one I put it in my list. if (device.getName().contains(DEVICE_NAME)) { mDevices.put(device.hashCode(), device); invalidateOptionsMenu(); } My problem is that if...

Basic Serial-Communication over Bluetooth (Cmd Syntax Issue?)

android,serialization,printing,bluetooth,adapter
I'm having trouble communicating with a Avery GSM Indicator (control box w/display for a weigh scale & printer). My inexperience leads me to suspect my command-syntax is way off. I'm currently establishing a connection with the bluetooth dongle, creating an OutputStream, and attempting to send commands over that with this...

Process the data received from bluetooth on android device

android,bluetooth
I am writing an application for a project, which detects light intensity and etc. The application is supposed to send out command from android device to Arduino board and receive data from it. It serves as a bluetooth terminal, which I have already finished. Now, I want to process the...

calling a method outside Onclick listener method in android app

android,bluetooth,arduino
I am using following tutorial to send message to arduino via Bluetooth. (see LEDOnOff.java code) http://digitalhacksblog.blogspot.in/2012/05/arduino-to-android-turning-led-on-and.html I want to make changes to this code such that the sendData() method is called as soon as the app starts but when i call sendData() method outside onClick listener of the button, app...

Android Lollipop - Service Intent must be explicit

android,android-intent,service,bluetooth,android-5.0-lollipop
I have (what I am sure is a simple) problem with Lollipop and explicit intents. I have built an app that communicates over a bluetooth connection to a printer - this works fine on anything below Lollipop. I've checked various other answers and the Android documentation but cannot see any...

UART buffer not raising a flag on PIC24F

c,bluetooth,uart,microchip,pic24
I am using an RN42-XV bluetooth module to send characters to the PIC24F from a computer. The module is connected/paired correctly and the characters that are sent across are also correct (used an oscilloscope). This is how it is being initialized: void initUART(){ //Peripheral Pin Mapping RPINR19bits.U2RXR = 5; //pin...

Is there a way to change bluetooth module's baud rate via Bluetooth connection with Android device?

android,bluetooth,spp
I would like to change a default baud rate of the bluetooth module. I am having an IR receiver which works on baud rate 2400 and it is connected directly to bluetooth module. I want the flow to be IR receiver->Bluetooth module->Android device. To do that, I assume I need...

Custom Bluetooth message mBluetoothAdapter

android,bluetooth
With the following code you can pop up a window with bluetooth acces request: if (!mBluetoothAdapter.isEnabled()) { Intent enableBtIntent = new Intent(BluetoothAdapter.ACTION_REQUEST_ENABLE); startActivityForResult(enableBtIntent, REQUEST_ENABLE_BT); } The output of the code is the following image: Is it possible to change the message (so not "An app wants to turn on Bluetooth",...

How to define chrome.bluetooth successfully?

javascript,google-chrome,bluetooth,bluetooth-lowenergy
I am looking for a minimal working example of a bluetooth low energy object for chrome such that: chrome.bluetooth returns something other than undefined from javascript at runtime. I've tried various incarnations of manifest.json including: { "name": "Bluetooth Low Energy Test App", "description": "App testing the chrome.bluetoothLowEnergy API", "version": "0.1",...

Android ble app crash if bluetooth is turned off in android lollipop

android,bluetooth
Hello I am try to scan the bluetooth ble device for Android Lollipop. It is working fine but if turned off the bluetotooth an then run the App it will crash and then give the pop up to enable the bluetooth.Ideally like it should give the pop up to enable...

Converting sensordata from arduino in java

java,bluetooth,weka
I'm building a program in Java where I receive sensordata from arduino (x,y,z). I get the data, but it's in the wrong format. I need to read the data as single values so I can put them in arraylist. public class SerialInput { SerialPort sp; int counter = 0; public...

Android reconnect to bluetooth device if connection lost

java,android,bluetooth,android-broadcast,android-bluetooth
My phone is connecting to a bluetooth device and it works normally. It connect and the connection holds. I can change orientation, have my app in the background, I can close app and when I turn it back on it will automatically connect. But from app users I get some...

How to connect android device via bluetooth with matlab 'Instrument Control'-Toolbox?

android,matlab,sockets,bluetooth,serial-port
I want to connect an android device over bluetooth with matlab for exchanging data between matlab and my own android app. But I can't connect via 'Instrument Control'-Toolbox with my android devices. Why? First I scaned for all available devices and then tried to connect (with the "connect"-button) with android....

What's the purpose of “Bluetooth snoop logging” option on Android Wear devices?

android,bluetooth,android-wear
It's in the wearable's Settings menu, in the Developers Options section. I couldn't find any information about it, nothing in the documentation either. What are the potential use case scenarios of this feature? Note: to unlock the Developers Options section, tap 7 times on the About item....

Bluetooth.ACTION_FOUND not registering

android,bluetooth
I have a bluetooth device. If: They have already paired and connected to the device it becomes unplugged then it becomes plugged back in I would like to auto-connect to it. That's why I'm listening to ACTION_FOUND. My code is fairly simple. The ACTION_BOND_STATE_CHANGED and ACTION_ACL_DISCONNECTED work just fine. I...

CoreBluetooth and BluetoothManager, device is not BLE

ios,objective-c,swift,bluetooth,bluetooth-lowenergy
Connect and receive data via bluetooth. We are developing an app for a client. It is a toy for babies that connects via bluetooth and we're having trouble connecting and transferring data. After all the research we did, we found two alternatives: CoreBluetooth and BluetoothManager. As far as I know...

BluetoothAdapter.getDefaultAdapter(); returns null

android,bluetooth,initialization,adapter
I'm starting to develop an app to communicate with an arduino device through bluetooth. I'm initializing the bt adapter with BluetoothAdapter btAdapter = BluetoothAdapter.getDefaultAdapter(); The problem is that btAdapter returns null, txt_status.append("\nAdapter " + btAdapter); Its like the device hasn't got a bluetooth adapter, which is not my case. Any...

How much memory does Bluetooth Low Energy device has

bluetooth,bluetooth-lowenergy,ibeacon,altbeacon
Let's say I want to start transmitting advertising packets from a Blueooth 4 module attached to a Raspberry Pi. I am planning to use BlueZ library for the same. Have a basic questions regarding the same - How much memory does a typical Bluetooth device contains (is it standard or...

Android - Bluetooth Buttons… Media Button Intents or Bluetooth Headset API?

java,android,bluetooth
edit It think all this stuff is now well out of date, there have been many changes to this as android has developed. I'll post an answer when I have worked it out (if noone else has). I really just want a background app to get first crack at bluetooth...

How to request Android user to enable Bluetooth through a click?

android,bluetooth
from http://developer.android.com/guide/topics/connectivity/bluetooth.html i know that i need to the following to request the user to enable his BT: if (!mBluetoothAdapter.isEnabled()) { Intent enableBtIntent = new Intent(BluetoothAdapter.ACTION_REQUEST_ENABLE); startActivityForResult(enableBtIntent, REQUEST_ENABLE_BT); } but the question is how to use it in a class? why does my code crash whenever click on the button...

Send & receive data simultaneously over Bluetooth

android,bluetooth,arduino,android-bluetooth
Can I use Bluetooth to send and receive data at the same time and make a full-duplex connection between two devices? I'm trying to connect an Android device and an Arduino (or AVR micro), and send data between them simultaneously (in real time). Thanks!...

Object push to bluetooth without pairing

bluetooth
Is it possible to send some notification messages to the nearby Bluetooth devices without pairing.I have found some protocol for these - OBEX Oject Push. But am not clear whether is is feasible without pairing request .Any demo apps for reference?

default location for sqlite databases on an android device is not displaying my database

android,mysql,sqlite3,bluetooth
I am a newbie to android. In my project i am sending data selected from drop down (spinners) via bluetooth. I have created a database and loaded the values into spinners and sent the selected values via bluetooth. It is working fine .Now the problem is i know the database...

My bluetooth connected with nokia but not connected with android

android,bluetooth,project
I am making bluetooth app in android studio everything works fine having problem when i connect bluetooth with my android mobile it is not connecting but when i connect it with my brother c2-02 it's now connected why????? My connecting thread is given below private class ConnectThread extends Thread {...

Android Bluetooth- MAC address

java,android,bluetooth,android-bluetooth
I am trying to get the MAC address of a bluetooth device when I click on a device in the listview. I want to pass in the MAC address in BluetoothDevice device = mBluetoothAdapter.getRemoteDevice(address); Is there a way I can extract the MAC address when I choose a device on...

Bluetooth Low Energy: gattCharacteristic.getDescriptor() returns null

android,bluetooth,bluetooth-lowenergy,descriptor,characteristics
I have a problem with getting characteristic's descriptor, it always returns null. There is a chunck of my code: public static final String CHARACTERISTIC_UPDATE_NOTIFICATION_DESCRIPTOR_UUID = "00000001-0000-1000-8000-00805f9b34fb"; public final static UUID tmp_uuid_1 = UUID.fromString(CHARACTERISTIC_UPDATE_NOTIFICATION_DESCRIPTOR_UUID); ... BluetoothGattDescriptor descriptor = gattCharacteristic.getDescriptor(tmp_uuid_1); descriptor.setValue(true ? BluetoothGattDescriptor.ENABLE_NOTIFICATION_VALUE : new byte[]{0x00, 0x00}); I tried this on...

Xamarin iOS Bluetooth Low Energy - CBPeripheral.UpdatedCharacteristicValue reading TX characteristic shows unexpected data

ios,bluetooth,xamarin,bluetooth-lowenergy,cbperipheral
I recently received a BLE device for Bluetooth to Serial. It uses TruConnect and I'm trying to get it to communicate with my serial device. The serial device receives communication over a serial cable and echoes back anything that is sent to it as well as any results from a...

Bluetooth: how to let ios attempt “App Not Installed”

ios,iphone,ipad,bluetooth
I am doing something by Nordic nrf51822 BLE solution, is there any idea to let ios(iphone/ipad) attempt dedicated app is not installed after ble device pair to the iphone or ipad(like the attachment picture)? I search the internet and many forums, no found similar use case. But in Logitech bluetooth...

Multiple CBCentralManager instances?

ios,bluetooth,core-bluetooth
Are multiple CBCentralManager instances supported? If so, in which version of iOS did they begin to be supported? I've found multiple emails on the Apple mailing lists stating that they are not. However, this is not enforced with exceptions or by having a theoretical +sharedCentralManager. One states that the documentation...

Issue in Bluetooth pairing

bluetooth,embedded,windows-ce,windows-embedded-compact,hci
We are testing Bluetooth in WEC2013 with a USB based dongle from generic vendor on iMx6 platform. We are using the default HCI Transport layer provided with WEC2013 BSP. BT is turned on and able to scan all the nearby devices. We have enabled following set of sysgen variables and...

Exception when connecting to device

c#,bluetooth,32feet
I have a problem with connection to my Bluetooth device (HC-05). When call BluetoothClient.Connect(), sometimes exception occures - "An invalid argument was supplied.", or another. But sometimes device connects (usually at first connection)! Do I have to close connection when I leave app?

Virtual serial port over BLE + ios?

ios,bluetooth,bluetooth-lowenergy,spp
AFAIK iOS 7 supports BLE but it does not support SPP. Any chance to have virtual serial port on iOS just like it's UART to send bytes to BLE module and receive bytes from BLE module? I've purchased cc2540 and cc2541 TI's ble modules, will they work as virtual serial...

IOS App : Is it possible to have 2 Bluetooth connections in one app?

objective-c,iphone,xcode,bluetooth,bluetooth-lowenergy
I'm in the process in developing an App That receives data from a Bluetooth accessory and does some processing for the data and then send a simple command to a Bluetooth-Low Energy(BLE) Module which is connected to an arduino . So far I managed to develop and app for the...

Difference between attributes and services in BLE

bluetooth,bluetooth-lowenergy
I would like to know what is the difference between attributes and service in GATT in BLE specification. and where we can find attributes, are they in service, caracteristics or in descriptors. thanks

Writing is not permitted error when attempting to subscribe to CBCharacteristic

ios,objective-c,bluetooth,bluetooth-lowenergy,core-bluetooth
I'm developing an App that communicates with a Bluetooth LE device and so I'm using CoreBluetooth to do this. The peripheral I'm using exposes 1 service which has two characteristics a serial port FIFO characteristic which supports indication/notification/write/write no response; and a serial port credit characteristic which supports write. From...

Can I receive more bytes in one transfer from this c# to android device?

c#,android,json,bluetooth
I'm trying to transfer a long string (2286 bytes) over Bluetooth. I've a bit of an issue about receiving a long json string over the bluetooth.. Well, not an issue, because it is receiving it, but in the manner it is receiving it. I was wondering if it was possible...

Displaying a list of paired bluetooth devices in a popup dialog - setAdapter null pointer exception

java,android,bluetooth
I'm trying to create a simple app that displays a list of paired bluetooth devices in a dialog box when a "Connect" item in the action bar is clicked. Here is the XML of the dialog I'm inflating: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/bt_list" android:orientation="vertical" android:layout_width="match_parent" android:layout_height="match_parent"> <ListView android:id="@+id/BTList" android:layout_width="fill_parent" android:layout_height="200dp" > </ListView>...

Receive the actions of a headset in Android

android,groovy,bluetooth
I'm trying to write a music player for Android as a project for school and I try to intercept the action of my bluetooth headset (Parrot Zik 2.0 if it matters). Here is my current code : AndroidManifest.xml : <receiver android:name=".core.MediaButtonReceiver"> <intent-filter android:priority="100"> <action android:name="android.intent.action.MEDIA_BUTTON" /> </intent-filter> </receiver> and in...

Bluetooth mobile streaming/hotspot functionality

android,ios,bluetooth
I'm wondering what would be the best way to make use of bluetooth functionality: 1) Is it possible to turn on/use bluetooth function from an app (ios/android)? if so how? 2) What would be the best way to enable broadcasting of bluetooth signal? For instance, is it possible to give...

Global name 'bluetooth' is not defined

python,data,bluetooth,connect
I am working with the bitalino board and I wanted to print the data with python but when I run the proper code, it shows me the message Global name 'bluetooth' is not defined According to my pc the board is connected via bluetooth. I don't know what the problem...

how to implement OnItemClickListener in this code?

java,android,bluetooth
I want to implement OnItemClickListener in this ListView ,But when i add code for this,my app will not work even there is no error. its closes automatically when I click on the Listview item. Please help me, I am a beginner in Android. I am adding my whole code here....

Prevent disconnection of Bluetooth LE Service

android,bluetooth,bluetooth-lowenergy
I am making an app using Bluetooth LE Service. What I noticed is the device gets disconnected automatically after some time after app goes to background. Can someone explain reason for this? I am getting following error. 02-12 16:48:27.497 11695-11695/main.nesttech.com.nesttechble E/ActivityThread﹕ Activity main.nesttech.com.nesttechble.MainActivity has leaked ServiceConnection [email protected] that was originally...

Bluetooth LE app, how to build it cross-plaftorm (iOS-Android)?

android,ios,cordova,bluetooth,bluetooth-lowenergy
I am working on an app that talks to a Bluetooth LE device. I would like some way to avoid developing it twice, for iOS and for Android. Is there a cross-platform app framework that has good support for Bluetooth LE? I have had a quick look at frameworks like...

Using IPEGA bluetooth gamepad with Retropie

bluetooth,raspberry-pi,emulation,bluez
I'm trying to configure my Ipega PG-9025 with Retropie with no succeed. I made some progress following this link (http://askubuntu.com/questions/608386/using-ipega-bluetooth-gamepad-with-steam-linux) but it only works at Emulation Station menu... The gamepad stops working in every emulation system and also gives me some problems pairing and reconnecting my device. Has someone any...

Bluetooth classic connection awareness

ios,objective-c,bluetooth,bluetooth-lowenergy,core-bluetooth
I have a Bluetooth application that communicates with a peripheral device over a low energy. This peripheral device also has a classic (HFP and/or A2DP) connection with the iOS device. It happens that the classic connection gets interrupted sometimes. What I need is to be able to notify the user...

iPhone - Best Way to Create Real Time Connectivity

ios,iphone,bluetooth,multiplayer,multipeer-connectivity
This is a general question I was having about Multiplayer connectivity in iPhone apps. I was wondering, what is the best method for connecting two players playing a game? I know there are forms using bluetooth, peer to peer connectivity, and game center, but which is the best one for...

iOS Bluetooth delegate connect function not being called

ios,swift,bluetooth
I'm trying to listen to all Bluetooth connect/disconnect events. Even though the delegate's centralManagerDidUpdateState function is called, nothing happens when I connect or disconnect Bluetooth devices. I'm confused as to what's going wrong. I initialize the Central Manager/delegate like this: var btDelegate: CBCentralManagerDelegate = BluetoothDelegate() var btManager = CBCentralManager(delegate: btDelegate,...

CoreBluetooth Framework: How to obtain connected devices without knowing the Service IDs?

ios,bluetooth,core-bluetooth
I have a bluetooth bracelet which connects to my iPhone 5s via Bluetooth; it comes with an App called Zeroner. Now I want to obtain the information from the connected and paired up bracelet without using the App. Here is what I attempted to do: Setup CBCentralManager Use retrieveConnectedPeripheralsWithServices: to...

Unable to make client server Bluetooth serial connection between Android phone and PC

java,android,bluetooth
According to my research it is most probably due to wrong UUID or because my PC doesn't support SPP. My SG4 is used as a Server while PC is used as a client. When I use standard serial UUID my android code never executes after .connect(). I thought I have...

Change bluetooth mac address in Raspbian

bluetooth,raspberry-pi,raspbian
hi i need to change the bluetooth mac address from my device. i've download the bdaddr utility from here! and i compiled it. Then... wget -U "Mozilla" http://www.petrilopia.net/wordpress/wp-content/uploads/bdaddrtar.bz2 ... mv bdaddrtar.bz2 bdaddr.tar.bz2 tar xvjf bdaddr.tar.bz2 cd bdaddr sudo apt-get install libbluetooth-dev ... make ... [email protected] ~/bdaddr $ hcitool dev Devices:...

Can Pyudev detect bluetooth devices?

bluetooth,device,pyudev
I am writing an application which monitors some devices connected to the computer. I loop over all the devices like this : from pyudev import Context, Monitor, MonitorObserver context = Context() monitor = Monitor.from_netlink(context) for device in context.list_devices(): print_device(device) USB devices are detected, along with most of built-in boards (ethernet,...

Why won't my cross-compiled CGO binary run on the Raspberry Pi (Raspbian)?

go,bluetooth,raspberry-pi,raspbian,cgo
When I compile the following snippet of code (playground link): package main /* #cgo LDFLAGS: -lbluetooth #include <bluetooth/bluetooth.h> #include <bluetooth/hci.h> #include <bluetooth/hci_lib.h> */ import "C" func main() { C.hci_get_route(nil) } …using these environment variables: CC=arm-linux-gnueabihf-gcc CGO_ENABLED=1 GOARCH=arm GOARM=6 I get a 1.6Mb binary that: works on my ODROID-C1 (ARMv7, running...

writeCharacteristic() returns true, but does not call onCharacteristicWrite()

android,bluetooth,bluetooth-lowenergy
I wish to read a characteristic value stored in a device, modify the value, and then write it to the device. For some reason, writeCharacteristic() return true, but the internal device value does not change and onCharacteristicWrite() is not called. In fact, for some reason it is only called if...

How can I maintain the whitespace of a command's results in a linux dialog inputbox?

bash,bluetooth,dialog
I've got a bash script file that I've been working on, that I'm trying to get to be able to list the currently available Bluetooth devices and then allow the user to choose one and connect to it. I've got all of the code to work, but the listing of...

How to detect with CoreBluetooth when a peripheral disappears?

ios,bluetooth,core-bluetooth,cbcentralmanager
I would like to have a list of ble devices to which my iOS can connect, which refreshes when ble devices appear and disappear. In order to do that, I created an NSMutableDictionnary* peripheralsAvailable, and everytime - (void)centralManager:(CBCentralManager *)central didDiscoverPeripheral:(CBPeripheral *)peripheral advertisementData:(NSDictionary *)advertisementData RSSI:(NSNumber *)RSSI; is called by the CBCentralManager,...

Thread, Asynctask or intentService for my app?

android,multithreading,service,android-asynctask,bluetooth
I need your opinion for my app. I'm developing an app which communicates with a radio via bluetooth. App is divided into 3 (swipe) tabs : In the first I put a connection option and a "connect" button to connect my device to a radio. In the second there is...

Bluetooth HC-05 Master - connect to Android device automatically

java,android,bluetooth
I have paired my HC-05 as master with my android device (listed in my bluetooth devices list). After the first pairing the HC-05 disconnects and seems not to connect to my Android device again. http://blog.zakkemble.co.uk/getting-bluetooth-modules-talking-to-each-other/ (master as master) Is it possible to configure the hc-05 that way that it automatically...

Android bluetooth socket timeout

android,bluetooth
Maybe I miss something, but How can I change the timeout of BluetoothSocket.connect() ? Thanks you Anthony...

Connecting multiple wireless devices to one main device using bluetooth

ios,iphone,bluetooth
What I want to do is connect to bluetooth enabled devices to one main device. For example two bluetooth speakers to connect to my iPhone and play music. Do speaker A needs to connect to Speaker B through bluetooth and then connect to the iPhone? IS this even possible?...

How to find Bluetooth signal strength of a connected bluetooth device

ios,swift,bluetooth,core-bluetooth
I need to get the Bluetooth signal strength of a connected device and I'm getting it. I can see the surrounded devices and I could display the RSSI value to a UITableview. Here I need to make the RSSI value changing according to my device position by doing this I...

Bluetooth HCI snoop log not generated

android,bluetooth,android-4.4-kitkat,android-bluetooth,s5
I'm running Android 4.4.2 and I enabled the "Bluetooth HCI snoop log" as described here Sniffing/logging your own Android Bluetooth traffic After turning bluetooth on and off I rebooted the phone. I could not find the log file in the expected location: $ adb pull /sdcard/btsnoop_hci.log remote object '/sdcard/btsnoop_hci.log' does...

BluetoothAPIs.h syntax error

c++,bluetooth,header-files
I have following problem. When I try to include BluetoothAPIs.h, the compiler shows me many syntax errors, example: [C++ Error] BluetoothAPIs.h(133): E2141 Declaration syntax error [C++ Error] BluetoothAPIs.h(171): E2238 Multiple declaration for '__checkReturn' ... This is BluetoothAPIs.h "invalid" part of code: 132-138 __checkReturn HBLUETOOTH_RADIO_FIND WINAPI BluetoothFindFirstRadio( __in const BLUETOOTH_FIND_RADIO_PARAMS *...

Bluetooth pairing - how to show the simple Cancel/Pair dialog?

android,android-intent,bluetooth,android-bluetooth,bluetooth-oob
I have prepared a simple test project for this question at GitHub. I am trying to create an Android app, which would scan a QR code from a computer screen and then use the data (MAC address and PIN or hash) for easy pairing (bonding) with a Bluetooth device. Similar...

Getting Android Bluetooth Adapter Name from JNI/C++

android,c++,bluetooth,android-ndk,jni
The Android API in question is android.bluetooth.BluetoothAdapter, which has a member function getName() which returns the adapter's user friendly name. In java: BluetoothAdapter.getDefaultAdapter().getName() I know I can wrap this in a java-function, which I call through jni, but, how can I achieve the same in C++, with only jni/android-ndk?...

didExitRegion not fired when turn off bluetooth

ios,objective-c,bluetooth,core-location,ibeacon
Im building a simple ios app with IBeacon, I'm monitoring a region but I have some issues with enter and exit events. If I go into a region the callback didEnterRegion is fired, but being within the region, turning off bluetooth doesn't fire didExitRegion callback. Is this the expected behavior?...

BlueZ scotest App and with Linux Config Can't Connect to SCO Socket

linux,bluetooth,linux-kernel,kernel,bluez
I am using BlueZ 4.101 on an embedded Linux project with Kernel 3.4.79+. Normal Bluetooth operations work great and I can use many headset with my device to transfer Audio. Now I am working towards Bluetooth Compliance and so I am using the Bluetooth SIG's USB PTS Dongle. I am...

Low Level Bluetooth Packet Analysis

ios,sockets,networking,bluetooth,reverse-engineering
I have a fitness tracker that uses Bluetooth LE, and my iPhone 6+. Unfortunately the app doesn't disclose the raw data coming out of the tracker and zero way to export it, while this data is very interesting to me. I purchased a Bluetooth LE sniffer from Adafruit and used...

Beacons in Windows Phone 8.1 - there are no possibilities?

c#,bluetooth,windows-phone-8.1,bluetooth-lowenergy,ibeacon
First of all, yes, i have read all other similar questions. Secondly, i am developing app (WP 8.1 WinRT), which must use Beacons. I read a lot about it, and i know, that generally connection with BLE device is not possible without pairing it first. But hope dies last, so...

Mindwave device validation in Visual Studio recognizes which COM port it's on, does not connect with device

c#,visual-studio,bluetooth
I'm using a Neurosky Mindwave headset to interface with the "HelloEEG" demo program that came in the ThinkGear .NET SDK for Visual Studio. connector.ConnectScan(); identifies COM3 as the port with the Bluetooth device plugged in, but it won't recognize the device. I wasn't sure if it was a timeout issue...

How deploy an large number iBeacons

bluetooth,raspberry-pi,bluetooth-lowenergy,uuid,ibeacon
I want deploy a large number of iBeacons with the same UUID because we can't access dynamically to the UUID of the beacons detected. What is the limit number of the maximum Beacons with the same UUID ? I found some discussions with a number of 65000 approximately, is it...

Bluetooth LE Java byte array size on characteristic setValue

java,android,bluetooth,bluetooth-lowenergy
I am trying to send a value using Bluetooth LE on my Android phone with the following line of code. I am getting an error that it exceeds the size of the array, which is 127 because of the 0xEA byte. I converted the byte to around 234. Is there...

Phone Bluetooth Wireless Microphone [closed]

python,audio,bluetooth,microphone
I am looking to turn my phone into a wireless microphone. This requires making a two part program. The first program would use the sound input from the microphone on my smartphone and sends it via bluetooth to my computer. The second program would be on my computer and treat...

Smart Bluetooth: GATT Vs. ATT - what are the differences between them?

bluetooth,bluetooth-lowenergy,att,gatt
Can anyone please define for me what are the differences between GATT and ATT? I didn't manage to understand. I know that they are both generic protocol to handle BLE services. but didn't really understand it. Please explain. Thanks!

Is Android BluetoothLE support two way communication between glass and mobile?

android,bluetooth,bluetooth-lowenergy,android-bluetooth
My Google Glass and Mobile supports Bluetooth LE.Can I use the Bluetooth LE for two way communication between Glass and mobile.I try to send an image from Glass to mobile and again send response to Glass using bluetooth LE.Is it possible to do this?

Bluetooth Related Linker Errors in XCode 6.1.1

ios,xcode,bluetooth,compiler-errors,linker-error
I'm relatively new to iOS development. I'm not sure what to do about resolving the following errors that I believe are due to referencing a bluetooth library. What can I do to debug/fix this? Undefined symbols for architecture armv7: "_CBCentralManagerScanOptionAllowDuplicatesKey", referenced from: _nclSStartScan in libNCLiOS.a(nclCb.o) "_CBAdvertisementDataManufacturerDataKey", referenced from: -[Boss centralManager:didDiscoverPeripheral:advertisementData:RSSI:]...

Beacon Bluetooth adddress in AltBeacon vs. BluetoothAdapater address

android,bluetooth,altbeacon
I'm currently using AltBeacon library to develop my app on Android. I need to identify which advertising device has sent the beacon from the scanning device's point-of-view. So, I am thinking of using bluetooth MAC address to check the advertising device. Using the library, my callback for RangeNotifier is called...

How to detect if a bluetooth headset plugged or not IOS 8?

bluetooth,ios8,headset,audiosession
In my project, I use AVAudioSession to detect any headphone is plugged or unplugged. But in this case, I can't detect when bluetooth device is plugged. Here is my code for headphone state. (void)audioRouteChangeListenerCallback:(NSNotification*)notification { NSDictionary *interuptionDict = notification.userInfo; NSInteger routeChangeReason = [[interuptionDict valueForKey:AVAudioSessionRouteChangeReasonKey] integerValue]; switch (routeChangeReason) case AVAudioSessionRouteChangeReasonNewDeviceAvailable:...

Android Development: Discovery of other devices using my app over Bluetooth

android,bluetooth
I am developing an android app where users must be able to see other users nearby them and send a message to that user specifically. I was hoping Bluetooth would be a good, low-energy solution to this. My trouble is in identifying nearby Bluetooth devices only if they are using...

BlueZ on i.MX25 : Can't connect RFCOMM socket: Operation now in progress

linux,bluetooth,embedded-linux,bluez,rfcomm
I'm trying to connect to a bluetooth device on embedded linux. BlueZ version is 4.101. Local bluetooth adapter is an USB Bluetooth dongle Trendnet TBW-107UB, for all tests. I can't provide details about the target device, as it is a product of the company I work for, sorry. Using the...

Bluetooth Shield V2.2 for arduino

ios,bluetooth,arduino,uuid,arduino-uno
I recently bought a bluetooth shield for my arduino. I am going to make an iOS app that will control the servos that I will be connecting to the arduino. I feel stupid asking this because it is hard to find but where do I find the UUID for the...

BluetoothProfile of Paired android device

android,bluetooth
is there any way to get the Profile of a paired blutooth device. i have been able to pair a bluetooth device and it has been paired as INPUT_DEVICE in android, i get the Object of BluetoothDevice for that , which contains the address and other things, but if the...

Send a Android BLE GATT Notification

android,bluetooth,notifications,bluetooth-lowenergy
I´m currently developing an BLE application, based on the Gatt sample project provided by Google. What I want to realize is to send a notification from my Android device(smartphone) to another BLE device(e.g. TI CC2540). There are many discussion about how to receive a notification on the Internet. However, I...

Send data from an android app to a Serial COM Port via Bluetooth

android,bluetooth,port
I'm new to android programming and to Bluetooth. I would like to send and receive data from my phone to an application on my computer that just connect to a PORT COM and can also send and receive data (like an UART). An exemple of such software (on the computer)...

How to extract data from Bluetooth packet data?

android,bluetooth,wireshark
After capturing data from Android 5.0 Bluetooth HCI Snoop Log (Settings > Developer options > Bluetooth HCI Snoop Log), I acquired a lot Bluetooth package data with ATT, HCI_CMD, HCI_EVT protocols. The Wireshark-compatible log can be downloaded here. How can I extract plain text data from the packages?...

Core Bluetooth - Unable to Write Value using CBCharacteristicWriteType.WithResponse

ios,swift,bluetooth,core-bluetooth
I am designing an iOS app with a custom made bluetooth enabled device that sends and receives text from my iPhone. I am able to send text data to the device when I send a CBCharacteristicWriteType.WithoutResponse, but that using that sends data as best-effort and not guaranteed according to Apple...

android.provider.Settings.ACTION_BLUETOOTH_SETTINGS crashes on Samsung

android,bluetooth,samsung-mobile
Anybody have any idea why Intent pairIntent = new Intent(android.provider.Settings.ACTION_BLUETOOTH_SETTINGS); startActivityForResult(pairIntent, 0); Crashes on all Samsung devices, but works fine on emulator, HTC, Sony, LG etc. EDITED ----------------------------------- Turns out Samsung also requires BLUETOOTH_ADMIN in the manifest <uses-permission android:name="android.permission.BLUETOOTH_ADMIN" /> ...

BlueZ Bluetooth API and distance calibration precision

c,bluetooth,bluetooth-lowenergy,bluez
I am using BlueZ C API to program my bluetooth mouse to read the distance. I have set up a bluetooth dongle. At the moment, I have to move the mouse at least 5-10 feet from the laptop (bluetooth dongle) to get some reading of RSSI. Below this distance, I...