We were thinking about this last night... when we couldn't sleep. Do you ever head into the kitchen instead of reading a book or turning on the TV? We realize that cooking while groggy might be dangerous. (Maybe steer clear of the chef's knife.) But cooking a simple meal in a quiet kitchen can be soothing.
Our other thought was that, if what's keeping you up is the thought of having to make six dozen cupcakes the next day for a school bake sale, getting started might actually alleviate the stress and help your mind rest.