Advertisement
Eeems

Untitled

Jun 11th, 2011
169
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. Basic FAT type filesystem for now. Maybe move on to journaling later
  2. Types of filesystem objects:
  3. Directories
  4. Files
  5. Symlinks
  6. Directory Format:
  7. db FILE_DIRECTORY
  8. db "Name can be any length",0
  9. ; files
  10. File Format in FAT:
  11. db FILE_FILE
  12. db "Name can be any length",0
  13. dw POINTER_TO_DATA
  14. dw LENGTH_OF_DATA
  15. File Format in Flash:
  16. db "Name can be any lenght",0
  17. dw LENGTH_OF_DATA
  18. ;Data
  19. Symlink Format:
  20. db FILE_SYMLINK
  21. db "Name can be any length",0
  22. db "path to file/folder",0
  23.  
  24. The extra copy of the FAT header in the files data is in case of FAT corruption, you still know that there is a file and what it is called.
  25.  
  26. Possible FILE_ types:
  27. FILE_START <- start of the fat
  28. FILE_NULL <- nothing here remove on next fat cleanup
  29. FILE_DELETED <- this file has been deleted remove on garbage collect
  30. FILE_FILE <- standard file
  31. FILE_DIRECTORY <-directory header
  32. FILE_END_DIRECTORY <-end of a directory entry
  33. FILE_SYMLINK <= link to a file/directory
  34. FILE_END <= end of the FAT
  35.  
  36. could change.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement