Hi I’m facing an estrange behavior with my RLP code, I hope that anyone could help me out with this must be something easy.
I’ve installed a function on Timer2 of my G120HDR using RLP, it’s executing every 100ms.
This timer is just pulsing an output.
The problem is when I reset or power on the G120 the timer continues executing before the boot up of the MF and with a different frequency, I get 3900 pulses instead of 10 by second until my code invoke again the install of the timer 2.
Why the timer is not uninstalled after reset or power off?
How could I turn off the timer until the MF is loaded after a reboot?
Same thing is happening with my RLP interrupt on EINT1, it continues receiving signals after a reboot and before the MF get loaded.
For some reason the RLP code is still installed and start running in the lower layer after reset or reboot.
I will show you tomorrow my RLP code just in case that you want to try it.
I’m working on a G120HDR v1.1
Let me know if any workaround come to your mind.
Just to be clear, after a reset (using the reset ping) any installed interrupt on RLP should be cleared until it’s installed again right?
This is not happening with my board, I can see that something in the timer get reset because the frequency is changed but the timer function is still installed.
Code sits in RAM/SDRAM so that will still be there after reset, not after power up. This is normal, but then how come the ISR handler is still installed after reset!
We can try to improve this in next release but we need a small test setp so we can try this on our end please.
Gus, I did a more deep testing today with a scope.
I noticed that the port that I using to send the pulses out is labeled LCD Green0 (P1.20) and it boot up sending those pulses until I get my RLP code installed.
I had switched the signal to another pin (P3.25) that boot up in a low state and it works, so it’s not the timer function, I have to check if there is a way to set those default values for specific pins in the LPC_1788 manual, but I don’t think that there is an option to do that.
Something that I noticed too is, if there an error on the managed code the ISR are still installed and working, do you know how notify the RLP code when there is an unmanaged error on the managed code?
You could build a watchdog type thread, which is pulsed by the managed code. If the pulsing stops, then the watchdog thread could communicate to the RLP code that the managed side has stopped/died. There would be a RLP method to communicate the stopped condition.
@ Gus - I know that this is not currently available, but maybe a good addition to RLP would be to have a function that allows you to install a Soft Reboot Handler, internally it would be calling HAL_AddSoftRebootHandler.