Пример #1
0
 public void ConnectToInvalidBluetoothID()
 {
     System.Threading.Tasks.Task.Run(async() =>
     {
         Crazyflie c            = new Crazyflie("BluetoothLE#BluetoothLE00:00:00:00:00:00-00:00:00:00:00:00");
         CrazyflieStatus status = await c.InitializeAsync();
         Assert.IsTrue(status == CrazyflieStatus.InvalidDeviceId);
     }).GetAwaiter().GetResult();
 }
Пример #2
0
        public void InitializeTest()
        {
            IList <string> devices = null;

            System.Threading.Tasks.Task.Run(async() =>
            {
                devices = await Crazyflie.ScanInterfacesAsync();
                Assert.IsTrue(devices.Count >= 1);
                Crazyflie c            = new Crazyflie(devices[0]);
                CrazyflieStatus status = await c.InitializeAsync();
                Assert.IsTrue(status == CrazyflieStatus.Success);
            }).GetAwaiter().GetResult();
        }