We strongly encourage users to use Package manager for sharing their code on Libstock website, because it boosts your efficiency and leaves the end user with no room for error. [more info]
Rating:
Author: dany
Last Updated: 2016-02-28
Package Version: 3.1.0.0
Category: Storage
Downloaded: 13770 times
Followed by: 6 users
License: MIT license
Several libraries for Fat16 and Fat32:
- Fat16Dir (findfirst, findnext) (only P18)
- Fat16DirLFN (Fat16Dir for long filenames) (only P18)
- Fat32_,1 Fat32_2; single and multiple Fat32 device(s) for P18, PIC24, dsPIC and PIC32
- IDE for P18, PIC24 and dsPIC.
Do you want to subscribe in order to receive notifications regarding "Fat" changes.
Do you want to unsubscribe in order to stop receiving notifications regarding "Fat" changes.
Do you want to report abuse regarding "Fat".
DOWNLOAD LINK | RELATED COMPILER | CONTAINS |
---|---|---|
1456660350_fat_mikropascal_pic.mpkg [5.33MB] | mikroPascal PRO for PIC |
|
1456660390_fat_mikropascal_pic24.mpkg [4.77MB] | mikroPascal PRO for dsPIC30/33 & PIC24 |
|
1456660423_fat_mikropascal_pic32.mpkg [4.75MB] | mikroPascal PRO for PIC32 |
|
1456660462_fat_mikrobasic_pic.mpkg [5.35MB] | mikroBasic PRO for PIC |
|
1456660490_fat_mikrobasic_pic24.mpkg [4.79MB] | mikroBasic PRO for dsPIC30/33 & PIC24 |
|
1456660524_fat_mikrobasic_pic32.mpkg [4.78MB] | mikroBasic PRO for PIC32 |
|
1456660551_fat_other_pic.zip [3.66MB] | Other PIC Compilers |
|
1456660581_fat_other_pic24.zip [3.41MB] | Other PIC24 Compilers |
|
1456660609_fat_other_pic32.zip [3.07MB] | Other PIC32 Compilers |
|
Libraries:
* Fat16 Directory and Long file names handling (only P18):
- Fat16Dir
- Fat16DirLFN
* Fat32 filesystem implementation (only P18, PIC24 and dsPIC):
- Fat32_1 - only one file in one directory - see short documentation - full documentation
- Fat32_2 - multiple files in multiple directories - see short documentation - full documentation
- Fat32_1_MD: same as Fat32_1, but more than one Fat32 device possible, still only one file in one directory per Fat32 device. Documentation.
- Fat32_2_MD: same as Fat32_2, but more than one Fat32 device possible. Documentation.
Examples: Fat32_Find_Example.zip, Fat32_Multi_File_Example.zip (only for Fat32_2), Fat32_Random_Access_Example.zip, Fat32_Sequential_Access_Example.zip, Fat32_1_md_SDMMC_USB_Stick_Example.zip and Fat32_2_md_SDMMC_USB_Stick_Example.zip.
Fat32 Documentation: Fat32 File System Specification, filename: "fatgen103.doc", and Fat32 structure information.
* IDE driver (only P18, PIC24 and dsPIC):
- IDE - IDE (harddisk) driver -
The zipfiles have the same content as the packages.
Have fun!
----------------------------------------------------------------------------------------------------------------------------------------------
2012-01-22: Version 2.0 published:
An extra version of the Fat32 library is added: Fat32_2, which is capable of handling more than one open file simultaneously (the files can be in different directories).
Additionally a "CopyFile" function has been added.
Have fun!
---------------------------------------------------------------------------------------------------------------------------------------------
2012-01-28: The Fat32_cf, Fat32_ide, Fat32_2.cf, fat32_2.ide and Ide libraries for PIC24 are added.
-------------------------------------------------------------------------------------------------------------------------------------------------
2012-06-08: The help section in the package and zip file has been updated.
------------------------------------------------------------------------------------------------------------------------------------------------
2012-07-23: Library version 2.100:
Only one version (hardware independant) of Fat32_1 and Fat32_2 exists from now onwards, the separate mmc, cf and IDE versions are gone.
All routines in the libraries also lost their "hardware" (e.g. "mmc_") prefix.
In return the using software must provide the "hardware dependancy" in the form of 2 routines:
function Fat32_Dev_Read_Sector (Sector: DWord; var Buffer: array[512] of byte): boolean; // returns true when successfull
function Fat32_Dev_Write_Sector(Sector: DWord; var Buffer: array[512] of byte): boolean; // returns true when successfull
I personally think this approach to construct the library is much better than the previous one (wich was simply a mistake...)
Have fun!
-------------------------------------------------------------------------------------------------------------------------------------------------
2012-08-01:
- Deleted an error in "MakeNewFile". (sorry for the possible inconvenience).
- Changed the signature and usage of "Fat32_Delete": the file needs not to be open before deletion. The name of the file to delete is required as function argument now.
-------------------------------------------------------------------------------------------------------------------------------------------------
2012-08-02: Changes are made to the "Fat32.." libraries:
Fat32_1:
Added the following routines:
------------------------------------------------------------------------------------------------------------------------------------------------
2012-08-05:
Fat32 and Fat32_2:
Added the routines "Fat32_RmDir_All", "Fat32_Delete_All" and "Fat32_Delete_Files"
------------------------------------------------------------------------------------------------------------------------------------------------
2012-08-16: Added extended documentation for the Fat32(_1 and_2) libraries. Also examples were added.
------------------------------------------------------------------------------------------------------------------------------------------------
2012-08-18: In the Fat32 and the Fat32_2 libraries: Changed the result of the Fat32_xxxSpace_GB routines to type real (too much rounding down errors otherwise).
------------------------------------------------------------------------------------------------------------------------------------------------
2012-08-29: made "Fat32_Read_File_Sector" faster (Fat32_1 and Fat32_2 libraries).
------------------------------------------------------------------------------------------------------------------------------------------------
2012-08-30: streamlined the Fat32_Read_sector and Fat32_Write_Sector procedures in the Fat32_1 and Fat32_2 libraries:
Added "Fat32_Seek_Sector" and "Fat32_Read_Sector"
Removed "Fat32_Read_File_Sector" and "Fat32_Write_File_Sector" (replaced by "Fat32_Read_Sector" and "Fat32_Write_Sector")
------------------------------------------------------------------------------------------------------------------------------------------------
2012-09-02: Added "Fat32_Append_Sector" to the "Fat32_1" and "Fat32_2" libraries.
-------------------------------------------------------------------------------------------------------------------------------------------------
2012-10-03:
- The "Fat32" library has been rename to "Fat32_1". This is done to avoid name clashes with the Fat32 mE library in the IDE's library manager.
- The "ReadBuffer" routine in the Fat32_1 and Fat32_2 libraries is made faster for 512 byte reads on a file sector boundary.
------------------------------------------------------------------------------------------------------------------------------------------------
2012-11-12: The microBasic package(s) ha(s)(ve) been added.
Only the .mcl files are available as "library" files: they are copied from the mikroPascal version (the mP and mB .mcl files are compatible - luckely - ).
If you want to see some sources: look into the mP versions.
The example files are still in mP, not in mB. (I do not have an mB licence, so I can not compile them).
Some of the helpfiles are also still referring to mP, but all library "interfaces" are available in the mB language.
-------------------------------------------------------------------------------------------------------------------------------------------------
2012-12-07: Fat32_2 has been updated, the file is now compiled with the SSA switched on (gave a problem when used with mBasic).
------------------------------------------------------------------------------------------------------------------------------------------------
2013-01-26: Replaced "Delay_ms" and "Delay_us" by routines available in the Delays lib.
"Delay_ms"
and "Delay_us" are inline routines and cannot be used in libraries if
they are to be used without source (e.g. non Pascal compilers).
-------------------------------------------------------------------------------------------------------------------------------------------------
2013-02-07: Made the dsPIC packages available.
--------------------------------------------------------------------------------------------------------------------------------------
2013-10-01: Added the "Fat32_Format" routine to the Fat32_1 and Fat32_2 units.
Those units now use the units "SDMMC_Utils" and "BitUtils" (see http://www.libstock.com/projects/view/39/utilities) for the Fat32_Format routine.
The Fat32_Format routine formats the medium from scratch in contrary to "Fat32_QuickFormat".
---------------------------------------------------------------------------------------------------------------------------------------
2013-10-05: Changed the "Examples": deleted a "delay_ms(1000);" in the beginning of their main file to prevent weird problems with the initialisation of SD/MMC cards.
---------------------------------------------------------------------------------------------------------------------------------------
2013-10-08:
- Added some extra checks to make sure Fat32_Init detects a Fat32 volume (and only that) properly.
- Added the creation of the FAT entries 0,1 and 2 to the Fat32_Format routine (was mistakenly ommitted).
- Adapted the "Calculate Sectors per cluster" code according to the findings of Serkan (thanks!)
2013-10-09: - Removed an error in the "Fat32_Format" routine.
----------------------------------------------------------------------------------------------------------------------------------------
2014-03-13: The mikroBasic files and zip files have been updated. All mB sources are present now (not tested if compilable though).
2014-10-24: Added both in Fat32_1 and Fat32_2 the routine "Fat32_MkDir_ChDir_FP". It changes the current directory to the lowest level in the directory path specified, while in the mean time creating missing directories.
04-11-2014:
- Made "MakeNewFile" more time efficient (better short file name generation)
- Changed the usage of "StrAppendPre": only used on a non empty string (string lib problem)
05-11-2014: Changed the routine "MakeShortFileName" to be more efficient (code & time) and more according the Microsoft specification.
2014-12-25: Added the Fat32_1_MD library: is the same as Fat32_1 (only one open file per Fat32 device at one time), but now capable of handling more than one Fat32 device (e.g. SDMMC card and USB Stick) simultaneously.
An example of its usage can be found in the examples folder: project Fat32_1_dw_SDMMC_USB_Stick_Example.zip.
The example is for PIC24, since it shows the usage of SDMMC card and USB stick together. The latter needs the USB host library.
The documentation is not adapted yet, and the Fat32_2_MD library is under construction.
2014-12-27, Version 3.0: - simplified the interface of "Fat32_init" and "Fat32_QuickFormat" in library "Fat32_2"
- Added library "Fat32_2_MD", capable of handling multiple Fat32 devices, with multiple files/directories in each device. The documentation is adapted.
2015-01-26: Replaced the mB files: all mB files are compilable now (which e.g. means that all "with" statements are dealt with). I could however not link and test the libraries (no mB licence).
2015-02-17: Added the mP for PIC32 libraries. Only compiled, not tested.
2015-03-23: added now in the documentation the circuit diagram how to use more than one SDMMC card toghether with the Fat_x_MD libarries.
-----------------------------------------------------------------------------------------------------------------------------------
2016-02-28: Version 3.1: Added the routine "Fat32_Truncate".