Mikroelektronika MIKROE-350 数据表

下载
页码 526
204
MIKROELEKTRONIKA
- SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Libraries
mikroBasic PRO for AVR
CHAPTER 6
Description
Note: Long File Names (LFN) are not supported. 
Requires
CF card and CF library must be initialized for file operations. See Cf_Fat_Init.
Example
program
'-------------- Try to create a swap file with archive atribute,
whose size will be at least 1000 sectors.
'               If it succeeds, it sends the No. of start sec-
tor over USART
dim size as longword
...
main:
...
size = Cf_Fat_Get_Swap_File(1000, "mikroE.txt", 0x20)
if size then
UART1_Write(0xAA)
UART1_Write(Lo(size))
UART1_Write(Hi(size))
UART1_Write(Higher(size))
UART1_Write(Highest(size))
UART1_Write(0xAA)
end if
end.
Bit
Mask
Description
0
0x01
Read Only
1
0x02
Hidden
2
0x04
System
3
0x08
Volume Label
4
0x10
Subdirectory
5
0x20
Archive
6
0x40
Device (internal use only, never found on disk)
7
0x80
Not used