Make print statements more clear during testing

This commit is contained in:
Blizzard Finnegan 2023-05-15 14:18:02 -04:00
parent 57b199dbfd
commit 3ad392b68c
No known key found for this signature in database
GPG key ID: CA68D42A2F00D450
3 changed files with 4 additions and 6 deletions

View file

@ -317,7 +317,7 @@ impl Device{
//Re-open serial connection?
_ = self.usb_tty.read_from_device(Some("["));
for bp_count in 1..=local_bp_cycles{
log::info!("Running bp {} on device {} ...",bp_count,self.serial);
log::info!("Running bp {} on device {} ...",self.bps,self.serial);
self.start_bp();
let bp_start = self.is_bp_running();
log::trace!("{:?}",bp_start);
@ -331,7 +331,7 @@ impl Device{
}
}
for temp_count in 1..=local_temp_cycles{
log::info!("Running temp {} on device {} ...",temp_count,self.serial);
log::info!("Running temp {} on device {} ...",self.temps,self.serial);
let temp_start = self.start_temp().is_temp_running();
let temp_end = self.stop_temp().is_temp_running();
if temp_start != temp_end {
@ -340,7 +340,7 @@ impl Device{
self.save_values();
}
}
log::info!("Rebooting {}",self.serial);
log::info!("Rebooting {} for the {}th time",self.serial, self.reboots);
self.reboot();
self.reboots += 1;
self.save_values();

View file

@ -9,7 +9,7 @@ impl GpioPins{
let mut output = Self { unassigned_addresses:Vec::new() };
for pin in RELAY_ADDRESSES.iter(){
let gpio_object = rppal::gpio::Gpio::new().unwrap();
let pin_object = gpio_object.get(pin).unwrap().into_output();
let mut pin_object = gpio_object.get(pin.clone()).unwrap().into_output();
pin_object.set_low();
output.unassigned_addresses.push(*pin);
}

View file

@ -1,5 +1,3 @@
use serialport;
use crate::serialport::SerialPortInfo;
use seymour_poc_rust::{device::Device, tty::{self,TTY,Response},log_facade,gpio_facade::GpioPins};
use std::io::{stdin,stdout,Write};
use std::thread::{self, JoinHandle};