[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[avr-libc-dev] ADCW and ADC 16-bit I/O definitions
From: |
Marek Michalkiewicz |
Subject: |
[avr-libc-dev] ADCW and ADC 16-bit I/O definitions |
Date: |
Sat, 8 Feb 2003 23:10:03 +0100 (CET) |
Hi,
I've just noticed this in include/avr/iom128.h:
#define ADCW _SFR_IO16(0x04) /* for backwards compatibility */
#define ADC _SFR_IO16(0x04)
The reason why ADC was originally renamed to ADCW is that there is
an ADC (add with carry) assembler instruction (if written in upper
case, and used in a preprocessed asm source which includes the I/O
defines). Similar confusion was probably the reason why Atmel has
renamed the UART overrun error flag from OR to DOR...
So, I'd suggest to prefer the use of ADCW ('W' stands for Word)
and ask Atmel to rename ADC to ADCW in their datasheets :)
BTW, has anyone had any success opening the latest mega128 datasheet?
http://www.atmel.com/dyn/resources/prod_documents/doc2467.pdf
It appears password-protected to me (tried both acroread-4.05 and
xpdf-1.01) - just a word of warning, especially for dialup users
(~3MB download).
Marek
- [avr-libc-dev] ADCW and ADC 16-bit I/O definitions,
Marek Michalkiewicz <=