Add fat12 lib

This commit is contained in:
2025-09-24 00:46:50 +02:00
parent 9bd84390d0
commit bdb2fce4db
2 changed files with 153 additions and 0 deletions

15
fat12.h Normal file
View File

@@ -0,0 +1,15 @@
#pragma once
/*
* Arguments:
* - fat_addr: 1 KiB
* - rootdir_addr: 3.5 KiB
*/
int fat12_init(void* fat_addr, void* rootdir_addr);
/*
* Returns:
* -4 if file is not found
* -5 if there is a disk error
*/
int fat12_readfile(const char* name, void* addr);