Error compiling again!

(a) don't use tone (not ideal)
(b) modify the IR library to use a different timer (not too difficult)

Which arduino do you have? (Mega, Uno, Leonardo etc.)