johnwasser:
Try:#define iroff TCCR1A &= ^(1<<COM1A0);The '^' operator is the binary inversion. It turns the 1 bit to a 0 and all the 0 bits to 1s.
The AND operator '&' then leaves anything ANDed with a 1 bit unchanged and anything ANDed with a 0 bit set to 0.
Thanks! I see why what I was doing is wrong. I understand the thinking of flipping the bit and AND the whole byte to preserve the other bits, but get this error using your snippet:
/home/johnny/Dropbox/Arduino/IR Voter/ATTiny841_Tx_Ver2/ATTiny841_Tx_Ver2.ino:37:3: note: in expansion of macro 'iroff'
iroff;
^
exit status 1
expected primary-expression before '^' token