Esempio n. 1
0
        // Creates a new instance of the NEC IR Receiver class
        internal NECReceiver(Cpu.Pin receiverPin)
        {
            _newPress = false;
            _lastTick = DateTime.Now.Ticks;

            _irPort = new InterruptPort(receiverPin, false, Port.ResistorMode.Disabled, Port.InterruptMode.InterruptEdgeBoth);

            _irPort.OnInterrupt += IrPortOnInterrupt;
            _irPort.EnableInterrupt();
        }