17 lines
523 B
C
17 lines
523 B
C
|
#ifndef _FAT32_H
|
||
|
#define _FAT32_H
|
||
|
#include <stdint.h>
|
||
|
|
||
|
#define FAT32_MAX_FILENAME 11
|
||
|
#define FAT32_ATTR_DIRECTORY 0x10
|
||
|
|
||
|
int32_t fat32_init(int32_t drive); /* 0 = primary master */
|
||
|
int32_t fat32_list_root(void);
|
||
|
int32_t fat32_read_file(const char *name, uint8_t *buffer, uint32_t max_len);
|
||
|
int32_t fat32_write_file(const char *name, const uint8_t *buffer, uint32_t len);
|
||
|
int32_t fat32_create_file(const char *name);
|
||
|
int32_t fat32_create_directory(const char *name);
|
||
|
int32_t fat32_change_directory(const char *name);
|
||
|
|
||
|
#endif
|