aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorhuntc <[email protected]>2021-12-09 10:40:03 +1100
committerhuntc <[email protected]>2021-12-09 10:40:03 +1100
commit990d2330dbcec71bf72bdc116c390181f8d995cc (patch)
treea5bbc83c1f7a9cbcc61ff5fdce21c4ebaada194c /README.md
parent4eb9f0f3aebfa7b1d72830da2241b2a8b7ca139f (diff)
Rust Analyzer documentation
Intends to clarify how to make Embassy usable from within Visual Studio Code by assuming the presence of the Rust Analyzer. Note that IntelliJ does not support the Rust Analyzer, so an open question remains as to the whether this is a good move. If it turns out not to be a good move then we should still look at clarifying the use of a workspace file.
Diffstat (limited to 'README.md')
-rw-r--r--README.md25
1 files changed, 21 insertions, 4 deletions
diff --git a/README.md b/README.md
index f8898dcd6..fd856bb6d 100644
--- a/README.md
+++ b/README.md
@@ -28,9 +28,10 @@ The `embassy::executor` module provides an async/await executor designed for emb
28 28
29`embassy::util` contains some lightweight async/await utilities, mainly helpful for async driver development (signaling a task that an interrupt has occured, for example). 29`embassy::util` contains some lightweight async/await utilities, mainly helpful for async driver development (signaling a task that an interrupt has occured, for example).
30 30
31## embassy-nrf 31## HALs
32 32
33The `embassy-nrf` crate contains implementations for nRF 52 series SoCs. 33Hardware Absraction Layers with asynchronous behaviors are provided for a variety of platforms.
34For example, the `embassy-nrf` crate contains implementations for nRF 52 series SoCs.
34 35
35- `uarte`: UARTE driver implementing `AsyncBufRead` and `AsyncWrite`. 36- `uarte`: UARTE driver implementing `AsyncBufRead` and `AsyncWrite`.
36- `qspi`: QSPI driver implementing `Flash`. 37- `qspi`: QSPI driver implementing `Flash`.
@@ -41,7 +42,8 @@ The `embassy-nrf` crate contains implementations for nRF 52 series SoCs.
41 42
42## Examples 43## Examples
43 44
44Examples are found in the `examples/` folder seperated by the chip manufacturer they are designed to run on: 45Examples are found in the `examples/` folder seperated by the chip manufacturer they are designed to run on. For example:
46
45* `examples/nrf` are designed to run on the `nrf52840-dk` board (PCA10056) but should be easily adaptable to other nRF52 chips and boards. 47* `examples/nrf` are designed to run on the `nrf52840-dk` board (PCA10056) but should be easily adaptable to other nRF52 chips and boards.
46* `examples/rp` are for the RP2040 chip. 48* `examples/rp` are for the RP2040 chip.
47* `examples/stm32` are designed for the STM32F429ZI chip but should be easily adaptable to other STM32F4xx chips. 49* `examples/stm32` are designed for the STM32F429ZI chip but should be easily adaptable to other STM32F4xx chips.
@@ -61,12 +63,27 @@ git submodule update
61cargo install probe-run 63cargo install probe-run
62``` 64```
63 65
66- Change directory to the sample's base directory. For example:
67
68```
69cd examples/nrf
70```
71
64- Run the example 72- Run the example
65 73
74For example:
75
66``` 76```
67cargo run --bin rtc_async 77cargo run --bin blinky
68``` 78```
69 79
80## Developing Embassy with Rust Analyzer based editors
81
82The [Rust Analyzer](https://rust-analyzer.github.io/) is used by [Visual Studio Code](https://code.visualstudio.com/)
83and others. Given the multiple targets that Embassy serves, there is no Cargo workspace file. Instead, the Rust Analyzer
84must be told of the target project to work with. In the case of Visual Studio Code,
85please refer to the `.vscode/settings.json` file's `rust-analyzer.linkedProjects`setting.
86
70## Minimum supported Rust version (MSRV) 87## Minimum supported Rust version (MSRV)
71 88
72Required nightly version is specified in the `rust-toolchain.toml` file. Nightly is required for: 89Required nightly version is specified in the `rust-toolchain.toml` file. Nightly is required for: