Skip to content

Commit

Permalink
ports/ameba: Enable VfsFat filesystem.
Browse files Browse the repository at this point in the history
  • Loading branch information
pi-anl committed Apr 14, 2022
1 parent 80fbd2a commit 673c3d1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion ports/ameba/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ include ../../py/mkenv.mk
# declare before py.mk
FROZEN_MANIFEST ?= manifest.py

MICROPY_VFS_FAT ?= 0 # need to strip fatfs libs out of lib_micropython.a first
MICROPY_VFS_FAT ?= 1
MICROPY_VFS_LFS2 ?= 1

include $(TOP)/py/py.mk
Expand Down
7 changes: 4 additions & 3 deletions ports/ameba/amebad.mk
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ INC += -I$(TOP)/shared/timeutils
INC += -I$(TOP)/shared/readline
INC += -I$(TOP)/shared/netutils
INC += -I$(TOP)/shared/runtime
#INC += -I$(TOP)/lib/oofatfs
#INC += -I$(TOP)/lib/lwip/src/include/lwip

INC += -Imp_helper
Expand All @@ -96,7 +95,7 @@ INC += -Imp_helper/mods/machine
# Micropython Port Source file list
# -------------------------------------------------------------------
UPY_C += pins.c
#UPY_C += mp_helper/diskio.c
UPY_C += mp_helper/diskio.c
# UPY_C += mp_helper/flashbdev.c
UPY_C += mp_helper/exception.c
UPY_C += mp_helper/help.c
Expand Down Expand Up @@ -188,7 +187,6 @@ CFLAGS += -Wno-write-strings -Wno-maybe-uninitialized -c -MMD -Wextra
CFLAGS += -Wl,--start-group
CFLAGS += $(INC)
CFLAGS += -Wl,--end-group
# CFLAGS += -DFFCONF_H=\"$(OOFATFS_DIR)/ffconf.h\"
CFLAGS += $(CFLAGS_MOD)


Expand Down Expand Up @@ -239,6 +237,9 @@ prerequirement: check_toolchain check_postbuildtools submodules
$(Q)cp -f $(POSTBUILDTOOL_PATH)/$(PICK) $(BUILD)/$(BUILDTOOL_PATH)/$(PICK)
$(Q)cp -f $(POSTBUILDTOOL_PATH)/$(PAD) $(BUILD)/$(BUILDTOOL_PATH)/$(PAD)

$(Q)echo "Delete diskio from the static micropython library."
ar dv $(TOP)/lib/ameba_sdk/MicroPython_RTL8722/ports/rtl8722/amebad_vendor/ARCHIVE_LIB/lib_micropython.a diskio.o 2> /dev/null


.PHONY: check_toolchain
check_toolchain:
Expand Down
2 changes: 1 addition & 1 deletion ports/ameba/mpconfigport.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@
#define MICROPY_READER_VFS (MICROPY_VFS)
#define MICROPY_READER_FATFS (MICROPY_VFS_FAT)
#define MICROPY_FATFS_ENABLE_LFN (1)
#define MICROPY_FATFS_LFN_CODE_PAGE (437) /* 1=SFN/ANSI 437=LFN/U.S.(OEM) */
#define MICROPY_FATFS_LFN_CODE_PAGE 437 /* 1=SFN/ANSI 437=LFN/U.S.(OEM) */
#define MICROPY_FATFS_VOLUMES (1)
#define MICROPY_FATFS_RPATH (2)
#define MICROPY_FATFS_MAX_SS (512)
Expand Down

0 comments on commit 673c3d1

Please sign in to comment.