diff options
author | Damien George <damien.p.george@gmail.com> | 2017-01-27 15:16:08 +1100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2017-01-27 17:21:45 +1100 |
commit | f9ecd484bbd698c0f85a3f40f391afeb01940052 (patch) | |
tree | ac85821061f3889e3aa65684c9a2d2fb927aa32f /esp8266/scripts | |
parent | f1e04148a195619d142523152e952af6eaf5cd1c (diff) | |
download | micropython-f9ecd484bbd698c0f85a3f40f391afeb01940052.tar.gz micropython-f9ecd484bbd698c0f85a3f40f391afeb01940052.zip |
esp8266: Change to use new generic VFS sub-system.
The VFS sub-system supports mounting of an arbitrary number of devices
(limited only by available RAM). The internal flash is now mounted at
"/flash".
Diffstat (limited to 'esp8266/scripts')
-rw-r--r-- | esp8266/scripts/inisetup.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/esp8266/scripts/inisetup.py b/esp8266/scripts/inisetup.py index 3930089db6..29421e7923 100644 --- a/esp8266/scripts/inisetup.py +++ b/esp8266/scripts/inisetup.py @@ -37,8 +37,10 @@ def setup(): print("Performing initial setup") wifi() uos.VfsFat.mkfs(bdev) - vfs = uos.VfsFat(bdev, "") - with open("/boot.py", "w") as f: + vfs = uos.VfsFat(bdev) + uos.mount(vfs, '/flash') + uos.chdir('/flash') + with open("boot.py", "w") as f: f.write("""\ # This file is executed on every boot (including wake-boot from deepsleep) #import esp |