rp-hal-boards/rp2040-hal/Cargo.toml

77 lines
2.4 KiB
TOML
Raw Normal View History

[package]
name = "rp2040-hal"
version = "0.6.0"
authors = ["The rp-rs Developers"]
edition = "2018"
homepage = "https://github.com/rp-rs/rp-hal"
description = "A Rust Embeded-HAL impl for the rp2040 microcontroller"
license = "MIT OR Apache-2.0"
2022-11-13 00:26:32 +11:00
[package.metadata.docs.rs]
features = ["rt", "rom-v2-intrinsics", "defmt", "rtic-monotonic"]
targets = ["thumbv6m-none-eabi"]
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
cortex-m = "0.7.2"
cortex-m-rt = ">=0.6.15,<0.8"
embedded-hal = { version = "0.2.5", features = ["unproven"] }
eh1_0_alpha = { package = "embedded-hal", version = "=1.0.0-alpha.9", optional = true }
fugit = "0.3.6"
itertools = { version = "0.10.1", default-features = false }
nb = "1.0"
rp2040-pac = "0.4.0"
paste = "1.0"
pio = "0.2.0"
rp2040-hal-macros = { version = "0.1.0", path = "../rp2040-hal-macros" }
2022-08-03 05:43:00 +10:00
usb-device = "0.2.9"
vcell = "0.1"
void = { version = "1.0.2", default-features = false }
rand_core = "0.6.3"
critical-section = { version = "1.0.0" }
chrono = { version = "0.4", default-features = false, optional = true }
Implement peripheral support for i2c and an advanced example (#162) * Implement peripheral support for i2c and an advanced example for the pico board. * Simplify i2c peripheral bootstrap and add a "free" function to allow switching modes. * Set dependency to futures & nostd_async to specific version/revision. * move enum & struct to the start of the file * Add a bit of documentation to the pico_i2c_controller_peripheral demo. * Migrate to pico_i2c_controller_peripheral to embassy & simplify the peripheral support nostd_async is broken since last stable roll out. The pico_i2c_controller_peripheral is being migrated to use embassy's executor. The Controller Async API is now aligned with embassy's traits to facilitate integration. The peripheral no longer require async to run and now appears as an event iterator. Embassy's support relies on unstable features (generic_associated_types and type_alias_impl_traits) and is therefore gated behind the `embassy-traits` feature flag. * make futures & embassy optional for the pico board too * Pin embassy to a specific rev. * Impl embassy_traits::i2c::WriteIter & enable unlimited transfer size on i2c * Applies comment suggestion from @9names for the advanced i2c example. Co-authored-by: 9names <60134748+9names@users.noreply.github.com> * use `I2C block` instead of `IP`. * Fix formatting (unnecessary space at end of line) * Enhance explanation for why `rd_req()` is not cleared in `Iterator::next`'s implementation. Co-authored-by: 9names <60134748+9names@users.noreply.github.com>
2021-11-08 23:23:28 +11:00
defmt = { version = ">=0.2.0, <0.4", optional = true }
rtic-monotonic = { version = "1.0.0", optional = true }
[dev-dependencies]
cortex-m-rt = "0.7"
panic-halt = "0.2.0"
rp2040-boot2 = "0.2.1"
hd44780-driver = "0.4.0"
pio-proc = "0.2.0"
2022-01-29 07:57:51 +11:00
dht-sensor = "0.2.1"
[features]
2022-10-03 11:43:09 +11:00
# Minimal startup / runtime for Cortex-M microcontrollers
rt = ["rp2040-pac/rt"]
2022-10-03 11:43:09 +11:00
# Memoize(cache) ROM function pointers on first use to improve performance
rom-func-cache = []
2022-10-03 11:43:09 +11:00
# Disable automatic mapping of language features (like floating point math) to ROM functions
disable-intrinsics = []
2022-10-03 11:43:09 +11:00
# This enables ROM functions for f64 math that were not present in the earliest RP2040s
rom-v2-intrinsics = []
2022-10-03 11:43:09 +11:00
# This enables a fix for USB errata 5: USB device fails to exit RESET state on busy USB bus.
# Only required for RP2040 B0 and RP2040 B1, but it also works for RP2040 B2 and above
rp2040-e5 = []
# critical section that is safe for multicore use
critical-section-impl = ["critical-section/restore-state-u8"]
[[example]]
# irq example uses cortex-m-rt::interrupt, need rt feature for that
name = "gpio_irq_example"
required-features = ["rt", "critical-section-impl"]
[[example]]
# vector_table example uses cortex-m-rt::interrupt, need rt feature for that
name = "vector_table"
required-features = ["rt", "critical-section-impl"]