Example #1
0
        private async void OnFoundAllNearbyDeviceForNow(object sender, EventArgs e)
        {
            m_messageOrchestrator = new BluetoothMessageOrchestrator(BluetoothMessageOrchestrator.Mode.Client);
            await m_messageOrchestrator.InitializeAsync();

            foreach (var device in m_deviceLocator.RemoteDevices)
            {
                var couldConnect = await m_messageOrchestrator.ConnectToServerAsync(device);

                if (couldConnect)
                {
                    break;
                }
            }
        }
Example #2
0
 public async Task CreateSession()
 {
     m_messageOrchestrator = new BluetoothMessageOrchestrator(BluetoothMessageOrchestrator.Mode.Server);
     await m_messageOrchestrator.InitializeAsync();
 }