edited the sleep function, added commentary. we have to reconsider the
wake function. we could probably introduce it to the sleep function itself