: You have to buy an Atmel microcontrollers programmer
That's one option, but if you know a thing or two about electronics you can
save a load of money by making your own programmer. There are really simple
schematics out there if you search for "atmega16 programmer" on Google.
I've used WinAVR for compiling and PonyProg for writing the hex file into
the controller, but use whatever works for you