Mikroelektronika MIKROE-350 Datenbogen

Seite von 526
Cf_Write_Init
Cf_Write_Byte
195
MIKROELEKTRONIKA
- SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Libraries
mikroBasic PRO for AVR
CHAPTER 6
Prototype
sub procedure Cf_Write_Init(dim address as longworddim sectcnt
as 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
sub procedure Cf_Write_Byte(dim data_ as 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
dim data_ as byte
...
data = 0xAA
Cf_Write_Byte(data)