Excellent project, but I will never use such an a chip to control sound, distortion always adds the more you add controls. IR code can also be found at AVRfreaks.net, I tried my best to tidy that code, ported this code to Crossworks as well:
http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=58645http://www.youtube.com/watch?v=ghSOHPLVSvwBut be careful, you write too much to the EEPROM and will end up with a broken AVR sooner or later. You better adopt another mechanism to save values at switch off, this is better and will save your EEPROM's life, trust me I had this situation before.
You could also think about something like this:
http://diyaudioprojects.com/Solid/DIY-Lightspeed-Passive-Attenuator/ Think about how to use a digital potentiometer to control these optocouplers, something like PGA and DS chips with OPA2134 as a buffer for the digital POT will be ok.
This project is also useful:
http://www.scienceprog.com/avr-based-tda7313-audio-processor-control/