Here is my approach to earning badges:
I just keep using the site, ask questions, answer questions, vote on stuff I like, edit, flag, ... and much much more.
Over time badges came in, one after the other. Mostly they were a real surprise. I had to look up what I got them forto look up what I got them for. For some of them I did not even know they existed. Some were introduced later and these were awarded to a lot of people all at the same time.
Only rarely I deliberately changed a bit of my behaviour in order to earn that badge: Altruist, Sportsmanship and Vox Populi are such examples.
But each except Tumbleweed made me a bit happy. I believe this is the main purpose of badges.