Thats what I think, a really simple thing, Thank You, it works! resp_sleep=sleep(INTERRUPT,CHANGE,SLEEP_TIME); and then hust a simple if resp_sleep.... Thanks!