Mikroelektronika MIKROE-742 데이터 시트

다운로드
페이지 532
Cf_Write_Init
Cf_Write_Byte
209
MIKROELEKTRONIKA
- SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Libraries
mikroPASCAL PRO for AVR
CHAPTER 6
Prototype
procedure Cf_Write_Init(address : dword; sectcnt : byte);
Returns
Nothing.
Description
Initializes CF card for writing.
Parameters : 
address
: the first sector to be prepared for writing operation. 
sectcnt
: number of sectors to be prepared for writing operation.
Requires
The corresponding MCU ports must be appropriately initialized for CF card. See
Cf_Init.
Example
// initialize compact flash for writing to sector 590
Cf_Write_Init(590, 1);
Prototype
procedure Cf_Write_Byte(data_ : byte) ;
Returns
Nothing.
Description
Writes a byte to Compact Flash sector buffer location currently pointed to by writing
pointers. These pointers will be autoicremented upon reading. When sector buffer is
full, its content will be transfered to appropriate flash memory sector.
Parameters : 
data_
: byte to be written. 
Requires
The corresponding MCU ports must be appropriately initialized for CF card. See
Cf_Init.
CF card must be initialized for writing operation. See Cf_Write_Init.
Example
var data_ : byte;
...
data := 0xAA;
Cf_Write_Byte(data);