When I feel like giving up something, I always take a rest for a short while. This gives me time to think about why I want to do this particular thing and remind myself of the determination. I believe we are demotivated because we try too hard and lose sight of our goal while pursuing it. Taking a break from what we are doing is helpful to let our mind calm down and bring fresh air to our goal. Also, we feel dull about working on something simply because the task got easy for us. When this happens, it is a good time to challenge yourself. Set a new goal and make it a little higher than before. That will boost you once again.