Beispiel #1
0
        public void CommandSetSourceTest()
        {
            Address zoneAddress = new Address(_deviceId, 2);                      // Zone 2

            _protDriver.CommandSetSource(zoneAddress, new Address(_deviceId, 5)); // Source 5
            Thread.Sleep(2000);                                                   // give control to worker thread

            Assert.IsTrue(_nuvoTelegramMock.TelegramList.Count >= 1);
            Assert.AreEqual(true, _nuvoTelegramMock.TelegramList.Contains("Z02SRC5"));
        }
Beispiel #2
0
        public void SimulatorCommandSetSourceTest()
        {
            NuvoEssentiaProtocolDriver target        = new NuvoEssentiaProtocolDriver();
            Communication communicationConfiguration = new Communication("SIM", 9600, 8, 1, "None"); // Create Simulator

            target.Open(ENuvoSystem.NuVoEssentia, _deviceId, communicationConfiguration, null);
            target.onCommandReceived += new ProtocolCommandReceivedEventHandler(target_onCommandReceived);

            Address zoneAddress = new Address(_deviceId, 2);                    // Zone 2

            target.CommandSetSource(zoneAddress, new Address(_deviceId, 5));    // Source 5
        }