A SCD40 (or 41) CO2 PPM Monitor with Web Interface for Raspberry Pi Pico W
Find a file
2025-03-17 21:13:50 +00:00
.cargo forgot the .cargo/config.toml file 2025-03-13 13:50:24 +00:00
cyw43-firmware Checking in initial baseline for project based on a combo 2025-03-13 13:28:48 +00:00
src OK! We have a workign thing! (Sorta). This now presents a web page which automatically updates the CO2, temp, and humitity values via JavaScript fetching from the Pico. The code diffs contain some gnarly stuff... I've thrown more debug prints and some sleeps in as I was hitting a sort of concurrently issue I think. I need to dig deeper into how these locks are working. Also I turned off keepalives as with the JS in the mix we were basically self-dossing... and adding more HTTP workers is bad solution as it just locks up the Pi (so those concurrently issues again?!) Anyway... it's definitely a milestone. Next up a spot of cleaning and debugging. 2025-03-17 21:13:50 +00:00
.gitignore remove .gitignore line as that doesn't work properly, the README gives a better alternative. 2025-03-17 17:38:37 +00:00
build.rs Checking in initial baseline for project based on a combo 2025-03-13 13:28:48 +00:00
Cargo.lock IT WORKS! OK, for small values of works, and the code is a mess. 2025-03-16 23:02:06 +00:00
Cargo.toml Update to explain what I needed to go to make this compile due to conflict in crates.io versions of embassy and picoserve 2025-03-17 13:51:36 +00:00
LICENSE-APACHE Checking in initial baseline for project based on a combo 2025-03-13 13:28:48 +00:00
LICENSE-MIT Checking in initial baseline for project based on a combo 2025-03-13 13:28:48 +00:00
memory.x The Pico W now serves a basic HTML page. 2025-03-14 17:42:07 +00:00
NOTICE.md Checking in initial baseline for project based on a combo 2025-03-13 13:28:48 +00:00
README.md Update to explain what I needed to go to make this compile due to conflict in crates.io versions of embassy and picoserve 2025-03-17 13:51:36 +00:00
rust-toolchain.toml The Pico W now serves a basic HTML page. 2025-03-14 17:42:07 +00:00

scd40-rusty-pi

A Raspberry Pi Pico W implementation of a SCD40 based CO2 PPM monitor, it has a web interface where the current values can be viewed. This is designed to work with an I2C SCD40 module.

This is a work in progress.

Compiling - picoserve mod

I struggled to get embassy + picoserve to compile together using crates.io sources. Despite the version number of embassy being the same it seems that using the git sources fixes the problem (the issue is with embassy-time-driver). But to achieve this I had to also edit the picoserve/Cargo.toml in the picoserve project, which I have checked out and sat alongside this project tree and referenced directly in this project's Cargo.toml. Hopefully in time the issue with the crates.io compatibility will be resolved.

diff --git a/picoserve/Cargo.toml b/picoserve/Cargo.toml
index 5bb0084..c9ad350 100644
--- a/picoserve/Cargo.toml
+++ b/picoserve/Cargo.toml
@@ -20,2 +20,2 @@ defmt = { version = "0.3.6", optional = true }
-embassy-net = { version = ">=0.6.0", optional = true, features = ["tcp", "proto-ipv4", "medium-ethernet"] }
-embassy-time = { version = ">=0.4.0", optional = true }
+embassy-net = { version = "0.7.0", git = "https://github.com/embassy-rs/embassy.git", optional = true, features = ["tcp", "proto-ipv4", "medium-ethernet"] }
+embassy-time = { version = "0.4.0", git = "https://github.com/embassy-rs/embassy.git", optional = true }

License

scd40-rusty-pi is licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.