Atmel CAVR-4 Manual De Usuario

Descargar
Página de 323
CAVR-4
206
Descriptions of extended keywords
AVR® IAR C/C++ Compiler
Reference Guide
_ _ext_io
Controls the storage of data objects in data memory space.
The 
_ _ext_io
 memory attribute implies that objects are 
_ _no_init
 and volatile, and 
allows objects to be accessed by use of the special I/O instructions in the AVR 
microcontroller.
Your application may access the AVR I/O system by using the memory-mapped internal 
special function registers (SFRs). To access the AVR I/O system efficiently, the 
_ _ext_io
 memory attribute should be included in the code.
_ _far
Controls the storage of data objects in data memory space.
The 
_ _far
 memory attribute overrides the default data storage of variables given by the 
selected memory model.
Note: When the 
_ _far
 memory attribute is used, the object cannot cross a 64-Kbyte 
boundary. Arithmetics will only be performed on the two lower bytes, except 
comparison which is always performed on the entire 24-bit address.
_ _farflash
Controls the storage of data objects in flash (code) memory space.
The 
_ _farflash
 memory attribute places objects in flash (code) memory.
Note that it is preferable to declare flash objects as 
const
. The 
_ _farflash
 memory 
attribute is only available for AVR chips with at least 64 Kbytes of flash memory.
The index type uses 16-bit arithmetic, which implies that a 64-Kbyte boundary cannot 
be crossed.
Note: When the 
_ _farflash
 memory attribute is used, the object cannot cross a 
64-Kbyte boundary. Arithmetics will only be performed on the two lower bytes, except 
comparison which is always performed on the entire 24-bit address.
Address range
Max object size
Pointer size
Memory space
0x100-0xFFFF
4 bytes (32 bits)
Pointers not allowed Data
Table 56: Near address ranges
Address range
Max object size
Pointer size
Memory space
0-0xFFFFFF
 (16 Mbytes)
65535 bytes
24 bits
Data
Table 57: Far address ranges
Address range
Max object size
Pointer size
Memory space
0-0x7FFFFF
 (8 Mbytes)
65535 bytes
24 bits
Code
Table 58: Farflash address ranges