show build version in html
This commit is contained in:
@@ -621,6 +621,7 @@ impl PlantCtrlBoardInteraction for PlantCtrlBoard<'_> {
|
||||
qos: AtLeastOnce,
|
||||
retain: true,
|
||||
}),
|
||||
client_id: Some("plantctrl"),
|
||||
keep_alive_interval : Some(Duration::from_secs(60*60*2)),
|
||||
//room for improvement
|
||||
..Default::default()
|
||||
@@ -716,14 +717,22 @@ impl PlantCtrlBoardInteraction for PlantCtrlBoard<'_> {
|
||||
println!("Some error assembling full_topic 2");
|
||||
bail!("Some error assembling full_topic 2")
|
||||
};
|
||||
client.publish(
|
||||
let publish = client.publish(
|
||||
&full_topic,
|
||||
embedded_svc::mqtt::client::QoS::ExactlyOnce,
|
||||
true,
|
||||
message,
|
||||
)?;
|
||||
);
|
||||
|
||||
match publish {
|
||||
OkStd(_) => return Ok(()),
|
||||
Err(err) => {
|
||||
println!("Error during mqtt send on topic {} with message {:#?} error is {:?}",full_topic, message, err);
|
||||
return Err(err)?
|
||||
},
|
||||
}
|
||||
|
||||
return Ok(());
|
||||
;
|
||||
}
|
||||
|
||||
fn state_charge_percent(&mut self) -> Result<u8> {
|
||||
|
||||
Reference in New Issue
Block a user