To avoid overworking it's really important to be well rested and fed and not just live on caffeine. Listen to your body and know when it needs to rest and when it's just trying to procrastinate. And avoid crunch time as much as possible, since it can really drain you.
For being productive, to me the most important part is just allocating a block to do your work at 100% power. No planning, no distractions, no phone, maybe some music if it helps you get in the zone, just do what you have to do nonstop. Once you get the ball running even with such a small timeframe the productivity will skyrocket. Just one hour a day like this can bring huge results in the long run, but of course if you can put more time in you should.
Motivation is a tricky one. Of course, there is going to be a point in the project where you aren't going to be in love with it anymore. Here the most important part is discipline and keeping progress up, but most importantly remembering yourself that you're moving forward. Keeping a journal/blog of your progress is immensely useful, since it tracks the progress you're making. I find that i get the most unmotivated when I work hard and long hours and don't see a return. That's normal psychology, when you think about it: no one wants to put time and money in a bad investment. You just have to remind yourself that it's actually working out, slowly.
I keep a schedule. It's hard to follow at times, especially since I tend to overwhelm myself. But I'm not that rigid if I don't respect it, if
I know that I've been working hard.
Hope this was useful