From e4d2b4c30d939ee139f4c0be33f7f85a8ed39c89 Mon Sep 17 00:00:00 2001 From: batt Date: Sat, 26 Mar 2011 08:43:59 +0000 Subject: [PATCH] Set the correct svn:eol-style=native property, please ignore. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4811 38d2e660-2303-0410-9eaa-f027e97ec537 --- bertos/fs/fatfs/00readme.txt | 192 +++++++++++++++++------------------ doc/chm-builder.py | 80 +++++++-------- doc/chm-toc-modifier.py | 88 ++++++++-------- doc/tag-filter.py | 38 +++---- 4 files changed, 199 insertions(+), 199 deletions(-) diff --git a/bertos/fs/fatfs/00readme.txt b/bertos/fs/fatfs/00readme.txt index f38a9587..0e06c20b 100644 --- a/bertos/fs/fatfs/00readme.txt +++ b/bertos/fs/fatfs/00readme.txt @@ -1,96 +1,96 @@ -FatFs/Tiny-FatFs Module Source Files R0.07a (C)ChaN, 2009 - - -FILES - - ff.h Common include file for FatFs and application module. - ff.c FatFs module. - diskio.h Common include file for FatFs and disk I/O module. - diskio.c Skeleton of low level disk I/O module. - integer.h Alternative type definitions for integer variables. - option Optional external functions. - - Low level disk I/O module is not included in this archive because the FatFs - module is only a generic file system layer and not depend on any specific - storage device. You have to provide a low level disk I/O module that written - to control your storage device. - - - -AGREEMENTS - - FatFs module is an open source software to implement FAT file system to - small embedded systems. This is a free software and is opened for education, - research and commercial developments under license policy of following trems. - - Copyright (C) 2009, ChaN, all right reserved. - - * The FatFs module is a free software and there is NO WARRANTY. - * No restriction on use. You can use, modify and redistribute it for - personal, non-profit or commercial use UNDER YOUR RESPONSIBILITY. - * Redistributions of source code must retain the above copyright notice. - - - -REVISION HISTORY - - Feb 26, 2006 R0.00 Prototype - - Apr 29, 2006 R0.01 First release. - - Jun 01, 2006 R0.02 Added FAT12. - Removed unbuffered mode. - Fixed a problem on small (<32M) patition. - - Jun 10, 2006 R0.02a Added a configuration option _FS_MINIMUM. - - Sep 22, 2006 R0.03 Added f_rename. - Changed option _FS_MINIMUM to _FS_MINIMIZE. - - Dec 11, 2006 R0.03a Improved cluster scan algolithm to write files fast. - Fixed f_mkdir creates incorrect directory on FAT32. - - Feb 04, 2007 R0.04 Supported multiple drive system. (FatFs) - Changed some APIs for multiple drive system. - Added f_mkfs. (FatFs) - Added _USE_FAT32 option. (Tiny-FatFs) - - Apr 01, 2007 R0.04a Supported multiple partitions on a plysical drive. (FatFs) - Fixed an endian sensitive code in f_mkfs. (FatFs) - Added a capability of extending the file size to f_lseek. - Added minimization level 3. - Fixed a problem that can collapse a sector when recreate an - existing file in any sub-directory at non FAT32 cfg. (Tiny-FatFs) - - May 05, 2007 R0.04b Added _USE_NTFLAG option. - Added FSInfo support. - Fixed some problems corresponds to FAT32. (Tiny-FatFs) - Fixed DBCS name can result FR_INVALID_NAME. - Fixed short seek (0 < ofs <= csize) collapses the file object. - - Aug 25, 2007 R0.05 Changed arguments of f_read, f_write. - Changed arguments of f_mkfs. (FatFs) - Fixed f_mkfs on FAT32 creates incorrect FSInfo. (FatFs) - Fixed f_mkdir on FAT32 creates incorrect directory. (FatFs) - - Feb 03, 2008 R0.05a Added f_truncate(). - Added f_utime(). - Fixed off by one error at FAT sub-type determination. - Fixed btr in f_read() can be mistruncated. - Fixed cached sector is not flushed when create and close without write. - - Apr 01, 2008 R0.06 Added f_forward(). (Tiny-FatFs) - Added string functions: fputc(), fputs(), fprintf() and fgets(). - Improved performance of f_lseek() on move to the same or following cluster. - - Apr 01, 2009, R0.07 Merged Tiny-FatFs as a buffer configuration option. - Added long file name support. - Added multiple code page support. - Added re-entrancy for multitask operation. - Added auto cluster size selection to f_mkfs(). - Added rewind option to f_readdir(). - Changed result code of critical errors. - Renamed string functions to avoid name collision. - - Apr 14, 2009, R0.07a Separated out OS dependent code on reentrant cfg. - Added multiple sector size support. +FatFs/Tiny-FatFs Module Source Files R0.07a (C)ChaN, 2009 + + +FILES + + ff.h Common include file for FatFs and application module. + ff.c FatFs module. + diskio.h Common include file for FatFs and disk I/O module. + diskio.c Skeleton of low level disk I/O module. + integer.h Alternative type definitions for integer variables. + option Optional external functions. + + Low level disk I/O module is not included in this archive because the FatFs + module is only a generic file system layer and not depend on any specific + storage device. You have to provide a low level disk I/O module that written + to control your storage device. + + + +AGREEMENTS + + FatFs module is an open source software to implement FAT file system to + small embedded systems. This is a free software and is opened for education, + research and commercial developments under license policy of following trems. + + Copyright (C) 2009, ChaN, all right reserved. + + * The FatFs module is a free software and there is NO WARRANTY. + * No restriction on use. You can use, modify and redistribute it for + personal, non-profit or commercial use UNDER YOUR RESPONSIBILITY. + * Redistributions of source code must retain the above copyright notice. + + + +REVISION HISTORY + + Feb 26, 2006 R0.00 Prototype + + Apr 29, 2006 R0.01 First release. + + Jun 01, 2006 R0.02 Added FAT12. + Removed unbuffered mode. + Fixed a problem on small (<32M) patition. + + Jun 10, 2006 R0.02a Added a configuration option _FS_MINIMUM. + + Sep 22, 2006 R0.03 Added f_rename. + Changed option _FS_MINIMUM to _FS_MINIMIZE. + + Dec 11, 2006 R0.03a Improved cluster scan algolithm to write files fast. + Fixed f_mkdir creates incorrect directory on FAT32. + + Feb 04, 2007 R0.04 Supported multiple drive system. (FatFs) + Changed some APIs for multiple drive system. + Added f_mkfs. (FatFs) + Added _USE_FAT32 option. (Tiny-FatFs) + + Apr 01, 2007 R0.04a Supported multiple partitions on a plysical drive. (FatFs) + Fixed an endian sensitive code in f_mkfs. (FatFs) + Added a capability of extending the file size to f_lseek. + Added minimization level 3. + Fixed a problem that can collapse a sector when recreate an + existing file in any sub-directory at non FAT32 cfg. (Tiny-FatFs) + + May 05, 2007 R0.04b Added _USE_NTFLAG option. + Added FSInfo support. + Fixed some problems corresponds to FAT32. (Tiny-FatFs) + Fixed DBCS name can result FR_INVALID_NAME. + Fixed short seek (0 < ofs <= csize) collapses the file object. + + Aug 25, 2007 R0.05 Changed arguments of f_read, f_write. + Changed arguments of f_mkfs. (FatFs) + Fixed f_mkfs on FAT32 creates incorrect FSInfo. (FatFs) + Fixed f_mkdir on FAT32 creates incorrect directory. (FatFs) + + Feb 03, 2008 R0.05a Added f_truncate(). + Added f_utime(). + Fixed off by one error at FAT sub-type determination. + Fixed btr in f_read() can be mistruncated. + Fixed cached sector is not flushed when create and close without write. + + Apr 01, 2008 R0.06 Added f_forward(). (Tiny-FatFs) + Added string functions: fputc(), fputs(), fprintf() and fgets(). + Improved performance of f_lseek() on move to the same or following cluster. + + Apr 01, 2009, R0.07 Merged Tiny-FatFs as a buffer configuration option. + Added long file name support. + Added multiple code page support. + Added re-entrancy for multitask operation. + Added auto cluster size selection to f_mkfs(). + Added rewind option to f_readdir(). + Changed result code of critical errors. + Renamed string functions to avoid name collision. + + Apr 14, 2009, R0.07a Separated out OS dependent code on reentrant cfg. + Added multiple sector size support. diff --git a/doc/chm-builder.py b/doc/chm-builder.py index e6900bd8..fb2cb725 100644 --- a/doc/chm-builder.py +++ b/doc/chm-builder.py @@ -1,40 +1,40 @@ -""" -To be used on windows platform only to generate BeRTOS .chm documentation. -Requires doxygen.exe and hhc.exe to be in the system PATH. -""" -from __future__ import with_statement -import os, sys - -def move(old_path, new_path): - if os.path.exists(new_path): - os.unlink(new_path) - os.rename(old_path, new_path) - - -if sys.platform != 'win32': - print "This program can be run only on a Windows machine" - sys.exit(-1) - -if len(sys.argv) < 2: - print "Usage: " + sys.argv[0] + " [custom_doxyfile]" - sys.exit(-1) - -DOC_PATH = 'doc\\offline-reference\\html\\' -toc_modifier = r"doc\chm-toc-modifier.py" -toc_file = DOC_PATH + r"index.hhc" -bertos_toc = r"bertos-toc.hhc" - - -if os.system("doxygen " + sys.argv[1]): - print "doxygen error" -if os.system(toc_modifier + " " + toc_file + " " + bertos_toc): - print "toc-modifier error" -move(bertos_toc, toc_file) - -# compile CHM -os.system(r"hhc " + DOC_PATH + "index.hhp") - -chm_target = r"bertos\bertos-doc.chm" -move(DOC_PATH + r"bertos-doc.chm", chm_target) - - +""" +To be used on windows platform only to generate BeRTOS .chm documentation. +Requires doxygen.exe and hhc.exe to be in the system PATH. +""" +from __future__ import with_statement +import os, sys + +def move(old_path, new_path): + if os.path.exists(new_path): + os.unlink(new_path) + os.rename(old_path, new_path) + + +if sys.platform != 'win32': + print "This program can be run only on a Windows machine" + sys.exit(-1) + +if len(sys.argv) < 2: + print "Usage: " + sys.argv[0] + " [custom_doxyfile]" + sys.exit(-1) + +DOC_PATH = 'doc\\offline-reference\\html\\' +toc_modifier = r"doc\chm-toc-modifier.py" +toc_file = DOC_PATH + r"index.hhc" +bertos_toc = r"bertos-toc.hhc" + + +if os.system("doxygen " + sys.argv[1]): + print "doxygen error" +if os.system(toc_modifier + " " + toc_file + " " + bertos_toc): + print "toc-modifier error" +move(bertos_toc, toc_file) + +# compile CHM +os.system(r"hhc " + DOC_PATH + "index.hhp") + +chm_target = r"bertos\bertos-doc.chm" +move(DOC_PATH + r"bertos-doc.chm", chm_target) + + diff --git a/doc/chm-toc-modifier.py b/doc/chm-toc-modifier.py index f6239c8c..38f25e2d 100644 --- a/doc/chm-toc-modifier.py +++ b/doc/chm-toc-modifier.py @@ -1,44 +1,44 @@ -from __future__ import with_statement -import sys, re - -if len(sys.argv) < 1: - print "Usage: " + sys.argv[0] + " [hhc index file] [output file]" - sys.exit(-1) - -outfile = "out.hhc" -if len(sys.argv) == 3: - outfile = sys.argv[2] - -data_structures = [] - -section_start = re.compile(r"
  • .*? value=\"((File List)|(Data Structures)|(Main Page)|(Directory Hierarchy))\".*$") - -data_section = False -file_section = False - -with open(sys.argv[1], "r") as f: - with open(outfile, "w+") as out: - for line in f: - if re.search(section_start, line): - if line.find("Data Structures") != -1: - data_section = True - file_section = False - elif line.find("File List") != -1: - data_section = False - file_section = True - else: - data_section = False - file_section = False - - if data_section: - data_structures.append(line) - elif file_section: - pass - elif re.search(r"^<\/UL>$", line): - for i in data_structures: - out.write(i) - out.write(line) - else: - out.write(line) - - +from __future__ import with_statement +import sys, re + +if len(sys.argv) < 1: + print "Usage: " + sys.argv[0] + " [hhc index file] [output file]" + sys.exit(-1) + +outfile = "out.hhc" +if len(sys.argv) == 3: + outfile = sys.argv[2] + +data_structures = [] + +section_start = re.compile(r"
  • .*? value=\"((File List)|(Data Structures)|(Main Page)|(Directory Hierarchy))\".*$") + +data_section = False +file_section = False + +with open(sys.argv[1], "r") as f: + with open(outfile, "w+") as out: + for line in f: + if re.search(section_start, line): + if line.find("Data Structures") != -1: + data_section = True + file_section = False + elif line.find("File List") != -1: + data_section = False + file_section = True + else: + data_section = False + file_section = False + + if data_section: + data_structures.append(line) + elif file_section: + pass + elif re.search(r"^<\/UL>$", line): + for i in data_structures: + out.write(i) + out.write(line) + else: + out.write(line) + + diff --git a/doc/tag-filter.py b/doc/tag-filter.py index 059d0181..2bc2b0b0 100644 --- a/doc/tag-filter.py +++ b/doc/tag-filter.py @@ -1,19 +1,19 @@ -#!/usr/bin/env python -from __future__ import with_statement -import re, sys - -def remove_expr(regex, line): - new_line = re.sub(regex, "", line) - sys.stdout.write(new_line) - -if __name__ == "__main__": - wiz = re.compile(r"\$WIZ\$.*$") - notest = re.compile(r'notest:.*$') - with file(sys.argv[1]) as f: - for line in f: - if re.search(wiz, line) != None: - remove_expr(wiz, line) - elif re.search(notest, line) != None: - remove_expr(notest, line) - else: - sys.stdout.write(line) +#!/usr/bin/env python +from __future__ import with_statement +import re, sys + +def remove_expr(regex, line): + new_line = re.sub(regex, "", line) + sys.stdout.write(new_line) + +if __name__ == "__main__": + wiz = re.compile(r"\$WIZ\$.*$") + notest = re.compile(r'notest:.*$') + with file(sys.argv[1]) as f: + for line in f: + if re.search(wiz, line) != None: + remove_expr(wiz, line) + elif re.search(notest, line) != None: + remove_expr(notest, line) + else: + sys.stdout.write(line) -- 2.25.1