The poet, Robert Lee Brewer asked a number of other poets for ideas on keeping on writing when they just didn't feel like it, and has collated the answers into an interesting blog post.
I like this answer from Todd Dillard particularly because it's true - sometimes you just need to go and do something different, although I am still growing out a really really bad haircut from last year so I might skip that one. I'm interested in the anthology of favourite poets though, a mixed tape of words:
I'm much more conscientious about my writing when I'm NOT writing than when I am, so I usually try to shift my focus away from that internal, absent impetus into something different, enjoyable, or productive. This usually means a new haircut, delightfully awful genre fiction, and editing. If that doesn't work, I create projects for myself, like painting, developing a mix tape, or creating a little Great(ness) anthology of my favorite poems from my favorite poets. When you're stuck in a writing slump, it's easy to focus on that missing creativity energy within you without realizing it's an entirely false paradigm. It's more likely that energy’s still in you, it's just moved somewhere else in you. Find it again and reign it in, or just go with it for a while, it might be leading you somewhere unexpected.