Esempio n. 1
0
        //--//

        static PowerState()
        {
            PowerStateEventProcessor psep = new PowerStateEventProcessor();
            PowerStateEventListener  psel = new PowerStateEventListener();

            Microsoft.SPOT.EventSink.AddEventProcessor(EventCategory.SleepLevel, psep);
            Microsoft.SPOT.EventSink.AddEventListener(EventCategory.SleepLevel, psel);
            Microsoft.SPOT.EventSink.AddEventProcessor(EventCategory.PowerLevel, psep);
            Microsoft.SPOT.EventSink.AddEventListener(EventCategory.PowerLevel, psel);
        }
Esempio n. 2
0
        //--//

        static PowerState()
        {
            PowerStateEventProcessor psep = new PowerStateEventProcessor();
            PowerStateEventListener psel = new PowerStateEventListener();

            Microsoft.SPOT.EventSink.AddEventProcessor(EventCategory.SleepLevel, psep);
            Microsoft.SPOT.EventSink.AddEventListener(EventCategory.SleepLevel, psel);
            Microsoft.SPOT.EventSink.AddEventProcessor(EventCategory.PowerLevel, psep);
            Microsoft.SPOT.EventSink.AddEventListener(EventCategory.PowerLevel, psel);
        }