Much of what I am doing these days takes a couple of hours to spin up, so I don't have any ideas for you here. Maybe find a way talking with your friend about your need for long stretches of uninterrupted time. Already mentioned here is Paul's very relevant essay http://www.paulgraham.com/makersschedule.html.
back
1 comments
Yes, this sounds like an occasion for social optimization rather than technical. See whether you and your friends can agree to a schedule that leaves you with a good block of uninterrupted time. Perhaps they would prefer to do things in the afternoon, leaving you the mornings free. Or they may be earlybirds, leaving you the evenings. This latter might be hard, though, as your work time would come at the end of the day and you might be tapped out.
Another recommendation might be meditation, rather than additional overt effort. It would take practice, but 5 to 10 minutes of quieting the mind might allow the context you want regain to emerge more quickly. I'm not too experienced in this personally, however, although I do find lost context returning to me once my physical environment quietens.