Skip to content

Commit

Permalink
(WIP) Code tyding
Browse files Browse the repository at this point in the history
  • Loading branch information
ivmarkov committed Apr 30, 2024
1 parent 029d835 commit 76038ca
Show file tree
Hide file tree
Showing 10 changed files with 851 additions and 939 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ enumset = { version = "1", default-features = false }
strum = { version = "0.26", default-features = false, features = ["derive"] }
embassy-futures = "0.1"
embassy-sync = "0.5"
embassy-time = { version = "0.3", features = ["generic-queue"] }
esp-idf-svc = { version = "0.48", default-features = false, features = ["alloc", "embassy-sync", "embassy-time-driver", "experimental"] }
embedded-svc = { version = "0.27", default-features = false }
rs-matter = { version = "0.1", default-features = false }
Expand Down
2 changes: 2 additions & 0 deletions examples/light.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ fn main() -> Result<(), Error> {
// w.r.t. stack usage in async functions
let matter = pin!(stack.run(
EspSystemEventLoop::take()?, // The Matter stack needs (a clone of) the system event loop
EspTimerService::take()?, // The Matter stack needs (a clone of) the timer service
EspDefaultNvsPartition::take()?, // The Matter stack needs (a clone of) the default ESP IDF NVS partition too
Peripherals::take()?.modem, // The Matter stack needs the BT/Wifi modem peripheral
CommissioningData {
Expand Down Expand Up @@ -95,6 +96,7 @@ fn main() -> Result<(), Error> {
}

/// The Matter stack is allocated statically to avoid program stack blowups
/// It is also a mandatory requirement when the `WifiBle` stack variation is used
static MATTER_STACK: ConstStaticCell<MatterStack<WifiBle>> =
ConstStaticCell::new(MatterStack::new(
&BasicInfoConfig {
Expand Down
Loading

0 comments on commit 76038ca

Please sign in to comment.