public void Start()
        {
            AllJoynBusAttachment bus = new AllJoynBusAttachment();

            bus.AuthenticationMechanisms.Add(AllJoynAuthenticationMechanism.SrpAnonymous);

            _consumer = new GarageDoorConsumer(bus);

            _watcher        = new GarageDoorWatcher(bus);
            _watcher.Added += _watcher_Added;
            _watcher.Start();
            GarageDoorState = -1;
        }
Exemplo n.º 2
0
        private void MainPage_Loaded(object sender, RoutedEventArgs e)
        {
            AllJoynBusAttachment bus = new AllJoynBusAttachment();

            bus.AuthenticationMechanisms.Add(AllJoynAuthenticationMechanism.SrpAnonymous);

            _producer         = new GarageDoorProducer(bus);
            _producer.Service = new GarageDoorService();
            _producer.Start();
            _timer = new Timer(TimerCallBack, null, 10000, Timeout.Infinite);

            _watcher        = new GarageDoorWatcher(bus);
            _watcher.Added += _watcher_Added;
            _watcher.Start();
        }
Exemplo n.º 3
0
        private void MainPage_Loaded(object sender, RoutedEventArgs e)
        {
            AllJoynBusAttachment bus = new AllJoynBusAttachment();
            bus.AuthenticationMechanisms.Add(AllJoynAuthenticationMechanism.SrpAnonymous);

            _producer = new GarageDoorProducer(bus);
            _producer.Service = new GarageDoorService();
            _producer.Start();
            _timer = new Timer(TimerCallBack, null, 10000, Timeout.Infinite);

            _watcher = new GarageDoorWatcher(bus);
            _watcher.Added += _watcher_Added;
            _watcher.Start();

            
        }
        public void Start()
        {
            AllJoynBusAttachment bus = new AllJoynBusAttachment();
            bus.AuthenticationMechanisms.Add(AllJoynAuthenticationMechanism.SrpAnonymous);

            _consumer = new GarageDoorConsumer(bus);
            
            _watcher = new GarageDoorWatcher(bus);
            _watcher.Added += _watcher_Added;
            _watcher.Start();
            GarageDoorState = -1;

        }