I use the following points to motivate myself whenever I feel down. Hope it helps others.
1. Follow a path to achieve your goal and stick to it.
2. Never quit what you have started.
3. Find friends or partners of similar interest.
4. Learn how to teach yourself.
5. Do something which is more in line with your talent and interest.
6. Dig deep in the subject which you find interesting.
7. No risk no game.
If you follow the above points to the core then you will never feel down and out. Remember you can be your biggest enemy so stay focused on the work and you will never be lost