Cargo Features
[dependencies]
embedded-svc = { version = "0.28.0", default-features = false, features = ["std", "alloc", "experimental", "use_serde", "use_strum", "use_numenum", "defmt", "log"] }
- default = log, std, use_numenum, use_serde, use_strum
-
These default features are set whenever
embedded-svc
is added without
somewhere in the dependency tree.default-features = false - std default = alloc
-
Enables std of embedded-io, embedded-io-async, optional num_enum, serde, and optional strum ^0.25
serde:
Provide impls for common standard library types like Vec<T> and HashMap<K, V>.
Requires a dependency on the Rust standard library. - alloc std
-
Enables alloc of optional defmt, embedded-io, embedded-io-async, and serde
serde:
Provide impls for types in the Rust core allocation and collections library including String, Box<T>, Vec<T>, and Cow<T>. This is a subset of std but may be enabled without depending on all of std.
Affects
wifi::Wifi.scan
,wifi::Wifi.scan
… - nightly experimental
- use_serde default
-
Enables serde and serde of enumset and heapless
heapless:
implement serde traits.
Affects
storage::Storage
,storage::SerDe
,storage::StorageImpl
… - use_strum default = strum, strum_macros
- defmt
-
Enables defmt and defmt-03 of embedded-io, embedded-io-async, and heapless
heapless:
Implement defmt::Format from defmt v0.3
Features from optional dependencies
In crates that don't use the dep:
syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.
- log default
- strum use_strum
-
Enables strum ^0.25
- strum_macros use_strum
-
Enables strum_macros ^0.25
- num_enum use_numenum