Skip to content

Commit 5de064f

Browse files
committed
docs/library/index: Elaborate uPy libraries intro.
1 parent b806889 commit 5de064f

File tree

1 file changed

+14
-12
lines changed

1 file changed

+14
-12
lines changed

docs/library/index.rst

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -9,34 +9,36 @@ MicroPython libraries
99

1010
* MicroPython implements a subset of Python functionality for each module.
1111
* To ease extensibility, MicroPython versions of standard Python modules
12-
usually have ``u`` (micro) prefix.
12+
usually have ``u`` ("micro") prefix.
1313
* Any particular MicroPython variant or port may miss any feature/function
14-
described in this general documentation, due to resource constraints.
14+
described in this general documentation (due to resource constraints or
15+
other limitations).
1516

1617

1718
This chapter describes modules (function and class libraries) which are built
18-
into MicroPython. There are a few categories of modules:
19+
into MicroPython. There are a few categories of such modules:
1920

2021
* Modules which implement a subset of standard Python functionality and are not
2122
intended to be extended by the user.
2223
* Modules which implement a subset of Python functionality, with a provision
2324
for extension by the user (via Python code).
2425
* Modules which implement MicroPython extensions to the Python standard libraries.
25-
* Modules specific to a particular port and thus not portable.
26+
* Modules specific to a particular `MicroPython port` and thus not portable.
2627

27-
Note about the availability of modules and their contents: This documentation
28+
Note about the availability of the modules and their contents: This documentation
2829
in general aspires to describe all modules and functions/classes which are
29-
implemented in MicroPython. However, MicroPython is highly configurable, and
30+
implemented in MicroPython project. However, MicroPython is highly configurable, and
3031
each port to a particular board/embedded system makes available only a subset
3132
of MicroPython libraries. For officially supported ports, there is an effort
3233
to either filter out non-applicable items, or mark individual descriptions
3334
with "Availability:" clauses describing which ports provide a given feature.
35+
3436
With that in mind, please still be warned that some functions/classes
35-
in a module (or even the entire module) described in this documentation may be
36-
unavailable in a particular build of MicroPython on a particular board. The
37+
in a module (or even the entire module) described in this documentation **may be
38+
unavailable** in a particular build of MicroPython on a particular system. The
3739
best place to find general information of the availability/non-availability
3840
of a particular feature is the "General Information" section which contains
39-
information pertaining to a specific port.
41+
information pertaining to a specific `MicroPython port`.
4042

4143
Beyond the built-in libraries described in this documentation, many more
4244
modules from the Python standard library, as well as further MicroPython
@@ -58,9 +60,9 @@ what done by the `micropython-lib` project mentioned above).
5860
On some embedded platforms, where it may be cumbersome to add Python-level
5961
wrapper modules to achieve naming compatibility with CPython, micro-modules
6062
are available both by their u-name, and also by their non-u-name. The
61-
non-u-name can be overridden by a file of that name in your package path.
62-
For example, ``import json`` will first search for a file ``json.py`` or
63-
directory ``json`` and load that package if it is found. If nothing is found,
63+
non-u-name can be overridden by a file of that name in your library path (``sys.path``).
64+
For example, ``import json`` will first search for a file ``json.py`` (or package
65+
directory ``json``) and load that module if it is found. If nothing is found,
6466
it will fallback to loading the built-in ``ujson`` module.
6567

6668
.. only:: port_unix

0 commit comments

Comments
 (0)