Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
micropython
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
card10
micropython
Commits
374654f2
Commit
374654f2
authored
9 years ago
by
Paul Sokolovsky
Browse files
Options
Downloads
Patches
Plain Diff
esp8266: Enable FatFs support.
parent
fe9bc0c5
No related branches found
No related tags found
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
esp8266/Makefile
+3
-0
3 additions, 0 deletions
esp8266/Makefile
esp8266/fatfs_port.c
+6
-0
6 additions, 0 deletions
esp8266/fatfs_port.c
esp8266/moduos.c
+5
-0
5 additions, 0 deletions
esp8266/moduos.c
esp8266/mpconfigport.h
+8
-0
8 additions, 0 deletions
esp8266/mpconfigport.h
with
22 additions
and
0 deletions
esp8266/Makefile
+
3
−
0
View file @
374654f2
...
@@ -75,6 +75,7 @@ SRC_C = \
...
@@ -75,6 +75,7 @@ SRC_C = \
utils.c
\
utils.c
\
ets_alt_task.c
\
ets_alt_task.c
\
$(
BUILD
)
/frozen.c
\
$(
BUILD
)
/frozen.c
\
fatfs_port.o
\
STM_SRC_C
=
$(
addprefix stmhal/,
\
STM_SRC_C
=
$(
addprefix stmhal/,
\
pybstdio.c
\
pybstdio.c
\
...
@@ -109,6 +110,8 @@ LIB_SRC_C = $(addprefix lib/,\
...
@@ -109,6 +110,8 @@ LIB_SRC_C = $(addprefix lib/,\
timeutils/timeutils.c
\
timeutils/timeutils.c
\
utils/pyexec.c
\
utils/pyexec.c
\
utils/printf.c
\
utils/printf.c
\
fatfs/ff.c
\
fatfs/option/ccsbcs.c
\
)
)
SRC_S
=
\
SRC_S
=
\
...
...
This diff is collapsed.
Click to expand it.
esp8266/fatfs_port.c
0 → 100644
+
6
−
0
View file @
374654f2
#include
"lib/fatfs/ff.h"
#include
"lib/fatfs/diskio.h"
DWORD
get_fattime
(
void
)
{
return
0
;
}
This diff is collapsed.
Click to expand it.
esp8266/moduos.c
+
5
−
0
View file @
374654f2
...
@@ -34,6 +34,8 @@
...
@@ -34,6 +34,8 @@
#include
"genhdr/mpversion.h"
#include
"genhdr/mpversion.h"
#include
"user_interface.h"
#include
"user_interface.h"
extern
const
mp_obj_type_t
mp_fat_vfs_type
;
STATIC
const
qstr
os_uname_info_fields
[]
=
{
STATIC
const
qstr
os_uname_info_fields
[]
=
{
MP_QSTR_sysname
,
MP_QSTR_nodename
,
MP_QSTR_sysname
,
MP_QSTR_nodename
,
MP_QSTR_release
,
MP_QSTR_version
,
MP_QSTR_machine
MP_QSTR_release
,
MP_QSTR_version
,
MP_QSTR_machine
...
@@ -68,6 +70,9 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_0(os_uname_obj, os_uname);
...
@@ -68,6 +70,9 @@ STATIC MP_DEFINE_CONST_FUN_OBJ_0(os_uname_obj, os_uname);
STATIC
const
mp_map_elem_t
os_module_globals_table
[]
=
{
STATIC
const
mp_map_elem_t
os_module_globals_table
[]
=
{
{
MP_OBJ_NEW_QSTR
(
MP_QSTR___name__
),
MP_OBJ_NEW_QSTR
(
MP_QSTR_uos
)
},
{
MP_OBJ_NEW_QSTR
(
MP_QSTR___name__
),
MP_OBJ_NEW_QSTR
(
MP_QSTR_uos
)
},
{
MP_OBJ_NEW_QSTR
(
MP_QSTR_uname
),
(
mp_obj_t
)
&
os_uname_obj
},
{
MP_OBJ_NEW_QSTR
(
MP_QSTR_uname
),
(
mp_obj_t
)
&
os_uname_obj
},
#if MICROPY_VFS_FAT
{
MP_ROM_QSTR
(
MP_QSTR_VfsFat
),
(
mp_obj_t
)
&
mp_fat_vfs_type
},
#endif
};
};
STATIC
MP_DEFINE_CONST_DICT
(
os_module_globals
,
os_module_globals_table
);
STATIC
MP_DEFINE_CONST_DICT
(
os_module_globals
,
os_module_globals_table
);
...
...
This diff is collapsed.
Click to expand it.
esp8266/mpconfigport.h
+
8
−
0
View file @
374654f2
...
@@ -59,6 +59,14 @@
...
@@ -59,6 +59,14 @@
#define MICROPY_MODULE_FROZEN (1)
#define MICROPY_MODULE_FROZEN (1)
#define MICROPY_MODULE_FROZEN_LEXER mp_lexer_new_from_str32
#define MICROPY_MODULE_FROZEN_LEXER mp_lexer_new_from_str32
#define MICROPY_FATFS_ENABLE_LFN (1)
#define MICROPY_FATFS_RPATH (2)
#define MICROPY_FATFS_VOLUMES (2)
#define MICROPY_FATFS_MAX_SS (4096)
#define MICROPY_FATFS_LFN_CODE_PAGE (437)
/* 1=SFN/ANSI 437=LFN/U.S.(OEM) */
#define MICROPY_FSUSERMOUNT (1)
#define MICROPY_VFS_FAT (1)
#define MICROPY_EVENT_POLL_HOOK {ets_event_poll();}
#define MICROPY_EVENT_POLL_HOOK {ets_event_poll();}
// type definitions for the specific machine
// type definitions for the specific machine
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment