Skip to content

Commit

Permalink
fix: adding default features
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasbrendel committed Dec 25, 2023
1 parent bf7e76a commit 4b4de8d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 15 deletions.
8 changes: 3 additions & 5 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,13 @@ edition = "2018"

[dependencies]
cortex-m = "0.7.7"
cortex-m-rt = { version = "0.7.3", optional = true}
critical-section = { version = "1.1.2", optional = true }
vcell = "0.1.3"

[dependencies.cortex-m-rt]
optional = true
version = "0.7.3"

[features]
default = ["critical-section", "rt"]
rt = ["cortex-m-rt/device"]

[package.metadata.docs.rs]
features = ["rt"]
features = ['default']
10 changes: 0 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@

This is a 'peripheral access crate' for interfacing to the XMC4500 series of microcontrollers for embedded support in Rust that is generated using [svd2rust](https://docs.rs/svd2rust) and an SVD file provided by Infineon.

There is an optional `rt` that can be utilized. An explanation of the feature is given by [svd2rust](https://docs.rs/svd2rust/0.16.1/svd2rust/#the-rt-feature)

All API's and usage (besides what registers exist) are defined by [svd2rust](https://docs.rs/svd2rust)

## Generate Crate from SVD
Expand All @@ -21,11 +19,3 @@ rustup component add rustfmt

svd.sh # Generates code from crate and formats to rustfmt
```

## Using Crate

```toml
[dependencies.xmc4500]
version = "0.3.1"
features = ["rt"]
```

0 comments on commit 4b4de8d

Please sign in to comment.