Datasheet

FLASH_Read_Bytes
FLASH_Read_Word
279
MIKROELEKTRONIKA - SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Libraries
mikroC PRO for AVR
CHAPTER 6
Prototype
// for MCUs with 64kb of Flash memory or less
void FLASH_Read_Bytes(unsigned int address, char *buffer,
unsigned NoBytes);
// for MCUs with Flash memory larger than 64kb
void FLASH_Read_Bytes(unsigned long address, char *buffer,
unsigned NoBytes);
Returns Nothing.
Description
Reads number of data bytes defined by NoBytes parameter from the specified
address in Flash memory to varibale pointed by buffer.
Requires Nothing.
Example
// for MCUs with Flash memory larger than 64kb
const long F_ADDRESS = 0x200;
unsigned int dat_buff[32];
...
FLASH_Read_Bytes(F_ADDRESS,dat_buff, 64);
Prototype
// for MCUs with 64kb of Flash memory or less
char FLASH_Read_Word(unsigned int address);
// for MCUs with Flash memory larger than 64kb
char FLASH_Read_Word(unsigned long address);
Returns Returns data word from Flash memory.
Description Reads data from the specified address in Flash memory.
Requires Nothing.
Example
// for MCUs with Flash memory larger than 64kb
unsigned long tmp;
...
tmp = Flash_Read(0x0D00);
...