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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
use crate::gpio;
use crate::i2c;
use crate::platform;
pub trait Feather: platform::Platform {
type MainLed: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type MainI2cMapping: i2c::I2cBusMapping<Self::SDA, Self::SCL>;
type SDA: gpio::IntoOpenDrainOutputPin<Error = Self::Error>
+ gpio::IntoFloatingInputPin<Error = Self::Error>;
type SCL: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type D2: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type D3: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type D4: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type D5: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type D6: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type D7: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type D8: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type P0;
type TX: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type RX: gpio::IntoFloatingInputPin<Error = Self::Error>;
type MISO: gpio::IntoFloatingInputPin<Error = Self::Error>;
type MOSI: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type SCK: gpio::IntoPushPullOutputPin<Error = Self::Error>;
type A5: gpio::IntoFloatingInputPin<Error = Self::Error>;
type A4: gpio::IntoFloatingInputPin<Error = Self::Error>;
type A3: gpio::IntoFloatingInputPin<Error = Self::Error>;
type A2: gpio::IntoFloatingInputPin<Error = Self::Error>;
type A1: gpio::IntoFloatingInputPin<Error = Self::Error>;
type A0: gpio::IntoFloatingInputPin<Error = Self::Error>;
fn take_main_led(&mut self) -> Self::MainLed;
fn take_main_i2c(
&mut self,
) -> <Self::MainI2cMapping as i2c::I2cBusMapping<Self::SDA, Self::SCL>>::Bus;
fn take_sda(&mut self) -> Self::SDA;
fn take_scl(&mut self) -> Self::SCL;
fn take_d2(&mut self) -> Self::D2;
fn take_d3(&mut self) -> Self::D3;
fn take_d4(&mut self) -> Self::D4;
fn take_d5(&mut self) -> Self::D5;
fn take_d6(&mut self) -> Self::D6;
fn take_d7(&mut self) -> Self::D7;
fn take_d8(&mut self) -> Self::D8;
fn take_p0(&mut self) -> Self::P0;
fn take_tx(&mut self) -> Self::TX;
fn take_rx(&mut self) -> Self::RX;
fn take_miso(&mut self) -> Self::MISO;
fn take_mosi(&mut self) -> Self::MOSI;
fn take_sck(&mut self) -> Self::SCK;
fn take_a5(&mut self) -> Self::A5;
fn take_a4(&mut self) -> Self::A4;
fn take_a3(&mut self) -> Self::A3;
fn take_a2(&mut self) -> Self::A2;
fn take_a1(&mut self) -> Self::A1;
fn take_a0(&mut self) -> Self::A0;
}