Now and then someone ask's how to use avrstudio and a more direct approach between their code and the atmega micro used in the arduino boards, so I think that this very well done collection of tutorials should be shown in a sticky post in this forum:
http://www.smileymicros.com/index.php?module=pagemaster&PAGE_user_op=view_page&PAGE_id=70&MMN_position=117:117
This and all the other Workshops teach a lot about programming and clever tricks that help when we are using a micro-controller like the atmega.