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

How to connect to obtain device info directly?

Topics: Bluetooth - Microsoft
Apr 15, 2015 at 2:45 PM
I need to connect to a device directly - via its MAC address - rather than the usual discovery/pairing approach. Once connected, I need to access all of the usual device's information (BluetoothDeviceInfo).

Is this possible?

So far I have the following, which appears to connect. I can't see how to obtain the device's info though, and I'm not even sure if I'm closing the connection correctly.
                    BluetoothClient client = new BluetoothClient();

                        BluetoothAddress address = BluetoothAddress.Parse(macAddress);
                        Guid serviceClass = BluetoothService.SerialPort;
                        BluetoothEndPoint ep = new BluetoothEndPoint(address, serviceClass);

                    catch (Exception ex)
                        if (client.Connected) client.Close();