Motivation can come from many sources, not only grading, e.g. individual encouragement, exciting applications, day-to-day relevance, interest shown by peers. Also students can just be intrinsically motivated.
It may come in different styles. But what do you do with students who don’t have motivation beyond grading/punishment? Some people just do not have motivation unless somebody standing by them with a stick.