Пример #1
0
        private static void Controller_DiscoveryProgress(object sender, DiscoveryProgressEventArgs args)
        {
            Console.WriteLine("DiscoveryProgress {0}", args.Status);
            switch (args.Status)
            {
            case DiscoveryStatus.DiscoveryStart:
                break;

            case DiscoveryStatus.DiscoveryEnd:
                break;
            }
        }
Пример #2
0
        private void Controller_DiscoveryProgress(object sender, DiscoveryProgressEventArgs args)
        {
            //var controller = (sender as ZWaveController);
            switch (args.Status)
            {
            case DiscoveryStatus.DiscoveryStart:
                OnInterfacePropertyChanged(this.GetDomain(), "1", "Z-Wave Controller", "Controller.Status", "Discovery Started");
                break;

            case DiscoveryStatus.DiscoveryEnd:
                OnInterfacePropertyChanged(this.GetDomain(), "1", "Z-Wave Controller", "Controller.Status", "Discovery Complete");
                OnInterfaceModulesChanged(this.GetDomain());
                break;
            }
        }
Пример #3
0
        protected void OnDiscoveryStatusChanged(object sender, DiscoveryProgressEventArgs args)
        {
            switch (args.Status)
            {
            case DiscoveryStatus.DiscoveryEnd:
                UpdateNodeCache();
                if (_startingSemaphor != null)
                {
                    _startingSemaphor.Release();
                    _startingSemaphor = null;
                }
                break;

            case DiscoveryStatus.DiscoveryError:
                OnError?.Invoke(this);
                break;

            case DiscoveryStatus.DiscoveryStart:
            default:
                break;
            }
        }