Wykres commitów

6 Commity (9d0525182dc926f68d73a9815c1b1abae1d69236)

Autor SHA1 Wiadomość Data
Damien George b33a770596 extmod/fsusermount: Support mounting of multiple block devices.
This patch adds support to fsusermount for multiple block devices
(instead of just one).  The maximum allowed is fixed at compile time by
the size of the fs_user_mount array accessed via MP_STATE_PORT, which
in turn is set by MICROPY_FATFS_VOLUMES.

With this patch, stmhal (which is still tightly coupled to fsusermount)
is also modified to support mounting multiple devices   And the flash and
SD card are now just two block devices that are mounted at start up if
they exist (and they have special native code to make them more
efficient).
2016-02-10 23:40:10 +00:00
Damien George 3770cd2e70 stmhal: Expose flash and SD card as proper objects with block protocol.
You can now create (singleton) objects representing the flash and SD
card, using:

    flash = pyb.Flash()
    sdcard = pyb.SDCard()

These objects provide the block protocol.
2016-02-10 23:40:10 +00:00
Damien George 1d7fb82f0a stmhal: Change 64-bit arithmetic to 32-bit for SD card block addressing.
By measuring SD card addresses in blocks and not bytes, one can get away
with using 32-bit numbers.

This patch also uses proper atomic lock/unlock around SD card
read/write, adds SD.info() function, and gives error code for failed
read/writes.
2014-09-15 23:49:57 +01:00
Damien George 04b9147e15 Add license header to (almost) all files.
Blanket wide to all .c and .h files.  Some files originating from ST are
difficult to deal with (license wise) so it was left out of those.

Also merged modpyb.h, modos.h, modstm.h and modtime.h in stmhal/.
2014-05-03 23:27:38 +01:00
Damien George b92d3e1fde stmhal: Add fatfs support, working with flash and SD card. 2014-03-17 14:04:19 +00:00
Damien George fb431bf556 stmhal: Add SD card support.
Just low-level read/write support.  No filesystem yet.
2014-03-17 13:03:41 +00:00