I did some more tests for the FTP problem, but without any luck. Windows firewall and the antivirus are disabled, AFAIK. I gave a try with Filezilla, using passive mode, with no results. I'm not really interested in this thing, it is certainly this notebook's fault.
PIT issue:
I tested your code and it does the same as mine, eg. the test_nmi function is executed only once.
I experimented with other PITs (0,2,3), same thing.
When I reconfigure the PIT every time , putting a fnConfigurePIT() call in the handler, it works as it should, periodically.
This thing is not easy to debug since I'm not able to place breakpoints in kinetis.c. Well, I place them but I only get a blue dot without the check mark which appears in breakpoints elsewhere.
From an Eclipse FAQ:
What does the checkmark next to the breakpoint represent?
The checkmark next to a breakpoint indicates that the debugger has resolved the
breakpoint and will be hit by the debugger. If the breakpoint does not have a checkmark,
the debugger will not hit it.
Not very helpfull.
Thanks again.