1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
//! # Debouncing Strategies
//!
//! The types in this module define the debouncing strategies available.
//!
//! The [`Strategy`] trait defines to what all strategies must conform. If a
//! custom strategy is desired, implement this trait and use the strategy in
//! a [`Debouncer`](crate::Debounced).
use crateStatus;
use ;
pub use Integrator;
pub use Shifter;
/// # Defining the Debouncing Algorithm
/// The strategy needs to do everything to debounce the input, but it should not
/// store the most recent state.
/// # Types Which Are Like Integers
///
/// These can `<<`, `>>`, [`==`, `>`, `<`](PartialOrd), and have a `MAX` and
/// `MIN`, so that Shift Register Debouncing is possible.
///
/// Although the [`MAX`](NumericType::MAX) and [`MIN`](NumericType::MIN) don't
/// have to be physically the largest value the type can store, `MAX > MIN` must
/// hold.
///
/// [`Shl`] must increase the value (towards the max) and [`Shr`] must decrease the
/// value and (towards the min).
impl_numeric_type!;