futures: readme, docs improvements.

This commit is contained in:
Dario Nieuwenhuis
2022-08-29 00:54:14 +02:00
parent 4c0f1b6354
commit 6392f06717
4 changed files with 48 additions and 8 deletions

View File

@ -1,10 +1,28 @@
# embassy-futures
Utilities for working with futures:
An [Embassy](https://embassy.dev) project.
Utilities for working with futures, compatible with `no_std` and not using `alloc`. Optimized for code size,
ideal for embedded systems.
- Future combinators, like [`join`](join) and [`select`](select)
- Utilities to use `async` without a fully fledged executor: [`block_on`](block_on::block_on) and [`yield_now`](yield_now::yield_now).
## Interoperability
Futures from this crate can run on any executor.
## Minimum supported Rust version (MSRV)
Embassy is guaranteed to compile on the latest stable Rust version at the time of release. It might compile with older versions but that may change in any new patch release.
## License
This work is licensed under either of
- Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or
<http://www.apache.org/licenses/LICENSE-2.0>)
- MIT license ([LICENSE-MIT](LICENSE-MIT) or <http://opensource.org/licenses/MIT>)
at your option.
- [`select`](select::select) - waiting for one out of two futures to complete.
- [`select3`](select::select3) - waiting for one out of three futures to complete.
- [`select4`](select::select4) - waiting for one out of four futures to complete.
- [`select_array`](select::select_array) - waiting for one future in an array of futures to complete.
- [`select_slice`](select::select_slice) - waiting for one future in a slice of futures to complete.
- [`yield_now`](yield_now::yield_now) - yielding the current task.