It is a truth universally accepted that if you talk to cashiers like they are actually people and not human-looking cash registers, you'll get great service...and a smile.
Well...it may not be universally accepted...but it should be.
Seriously, the next time you are in the check out line, remember that the person ringing you up is actually a person. Look at them. Smile. Speak. And when you do, make it something nice.