Add serde
This commit is contained in:
parent
38b5077ad6
commit
4f2a8dba5d
3 changed files with 19 additions and 1 deletions
|
@ -24,6 +24,8 @@ pio = "0.2.1"
|
||||||
fixed = "1.23.1"
|
fixed = "1.23.1"
|
||||||
fixed-macro = "1.2"
|
fixed-macro = "1.2"
|
||||||
|
|
||||||
|
serde = { version = "1.0.203", default-features = false, features = ["derive"] }
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
embassy-executor = { version = "0.5.0", features = ["task-arena-size-32768", "arch-cortex-m", "executor-thread", "executor-interrupt", "integrated-timers"] }
|
embassy-executor = { version = "0.5.0", features = ["task-arena-size-32768", "arch-cortex-m", "executor-thread", "executor-interrupt", "integrated-timers"] }
|
||||||
embassy-futures = { version = "0.1.1" }
|
embassy-futures = { version = "0.1.1" }
|
||||||
|
|
15
renovate.json
Normal file
15
renovate.json
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
{
|
||||||
|
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
|
||||||
|
"extends": [
|
||||||
|
"config:base"
|
||||||
|
],
|
||||||
|
"packageRules": [
|
||||||
|
{
|
||||||
|
"matchUpdateTypes": [
|
||||||
|
"minor",
|
||||||
|
"patch"
|
||||||
|
],
|
||||||
|
"automerge": true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
|
@ -4,6 +4,7 @@ use embassy_rp::pio::{Common, Instance, PioPin, StateMachine};
|
||||||
|
|
||||||
mod dht;
|
mod dht;
|
||||||
use dht::DhtPio;
|
use dht::DhtPio;
|
||||||
|
use serde::{Deserialize, Serialize};
|
||||||
|
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub enum DhtError {
|
pub enum DhtError {
|
||||||
|
@ -15,7 +16,7 @@ pub enum DhtError {
|
||||||
ReadError,
|
ReadError,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug)]
|
#[derive(Debug, Deserialize, Serialize)]
|
||||||
pub struct DhtResult {
|
pub struct DhtResult {
|
||||||
pub temperature: f32,
|
pub temperature: f32,
|
||||||
pub humidity: f32,
|
pub humidity: f32,
|
||||||
|
|
Loading…
Reference in a new issue