> From: Dave Hylands > > .... > The reason that writing a 1 to it clears it is because if you write a > 1 to some other bit in the same register, you're writing a zero to all > of the other bits. ????? I assume when one writes a 1 to a register bit position one is ORing it into the register such as: reg |= 0x20; and, clearing a bit ... reg &= ~0x20; so I don't understand your statement that "if you write a 1 to some other bit in the same register, you're writing a zero to all of the other bits". I assume you're saying something like: reg = 0x02; to clear the 0x20 bit (bit position 5) but I wouldn't think that that would be normal practice ... ... but, hey, I'm new here so I could be wrong :-) Cheers, Chuck Hackett "Good judgment comes from experience, experience comes from bad judgment" 7.5" gauge Union Pacific Northern (4-8-4) 844 http://www.whitetrout.net/Chuck
Message
RE: [AVR-Chat] Re: documentation of timer interrupts vs bugs
2005-04-21 by Chuck Hackett
Attachments
- No local attachments were found for this message.