A yawn may indicate anticipation or stress, too.
Your dog may yawn repeatedly when he's waiting in the vet's office as a way of dealing with nervousness.
Sometimes dogs yawn in anticipation of something enjoyable, such as a walkthis is a way of controlling his enthusiasm.