Add mcutie MQTT client implementation and improve library structure

- Integrated `mcutie` library as a core MQTT client for device communication.
- Added support for Home Assistant entities (binary sensor, button) via MQTT.
- Implemented buffer management, async operations, and packet encoding/decoding.
- Introduced structured error handling and device registration features.
- Updated `Cargo.toml` with new dependencies and enabled feature flags for `serde` and `log`.
- Enhanced logging macros with configurable options (`defmt` or `log`).
- Organized codebase into modules (buffer, components, IO, publish, etc.) for better maintainability.

fix legacy dependecencies and compatiblity with mcutie vendored lib

fix shit i hate this
This commit is contained in:
2026-04-27 09:39:29 +02:00
committed by ju6ge
parent cf58486cf5
commit e05f3d768f
17 changed files with 2954 additions and 10 deletions

View File

@@ -1,3 +1,4 @@
[package]
edition = "2021"
name = "plant-ctrl2"
@@ -63,6 +64,7 @@ log = "0.4.27"
embassy-net = { version = "0.7.1", default-features = false, features = [
"dhcpv4",
"log",
"medium-ip",
"medium-ethernet",
"tcp",
"udp",
@@ -123,7 +125,6 @@ embedded-hal-bus = { version = "0.3.0" }
#bq34z100 = { version = "0.3.0", default-features = false }
onewire = "0.4.0"
#strum = { version = "0.27.0", default-feature = false, features = ["derive"] }
measurements = "0.11.0"
ds323x = "0.6.0"
#json
@@ -156,16 +157,14 @@ embassy-embedded-hal = "0.5.0"
bincode = { version = "2.0.1", default-features = false, features = ["derive"] }
sntpc = { version = "0.6.0", default-features = false, features = ["log", "embassy-socket", "embassy-socket-ipv6"] }
option-lock = { version = "0.3.1", default-features = false }
#stay in sync with mcutie version here!
measurements = "0.11.1"
heapless = { version = "0.7.17", features = ["serde"] }
mcutie = { version = "0.3.0", default-features = false, features = ["log", "homeassistant"] }
mcutie = { path = "./src/mcutie_3_0_0/", default-features = false, features = ["log"] }
[patch.crates-io]
mcutie = { git = 'https://github.com/empirephoenix/mcutie.git' }
#bq34z100 = { path = "../../bq34z100_rust" }
[build-dependencies]
vergen = { version = "8.2.6", features = ["build", "git", "gitcl"] }
vergen = { version = "8.2.6", features = ["build", "git", "gitcl"] }