Skip to content

Commit 8d336f2

Browse files
committed
Updated documentation to match other info around littlefs
Mostly brought from documentation changes in the core repo
1 parent 9b79136 commit 8d336f2

File tree

1 file changed

+34
-27
lines changed

1 file changed

+34
-27
lines changed

README.md

+34-27
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## mbed wrapper for the [little filesystem](https://github.com/geky/littlefs)
1+
## mbed wrapper for the little filesystem
22

33
This is the mbed wrapper for [littlefs](https://github.com/geky/littlefs),
44
a little fail-safe filesystem designed for embedded systems.
@@ -12,34 +12,17 @@ a little fail-safe filesystem designed for embedded systems.
1212
| | |
1313
```
1414

15-
The littlefs comes with the following features:
15+
**Bounded RAM/ROM** - The littlefs is designed to work with a limited amount
16+
of memory. Recursion is avoided and dynamic memory is limited to configurable
17+
buffers that can be provided statically.
1618

17-
- **Power-loss resilient** - The littlefs is designed to handle random power
18-
failures and has strong copy-on-write guaruntees. During all filesystem
19-
operations, the storage on disk is always kept in a valid state. When
20-
updating a file, the original file will remain unmodified until the file is
21-
closed, or sync is called.
19+
**Power-loss resilient** - The littlefs is designed for systems that may have
20+
random power failures. The littlefs has strong copy-on-write guaruntees and
21+
storage on disk is always kept in a valid state.
2222

23-
- **Error detection** - While the littlefs does not implement static wear
24-
leveling, the littlefs detects write error and uses a limited form of dynamic
25-
wear leveling to work around blocks that go bad during the lifetime of the
26-
filesystem.
27-
28-
- **Low RAM/ROM usage** - The littlefs is designed to work in a limited amount
29-
of memory, recursion is avoided, and dynamic memory is limited to
30-
configurable buffers that can be provided statically.
31-
32-
The littlefs also comes with the following limitations:
33-
34-
- **Not portable to host OSs** - While the littlefs can use an SD card, no
35-
littlefs driver has been ported to host OSs such as Linux or Windows. If
36-
you need to support host OSs consider using the [FATFileSystem](https://github.com/ARMmbed/mbed-os/blob/mbed-os-5.5/features/filesystem/fat/FATFileSystem.h)
37-
found in mbed OS.
38-
39-
- **No static wear leveling** - While the littlefs does extend the lifetime
40-
of storage through a form of dynamic wear leveling, the littlefs does not
41-
evict static blocks. If you need to maximize the longevity of the underlying
42-
storage consider using the [SPIFFileSystem](https://github.com/armmbed/mbed-spiffs).
23+
**Wear leveling** - Since the most common form of embedded storage is erodible
24+
flash memories, littlefs provides a form of dynamic wear leveling for systems
25+
that can not fit a full flash translation layer.
4326

4427
## Usage
4528

@@ -95,3 +78,27 @@ int main() {
9578
printf("boot_count: %ld\n", boot_count);
9679
}
9780
```
81+
82+
## Reference material
83+
84+
[DESIGN.md](littlefs/DESIGN.md) - DESIGN.md contains a fully detailed dive into
85+
how littlefs actually works. I would encourage you to read it since the
86+
solutions and tradeoffs at work here are quite interesting.
87+
88+
[SPEC.md](littlefs/SPEC.md) - SPEC.md contains the on-disk specification of
89+
littlefs with all the nitty-gritty details. Can be useful for developing
90+
tooling.
91+
92+
## Related projects
93+
94+
[littlefs](https://github.com/geky/littlefs) - Where the core of littlefs
95+
currently lives.
96+
97+
[littlefs-fuse](https://github.com/geky/littlefs-fuse) - A [FUSE](https://github.com/libfuse/libfuse)
98+
wrapper for littlefs. The project allows you to mount littlefs directly in a
99+
Linux machine. Can be useful for debugging littlefs if you have an SD card
100+
handy.
101+
102+
[littlefs-js](https://github.com/geky/littlefs-js) - A javascript wrapper for
103+
littlefs. I'm not sure why you would want this, but it is handy for demos.
104+
You can see it in action [here](http://littlefs.geky.net/demo.html).

0 commit comments

Comments
 (0)