(I am supposing this is for the TI-Nspire)
Could you describe further what you would like to do? Setting an an interrupt handler is probably not easy, perhaps an inline delay could be a better solution depending on what you want to do.
I have a working sleep() routine I should commit to the Ndless SVN.