use std::time::Duration;
use fiscalprinter::{FiscalPrinter, ReportType, Report, ReportAction};
mod pnp;
fn main() {
let mut _handler = serialport::new("/dev/ttyUSB0", 9600)
.timeout(Duration::from_millis(10))
.open().expect("Failed to open port");
let mut _pnp_driver: pnp::printer::Printer = FiscalPrinter::new();
let _x_result = _pnp_driver.print_report(&mut _handler, Report::new(ReportType::XReport));
println!("Result of X Report {:?}", _x_result);
}