Skip to content
Snippets Groups Projects
Commit 1e2cf746 authored by mux's avatar mux
Browse files

Add Configurable LFN support to FatFS

parent 2613ffde
No related branches found
No related tags found
No related merge requests found
......@@ -141,6 +141,7 @@ SRC_STMUSBH = $(addprefix $(STMUSBH_DIR)/,\
SRC_FATFS = $(addprefix $(FATFS_DIR)/,\
ff.c \
diskio.c \
ccsbcs.c \
)
SRC_CC3K = $(addprefix $(CC3K_DIR)/,\
......
This diff is collapsed.
......@@ -9,6 +9,7 @@
#ifndef _FFCONF
#define _FFCONF 80960 /* Revision ID */
#include "mpconfigport.h"
/*---------------------------------------------------------------------------/
/ Functions and Buffer Configurations
......@@ -60,7 +61,7 @@
/ Locale and Namespace Configurations
/----------------------------------------------------------------------------*/
#define _CODE_PAGE 1
#define _CODE_PAGE (MICROPY_LFN_CODE_PAGE)
/* The _CODE_PAGE specifies the OEM code page to be used on the target system.
/ Incorrect setting of the code page can cause a file open failure.
/
......@@ -92,8 +93,7 @@
/ 1 - ASCII (Valid for only non-LFN cfg.)
*/
#define _USE_LFN 0 /* 0 to 3 */
#define _USE_LFN (MICROPY_ENABLE_LFN) /* 0 to 3 */
#define _MAX_LFN 255 /* Maximum LFN length to handle (12 to 255) */
/* The _USE_LFN option switches the LFN feature.
/
......
......@@ -8,6 +8,14 @@
#define MICROPY_ENABLE_REPL_HELPERS (1)
#define MICROPY_ENABLE_FLOAT (1)
#define MICROPY_PATH_MAX (128)
/* Enable FatFS LFNs
0: Disable LFN feature.
1: Enable LFN with static working buffer on the BSS. Always NOT reentrant.
2: Enable LFN with dynamic working buffer on the STACK.
3: Enable LFN with dynamic working buffer on the HEAP.
*/
#define MICROPY_ENABLE_LFN (0)
#define MICROPY_LFN_CODE_PAGE (1) /* 1=SFN/ANSI 437=LFN/U.S.(OEM) */
// type definitions for the specific machine
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment