@@ -5,7 +5,7 @@ use crate::gpio::gpiob::*;
5
5
#[ allow( unused) ]
6
6
#[ cfg( feature = "device-selected" ) ]
7
7
use crate :: gpio:: gpioc:: * ;
8
- #[ cfg( feature = "stm32f030xc " ) ]
8
+ #[ cfg( feature = "stm32f030 " ) ]
9
9
use crate :: gpio:: gpiod:: * ;
10
10
#[ allow( unused) ]
11
11
#[ cfg( feature = "device-selected" ) ]
@@ -58,31 +58,7 @@ pins! {
58
58
PA12 => { AF5 : SdaPin <I2C1 >}
59
59
}
60
60
61
- #[ cfg( feature = "stm32f030x6" ) ]
62
- pins ! {
63
- PA2 => { AF1 : TxPin <USART1 >} ,
64
- PA3 => { AF1 : RxPin <USART1 >} ,
65
- PA14 => { AF1 : TxPin <USART1 >} ,
66
- PA15 => { AF1 : RxPin <USART1 >} ,
67
- PB13 => { AF0 : SckPin <SPI1 >} ,
68
- PB14 => { AF0 : MisoPin <SPI1 >} ,
69
- PB15 => { AF0 : MosiPin <SPI1 >}
70
- }
71
-
72
- #[ cfg( any(
73
- feature = "stm32f030x8" ,
74
- feature = "stm32f030xc" ,
75
- feature = "stm32f042" ,
76
- feature = "stm32f070" ,
77
- ) ) ]
78
- pins ! {
79
- PA2 => { AF1 : TxPin <USART2 >} ,
80
- PA3 => { AF1 : RxPin <USART2 >} ,
81
- PA14 => { AF1 : TxPin <USART2 >} ,
82
- PA15 => { AF1 : RxPin <USART2 >}
83
- }
84
-
85
- #[ cfg( any( feature = "stm32f030xc" , feature = "stm32f070xb" ) ) ]
61
+ #[ cfg( any( feature = "stm32f030" , feature = "stm32f070" ) ) ]
86
62
pins ! {
87
63
PA0 => { AF4 : TxPin <USART4 >} ,
88
64
PA1 => { AF4 : RxPin <USART4 >} ,
@@ -105,7 +81,7 @@ pins! {
105
81
}
106
82
}
107
83
108
- #[ cfg( feature = "stm32f030xc " ) ]
84
+ #[ cfg( feature = "stm32f030 " ) ]
109
85
pins ! {
110
86
PA4 => { AF5 : TxPin <USART6 >} ,
111
87
PA5 => { AF5 : RxPin <USART6 >} ,
@@ -117,6 +93,29 @@ pins! {
117
93
PD2 => { AF2 : TxPin <USART5 >}
118
94
}
119
95
96
+ #[ cfg( feature = "stm32f030x6" ) ]
97
+ pins ! {
98
+ PA2 => { AF1 : TxPin <USART1 >} ,
99
+ PA3 => { AF1 : RxPin <USART1 >} ,
100
+ PA14 => { AF1 : TxPin <USART1 >} ,
101
+ PA15 => { AF1 : RxPin <USART1 >} ,
102
+ PB13 => { AF0 : SckPin <SPI1 >} ,
103
+ PB14 => { AF0 : MisoPin <SPI1 >} ,
104
+ PB15 => { AF0 : MosiPin <SPI1 >}
105
+ }
106
+
107
+ #[ cfg( any(
108
+ feature = "stm32f030x8" ,
109
+ feature = "stm32f030xc" ,
110
+ feature = "stm32f042" ,
111
+ feature = "stm32f070" ,
112
+ ) ) ]
113
+ pins ! {
114
+ PA2 => { AF1 : TxPin <USART2 >} ,
115
+ PA3 => { AF1 : RxPin <USART2 >} ,
116
+ PA14 => { AF1 : TxPin <USART2 >} ,
117
+ PA15 => { AF1 : RxPin <USART2 >}
118
+ }
120
119
#[ cfg( any(
121
120
feature = "stm32f030x8" ,
122
121
feature = "stm32f030xc" ,
@@ -132,39 +131,41 @@ pins! {
132
131
feature = "stm32f030x6" ,
133
132
feature = "stm32f030xc" ,
134
133
feature = "stm32f042" ,
135
- feature = "stm32f070x6" ,
134
+ feature = "stm32f070x6"
136
135
) ) ]
137
136
pins ! {
138
137
PA9 => { AF4 : SclPin <I2C1 >} ,
139
138
PA10 => { AF4 : SdaPin <I2C1 >}
140
139
}
141
140
142
141
#[ cfg( any(
143
- feature = "stm32f042" ,
144
142
feature = "stm32f030x6" ,
145
- feature = "stm32f030x8" ,
146
- feature = "stm32f030xc" ,
143
+ feature = "stm32f042" ,
147
144
feature = "stm32f070xb"
148
145
) ) ]
149
146
pins ! {
150
147
PB10 => { AF1 : SclPin <I2C1 >} ,
151
148
PB11 => { AF1 : SdaPin <I2C1 >}
152
149
}
153
150
151
+ #[ cfg( any( feature = "stm32f030x8" , feature = "stm32f030xc" ) ) ]
152
+ pins ! {
153
+ PB10 => { AF1 : SclPin <I2C2 >} ,
154
+ PB11 => { AF1 : SdaPin <I2C1 >}
155
+ }
154
156
#[ cfg( any(
155
157
feature = "stm32f042" ,
156
158
feature = "stm32f030xc" ,
157
159
feature = "stm32f070x6" ,
158
160
) ) ]
159
161
pins ! {
160
- PF1 => { AF1 : SclPin <I2C1 >} ,
161
162
PF0 => { AF1 : SdaPin <I2C1 >}
163
+ PF1 => { AF1 : SclPin <I2C1 >} ,
162
164
}
163
165
164
166
#[ cfg( any(
165
167
feature = "stm32f042" ,
166
168
feature = "stm32f030xc" ,
167
- feature = "stm32f030xc" ,
168
169
feature = "stm32f070xb"
169
170
) ) ]
170
171
pins ! {
0 commit comments