Skip to content

Commit

Permalink
docs: Fix README docs
Browse files Browse the repository at this point in the history
  • Loading branch information
BroderickCarlin committed Dec 9, 2024
1 parent 2889ddc commit 95b9302
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ impl ToByteArray for Configuration {
type Array = [u8; 3];
type Error = &'static str;

fn to_bytes(&self) -> Result<Self::Array, Self::Error> {
fn to_bytes(self) -> Result<Self::Array, Self::Error> {
let mut bytes = [0u8; 3];
bytes[0..2].copy_from_slice(&self.sample_rate.to_be_bytes());
bytes[2] = self.enabled as u8;
Expand All @@ -141,7 +141,7 @@ impl ToByteArray for CalibrationParams {
type Array = [u8; 4];
type Error = &'static str;

fn to_bytes(&self) -> Result<Self::Array, Self::Error> {
fn to_bytes(self) -> Result<Self::Array, Self::Error> {
Ok(self.reference_temp.to_be_bytes())
}
}
Expand Down Expand Up @@ -169,7 +169,7 @@ impl Command for Calibrate {
0xF0.into()
}

fn invoking_parameters(&self) -> Self::CommandParameters {
fn invoking_parameters(self) -> Self::CommandParameters {
CalibrationParams {
reference_temp: 25.0,
}
Expand Down

0 comments on commit 95b9302

Please sign in to comment.