This project has moved. For the latest updates, please go here.

Windows Phone 8

Windows Phone 8, and by extension Windows Embedded Handheld 8, has partial Bluetooth support via the PeerFinder and StreamSocket classes in the Windows Phone API. The following basic functionality is supported:-
  • Retrieve Name and Bluetooth Address of all paired devices
  • Establish a socket connection to a known address and port number or service Guid
  • Programmatically launch the Bluetooth Settings page to allow the user to toggle the radio state or pair with a device

InTheHand.Phone.Bluetooth.dll adds the following:-
  • Strongly typed ConnectAsync methods for Bluetooth
  • BluetoothDevicePicker
  • Common BluetoothService Guids
  • Barcode scanner sample

Last edited Dec 18, 2013 at 7:15 PM by PeterFoot, version 3


lseidman Feb 10, 2013 at 10:20 PM 
Any chance this can send commands to a device (e.g. Arduino)? Currently my code can connect to the Arduino successfully, but when I try to run await _socket.OutputStream.WriteAsync(buffer); Where buffer is a function that uses IBuffer and DataWriter but no luck for the device understanding or maybe not sending to the Arduino.

var buffer = TheBuffer();
await _socket.ConnectAsync(peer.HostName, serviceName);
await _socket.OutputStream.WriteAsync(buffer);

private IBuffer TheBuffer()
using (var dataWriter = new DataWriter())
dataWriter.UnicodeEncoding = UnicodeEncoding.Utf8;
return dataWriter.DetachBuffer();

Any ideas welcomed!