Long answer... hard slog and forcing oneself often accomplishes as much, if not more, than motivation. Still, I still frequently suffer total motivation failure.
Oddly, when I AM motivated to do something it can become more difficult as I end up setting impossibly high standards for myself that I can't meet and so end up paralysed with the inability to do anything - because it won't be good enough.
Another problem is that I am a person who has at least ten 'cool' ideas a day and my motivation frequently switches from whatever I SHOULD be focussing on to something else from the scattershot concept firing range that is the interior of my skull.
What few little tricks I've found mostly revolve around giving myself little rewards if I manage to do X. It's surprising how effective that can be.