G120 EINT1 Interrupt on RLP

Hi Guys, this has been a hard week trying to get the ENT1 RLP working on my G120 HRD.

I wondering if someone has some experience on it, so far I have it sort of working but not really well, it must be something easy that I’m missing.

I have the RLP code running nicely on my G120 until the interrupt signal is triggered (EINT1=P2.11) unsing a low signal on it, then the system halt with no messages or warnings. I think that it keeps running in unmanaged code.
After that when I set the input signal back to high the managed code continues running.

I have a working version of the header file for the 1788 MCU and an example from miniSun (http://www.thaieasyelec.net/archives/Manual/miniSUN7/Example_peripheral_for_miniSUN7.7z)

I have double checked all my registry addresses and the interrupt id in the processor datasheet against the header file (http://www.nxp.com/download/pip/LPC1788FET180/user_manual), everything match.

Also try to change the interrupt mode level/edge and low/active and the behavior is the same or worse, depending of the configuration sometimes it doesn’t return at all from the interrupt what make me thinks that maybe there is a hidden flag that is not cleared with the RLPext interrupt install function.

Maybe someone has a working example of how attach this interrupt, I have looked into the example on codeshare http://www.ghielectronics.com/community/codeshare/entry/219 but the header files and MCU are way differents.

Here you will find my project, there you will see a timer sending debug commands every 2 seconds with a managed counter and a unmanaged counter from the interrupt.

http://www.ghielectronics.com/community/codeshare/entry/724

Any help will be appreciated

Check this codeshare example:

http://www.tinyclr.com/codeshare/entry/366

This things happens when you has been working almost the whole night!

I found my mistake, I don’t know why I was thinking that 0x10 = (1 << 1)

Replaced the wrong bit set with (1 << 1) and everything works normally.

Well at least someone can use the code I shared to implement this easily, I will update the project with the fixed version.

@ architect thanks for pointing that example, I have already checked it. Unfortunately the processor and logic are different between the two MCU.

Wasn’t sure if you have seen it or not. Good you have found the bug!