First, make a trip to the vet to be sure there isn't a serious health problem involved. Your dog may be cold and shivering, if so, get a blanket. Or the dog may be dehydrated and having trouble with muscle cramps. Be sure the dog is getting plenty of water and quality food. If the dog gets lots of exercise and is just tired, try giving it a massage on its legs and see if that works.