stm32-p103: add "empty" preset template.
[bertos.git] / boards / stm32-p103 / templates / empty / cfg / cfg_fat.h
1 /**
2  * \file
3  * <!--
4  * This file is part of BeRTOS.
5  *
6  * Bertos is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
19  *
20  * As a special exception, you may use this file as part of a free software
21  * library without restriction.  Specifically, if other files instantiate
22  * templates or use macros or inline functions from this file, or you compile
23  * this file and link it with other files to produce an executable, this
24  * file does not by itself cause the resulting executable to be covered by
25  * the GNU General Public License.  This exception does not however
26  * invalidate any other reasons why the executable file might be covered by
27  * the GNU General Public License.
28  *
29  * Copyright 2009 Develer S.r.l. (http://www.develer.com/)
30  * All Rights Reserved.
31  * -->
32  *
33  * \brief Configuration file for Fat module.
34  *
35  * \version $Id$
36  *
37  * \author Luca Ottaviano <lottaviano@develer.com>
38  * \author Francesco Sacchi <batt@develer.com>
39  */
40
41 #ifndef CFG_FAT_H
42 #define CFG_FAT_H
43
44 /**
45  * Use word alignment to access FAT structure.
46  * $WIZ$ type = "boolean"
47  */
48 #define CONFIG_FAT_WORD_ACCESS   0
49 #define _WORD_ACCESS CONFIG_FAT_WORD_ACCESS
50
51 /**
52  * Enable read functions only.
53  * $WIZ$ type = "boolean"
54  */
55 #define CONFIG_FAT_FS_READONLY   0
56 #define _FS_READONLY CONFIG_FAT_FS_READONLY
57
58 /**
59  * Minimization level to remove some functions.
60  * $WIZ$ type = "int"; min = 0; max = 3
61  */
62 #define CONFIG_FAT_FS_MINIMIZE 0
63 #define _FS_MINIMIZE CONFIG_FAT_FS_MINIMIZE
64
65 /**
66  * If enabled, this reduces memory consumption 512 bytes each file object by using a shared buffer.
67  * $WIZ$ type = "boolean"
68  */
69 #define CONFIG_FAT_FS_TINY 1
70 #define _FS_TINY CONFIG_FAT_FS_TINY
71
72 /**
73  * To enable string functions, set _USE_STRFUNC to 1 or 2.
74  * $WIZ$ type = "int"
75  * $WIZ$ supports = "False"
76  */
77 #define CONFIG_FAT_USE_STRFUNC 0
78 #define _USE_STRFUNC CONFIG_FAT_USE_STRFUNC
79
80 /**
81  * Enable f_mkfs function. Requires CONFIG_FAT_FS_READONLY = 0.
82  * $WIZ$ type = "boolean"
83  */
84 #define CONFIG_FAT_USE_MKFS 0
85 #define _USE_MKFS (CONFIG_FAT_USE_MKFS && !CONFIG_FAT_FS_READONLY)
86
87 /**
88  * Enable f_forward function. Requires CONFIG_FAT_FS_TINY.
89  * $WIZ$ type = "boolean"
90  */
91 #define CONFIG_FAT_USE_FORWARD 0
92 #define _USE_FORWARD (CONFIG_FAT_USE_FORWARD && CONFIG_FAT_FS_TINY)
93
94 /**
95  * Number of volumes (logical drives) to be used.
96  * $WIZ$ type = "int"; min = 1; max = 255
97  */
98 #define CONFIG_FAT_DRIVES 1
99 #define _DRIVES CONFIG_FAT_DRIVES
100
101 /**
102  * Maximum sector size to be handled. (512/1024/2048/4096).
103  * 512 for memory card and hard disk, 1024 for floppy disk, 2048 for MO disk
104  * $WIZ$ type = "int"; min = 512; max = 4096
105  */
106 #define CONFIG_FAT_MAX_SS 512
107 #define _MAX_SS CONFIG_FAT_MAX_SS
108
109 /**
110  * When _MULTI_PARTITION is set to 0, each volume is bound to the same physical
111  * drive number and can mount only first primaly partition. When it is set to 1,
112  * each volume is tied to the partitions listed in Drives[].
113  * $WIZ$ type = "boolean"
114  * $WIZ$ supports = "False"
115  */
116 #define CONFIG_FAT_MULTI_PARTITION 0
117 #define _MULTI_PARTITION CONFIG_FAT_MULTI_PARTITION
118
119 /**
120  * Specifies the OEM code page to be used on the target system.
121  * $WIZ$ type = "int"
122  */
123 #define CONFIG_FAT_CODE_PAGE 850
124 #define _CODE_PAGE CONFIG_FAT_CODE_PAGE
125
126 /**
127  * Support for long filenames. Enable only if you have a valid Microsoft license.
128  * $WIZ$ type = "boolean"
129  */
130 #define CONFIG_FAT_USE_LFN 0
131 #define _USE_LFN CONFIG_FAT_USE_LFN
132
133 /**
134  * Maximum Long File Name length to handle.
135  * $WIZ$ type = "int"; min = 8; max = 255
136  */
137 #define CONFIG_FAT_MAX_LFN 255
138 #define _MAX_LFN CONFIG_FAT_MAX_LFN
139
140 #endif /* CFG_FAT_H */