1#![allow(dead_code)]
5
6use std::{time::Duration};
7
8use crate::reader::*;
9use crate::reader::processing::*;
10
11#[derive(Debug, Default)]
12struct ReaderRs {
13 timeout: Duration,
14 port: u8,
15 ncommand: u8,
16}
17
18impl CommandsCounter for ReaderRs {
19 fn commands_count(&self) -> u8 {
20 self.ncommand
21 }
22
23 fn increment_commands(&mut self) {
24 if self.commands_count() == u8::MAX {
25 self.ncommand = 0;
26 }
27 self.ncommand += 1;
28 }
29}
30
31impl ReaderRs {
32 pub fn open(&mut self) -> UemResult {
35 Ok(())
36 }
37
38 pub fn close(&mut self) -> core::result::Result<(), UemError> {
40 Ok(())
41 }
42
43 #[allow(unused_variables)]
44 pub fn send(&mut self, command: &Vec<u8>) -> UemResultVec {
46 Ok(Vec::new())
47 }
48}
49
50pub fn find_rs_readers() -> Vec<UemReader> {
53 Vec::new()
54}