Hi,
I have recently purchased a Netduino plus 2 to use as a hub for a set of wireless humidity and temperature sensors that communicate using an NRF24L01P radio module.
I am in the middle of developing a class lib for the radio module. The issue that I have is that the interrrupt is not firing at all. I did some digging on the forum but I have yet to find any thing that could indicate an issue.
_radio = new Nrf24L01P(SPI_Devices.SPI1, Pins.GPIO_PIN_D0, Pins.GPIO_PIN_D1, Pins.GPIO_PIN_D2) { TransmitAddress = AppConfiguration.Instance.RadioAddress, Channel = AppConfiguration.Instance.RadioChannel, Mode = Mode.Transmitter };
The interrupt line from the device is connected to Pins.GPIO_PIN_D2.
The Nrf24L01P initalises the interrupt pin in the following way, only relevent code shown:
public Nrf24L01P(SPI.SPI_module spi, Cpu.Pin chipSelectPin, Cpu.Pin chipEnablePin, Cpu.Pin interruptPin) { _interruptPin = new InterruptPort(interruptPin, false, Port.ResistorMode.PullUp, Port.InterruptMode.InterruptEdgeLow); _interruptPin.OnInterrupt += HandleInterrupt; ..... }
To trigger an interrupt I perform the following:
while (true) { _radio.Transmit(new byte[] {0,1,2,3,4},true); Thread.Sleep(1000); }
This should cause an interrrupt when the packet send retry is exhausted, there is no receive radio to ack the sent data.
The hardware wiring is pretty straight forward so I do not believe that this is an issue. I have verified the signal levels/connectivity as much as I can with a multimeter. I dont have a scope that I can use. I am pretty familiar with the characteristics of the radio module as I have built a sensor node with an AVR and it is functioning correctly.
I would like to know is there something I am overlooking wrt how the netduino/MCLR handles and raises interrupts that could cause this behaviour.
Thanks in advance