1
1
use super :: * ;
2
+ use crate :: bb;
2
3
3
4
macro_rules! bus_enable {
4
- ( $PER: ident => ( $busenr: ident, $peren : ident ) ) => {
5
+ ( $PER: ident => ( $busenr: ident, $enbit : literal ) ) => {
5
6
impl Enable for crate :: pac:: $PER {
6
7
#[ inline( always) ]
7
8
fn enable( rcc: & RccRB ) {
8
- rcc. $busenr. modify( |_, w| w. $peren( ) . set_bit( ) ) ;
9
+ unsafe {
10
+ bb:: set( & rcc. $busenr, $enbit) ;
11
+ }
9
12
// Stall the pipeline to work around erratum 2.1.13 (DM00037591)
10
13
cortex_m:: asm:: dsb( ) ;
11
14
}
12
15
#[ inline( always) ]
13
16
fn disable( rcc: & RccRB ) {
14
- rcc. $busenr. modify( |_, w| w. $peren( ) . clear_bit( ) ) ;
17
+ unsafe {
18
+ bb:: clear( & rcc. $busenr, $enbit) ;
19
+ }
15
20
}
16
21
}
17
22
} ;
18
23
}
19
24
macro_rules! bus_lpenable {
20
- ( $PER: ident => ( $buslpenr: ident, $perlpen : ident ) ) => {
25
+ ( $PER: ident => ( $buslpenr: ident, $lpenbit : literal ) ) => {
21
26
impl LPEnable for crate :: pac:: $PER {
22
27
#[ inline( always) ]
23
28
fn low_power_enable( rcc: & RccRB ) {
24
- rcc. $buslpenr. modify( |_, w| w. $perlpen( ) . set_bit( ) ) ;
29
+ unsafe {
30
+ bb:: set( & rcc. $buslpenr, $lpenbit) ;
31
+ }
25
32
// Stall the pipeline to work around erratum 2.1.13 (DM00037591)
26
33
cortex_m:: asm:: dsb( ) ;
27
34
}
28
35
#[ inline( always) ]
29
36
fn low_power_disable( rcc: & RccRB ) {
30
- rcc. $buslpenr. modify( |_, w| w. $perlpen( ) . clear_bit( ) ) ;
37
+ unsafe {
38
+ bb:: clear( & rcc. $buslpenr, $lpenbit) ;
39
+ }
31
40
}
32
41
}
33
42
} ;
34
43
}
35
44
macro_rules! bus_reset {
36
- ( $PER: ident => ( $busrstr: ident, $perrst : ident ) ) => {
45
+ ( $PER: ident => ( $busrstr: ident, $resetbit : literal ) ) => {
37
46
impl Reset for crate :: pac:: $PER {
38
47
#[ inline( always) ]
39
48
fn reset( rcc: & RccRB ) {
40
- rcc. $busrstr. modify( |_, w| w. $perrst( ) . set_bit( ) ) ;
41
- rcc. $busrstr. modify( |_, w| w. $perrst( ) . clear_bit( ) ) ;
49
+ unsafe {
50
+ bb:: set( & rcc. $busrstr, $resetbit) ;
51
+ bb:: clear( & rcc. $busrstr, $resetbit) ;
52
+ }
42
53
}
43
54
}
44
55
} ;
45
56
}
46
57
47
58
macro_rules! bus {
48
- ( $( $PER: ident => ( $busenr: ident, $peren : ident , $ buslpenr: ident, $perlpen : ident , $ busrstr: ident, $perrst : ident ) , ) +) => {
59
+ ( $( $PER: ident => ( $busenr: ident, $buslpenr: ident, $busrstr: ident, $bit : literal ) , ) +) => {
49
60
$(
50
61
impl private:: Sealed for crate :: pac:: $PER { }
51
- bus_enable!( $PER => ( $busenr, $peren ) ) ;
52
- bus_lpenable!( $PER => ( $buslpenr, $perlpen ) ) ;
53
- bus_reset!( $PER => ( $busrstr, $perrst ) ) ;
62
+ bus_enable!( $PER => ( $busenr, $bit ) ) ;
63
+ bus_lpenable!( $PER => ( $buslpenr, $bit ) ) ;
64
+ bus_reset!( $PER => ( $busrstr, $bit ) ) ;
54
65
) +
55
66
}
56
67
}
57
68
58
69
bus ! {
59
- CRC => ( ahb1enr, crcen , ahb1lpenr, crclpen , ahb1rstr, crcrst ) ,
60
- DMA1 => ( ahb1enr, dma1en , ahb1lpenr, dma1lpen , ahb1rstr, dma1rst ) ,
61
- DMA2 => ( ahb1enr, dma2en , ahb1lpenr, dma2lpen , ahb1rstr, dma2rst ) ,
70
+ CRC => ( ahb1enr, ahb1lpenr, ahb1rstr, 12 ) ,
71
+ DMA1 => ( ahb1enr, ahb1lpenr, ahb1rstr, 21 ) ,
72
+ DMA2 => ( ahb1enr, ahb1lpenr, ahb1rstr, 22 ) ,
62
73
}
63
74
64
75
bus ! {
65
- GPIOA => ( ahb1enr, gpioaen , ahb1lpenr, gpioalpen , ahb1rstr, gpioarst ) ,
66
- GPIOB => ( ahb1enr, gpioben , ahb1lpenr, gpioblpen , ahb1rstr, gpiobrst ) ,
67
- GPIOC => ( ahb1enr, gpiocen , ahb1lpenr, gpioclpen , ahb1rstr, gpiocrst ) ,
68
- GPIOH => ( ahb1enr, gpiohen , ahb1lpenr, gpiohlpen , ahb1rstr, gpiohrst ) ,
76
+ GPIOA => ( ahb1enr, ahb1lpenr, ahb1rstr, 0 ) ,
77
+ GPIOB => ( ahb1enr, ahb1lpenr, ahb1rstr, 1 ) ,
78
+ GPIOC => ( ahb1enr, ahb1lpenr, ahb1rstr, 2 ) ,
79
+ GPIOH => ( ahb1enr, ahb1lpenr, ahb1rstr, 7 ) ,
69
80
}
70
81
71
82
#[ cfg( any( feature = "gpiod" , feature = "gpioe" ) ) ]
72
83
bus ! {
73
- GPIOD => ( ahb1enr, gpioden , ahb1lpenr, gpiodlpen , ahb1rstr, gpiodrst ) ,
74
- GPIOE => ( ahb1enr, gpioeen , ahb1lpenr, gpioelpen , ahb1rstr, gpioerst ) ,
84
+ GPIOD => ( ahb1enr, ahb1lpenr, ahb1rstr, 3 ) ,
85
+ GPIOE => ( ahb1enr, ahb1lpenr, ahb1rstr, 4 ) ,
75
86
}
76
87
#[ cfg( any( feature = "gpiof" , feature = "gpiog" ) ) ]
77
88
bus ! {
78
- GPIOF => ( ahb1enr, gpiofen , ahb1lpenr, gpioflpen , ahb1rstr, gpiofrst ) ,
79
- GPIOG => ( ahb1enr, gpiogen , ahb1lpenr, gpioglpen , ahb1rstr, gpiogrst ) ,
89
+ GPIOF => ( ahb1enr, ahb1lpenr, ahb1rstr, 5 ) ,
90
+ GPIOG => ( ahb1enr, ahb1lpenr, ahb1rstr, 6 ) ,
80
91
}
81
92
82
93
#[ cfg( feature = "gpioi" ) ]
83
94
bus ! {
84
- GPIOI => ( ahb1enr, gpioien , ahb1lpenr, gpioilpen , ahb1rstr, gpioirst ) ,
95
+ GPIOI => ( ahb1enr, ahb1lpenr, ahb1rstr, 8 ) ,
85
96
}
86
97
87
98
#[ cfg( any( feature = "gpioj" , feature = "gpiok" ) ) ]
88
99
bus ! {
89
- GPIOJ => ( ahb1enr, gpiojen , ahb1lpenr, gpiojlpen , ahb1rstr, gpiojrst ) ,
90
- GPIOK => ( ahb1enr, gpioken , ahb1lpenr, gpioklpen , ahb1rstr, gpiokrst ) ,
100
+ GPIOJ => ( ahb1enr, ahb1lpenr, ahb1rstr, 9 ) ,
101
+ GPIOK => ( ahb1enr, ahb1lpenr, ahb1rstr, 10 ) ,
91
102
}
92
103
93
104
#[ cfg( feature = "rng" ) ]
94
105
bus ! {
95
- RNG => ( ahb2enr, rngen , ahb2lpenr, rnglpen , ahb2rstr, rngrst ) ,
106
+ RNG => ( ahb2enr, ahb2lpenr, ahb2rstr, 6 ) ,
96
107
}
97
108
98
109
#[ cfg( feature = "otg-fs" ) ]
99
110
bus ! {
100
- OTG_FS_GLOBAL => ( ahb2enr, otgfsen , ahb2lpenr, otgfslpen , ahb2rstr, otgfsrst ) ,
111
+ OTG_FS_GLOBAL => ( ahb2enr, ahb2lpenr, ahb2rstr, 7 ) ,
101
112
}
102
113
103
114
#[ cfg( feature = "otg-hs" ) ]
104
115
bus ! {
105
- OTG_HS_GLOBAL => ( ahb1enr, otghsen , ahb1lpenr, otghslpen , ahb1rstr, otghsrst ) ,
116
+ OTG_HS_GLOBAL => ( ahb1enr, ahb1lpenr, ahb1rstr, 29 ) ,
106
117
}
107
118
108
119
#[ cfg( feature = "fmc" ) ]
109
120
bus ! {
110
- FMC => ( ahb3enr, fmcen , ahb3lpenr, fmclpen , ahb3rstr, fmcrst ) ,
121
+ FMC => ( ahb3enr, ahb3lpenr, ahb3rstr, 0 ) ,
111
122
}
112
123
113
124
// TODO: fix absent ahb3lpenr
114
125
#[ cfg( feature = "fsmc" ) ]
115
126
impl private:: Sealed for crate :: pac:: FSMC { }
116
127
#[ cfg( feature = "fsmc" ) ]
117
128
#[ cfg( any( feature = "stm32f427" , feature = "stm32f437" ) ) ]
118
- bus_enable ! ( FSMC => ( ahb3enr, fmcen ) ) ;
129
+ bus_enable ! ( FSMC => ( ahb3enr, 0 ) ) ;
119
130
#[ cfg( feature = "fsmc" ) ]
120
131
#[ cfg( not( any( feature = "stm32f427" , feature = "stm32f437" ) ) ) ]
121
- bus_enable ! ( FSMC => ( ahb3enr, fsmcen ) ) ;
132
+ bus_enable ! ( FSMC => ( ahb3enr, 0 ) ) ;
122
133
#[ cfg( feature = "fsmc" ) ]
123
134
#[ cfg( any( feature = "stm32f427" , feature = "stm32f437" ) ) ]
124
- bus_reset ! ( FSMC => ( ahb3rstr, fmcrst ) ) ;
135
+ bus_reset ! ( FSMC => ( ahb3rstr, 0 ) ) ;
125
136
#[ cfg( feature = "fsmc" ) ]
126
137
#[ cfg( not( any( feature = "stm32f427" , feature = "stm32f437" ) ) ) ]
127
- bus_reset ! ( FSMC => ( ahb3rstr, fsmcrst ) ) ;
138
+ bus_reset ! ( FSMC => ( ahb3rstr, 0 ) ) ;
128
139
129
140
bus ! {
130
- PWR => ( apb1enr, pwren , apb1lpenr, pwrlpen , apb1rstr, pwrrst ) ,
141
+ PWR => ( apb1enr, apb1lpenr, apb1rstr, 28 ) ,
131
142
}
132
143
133
144
bus ! {
134
- SPI1 => ( apb2enr, spi1en , apb2lpenr, spi1lpen , apb2rstr, spi1rst ) ,
135
- SPI2 => ( apb1enr, spi2en , apb1lpenr, spi2lpen , apb1rstr, spi2rst ) ,
145
+ SPI1 => ( apb2enr, apb2lpenr, apb2rstr, 12 ) ,
146
+ SPI2 => ( apb1enr, apb1lpenr, apb1rstr, 14 ) ,
136
147
}
137
148
#[ cfg( feature = "spi3" ) ]
138
149
bus ! {
139
- SPI3 => ( apb1enr, spi3en , apb1lpenr, spi3lpen , apb1rstr, spi3rst ) ,
150
+ SPI3 => ( apb1enr, apb1lpenr, apb1rstr, 15 ) ,
140
151
}
141
152
142
153
#[ cfg( feature = "spi4" ) ]
143
154
bus ! {
144
- SPI4 => ( apb2enr, spi4en , apb2lpenr, spi4lpen , apb2rstr, spi4rst ) ,
155
+ SPI4 => ( apb2enr, apb2lpenr, apb2rstr, 13 ) ,
145
156
}
146
157
147
158
#[ cfg( feature = "spi5" ) ]
148
159
bus ! {
149
- SPI5 => ( apb2enr, spi5en , apb2lpenr, spi5lpen , apb2rstr, spi5rst ) ,
160
+ SPI5 => ( apb2enr, apb2lpenr, apb2rstr, 20 ) ,
150
161
}
151
162
152
163
#[ cfg( feature = "spi6" ) ]
153
164
bus ! {
154
- SPI6 => ( apb2enr, spi6en , apb2lpenr, spi6lpen , apb2rstr, spi6rst ) ,
165
+ SPI6 => ( apb2enr, apb2lpenr, apb2rstr, 21 ) ,
155
166
}
156
167
157
168
bus ! {
158
- I2C1 => ( apb1enr, i2c1en , apb1lpenr, i2c1lpen , apb1rstr, i2c1rst ) ,
159
- I2C2 => ( apb1enr, i2c2en , apb1lpenr, i2c2lpen , apb1rstr, i2c2rst ) ,
169
+ I2C1 => ( apb1enr, apb1lpenr, apb1rstr, 21 ) ,
170
+ I2C2 => ( apb1enr, apb1lpenr, apb1rstr, 22 ) ,
160
171
}
161
172
#[ cfg( feature = "i2c3" ) ]
162
173
bus ! {
163
- I2C3 => ( apb1enr, i2c3en , apb1lpenr, i2c3lpen , apb1rstr, i2c3rst ) ,
174
+ I2C3 => ( apb1enr, apb1lpenr, apb1rstr, 23 ) ,
164
175
}
165
176
#[ cfg( feature = "fmpi2c1" ) ]
166
177
bus ! {
167
- FMPI2C1 => ( apb1enr, fmpi2c1en , apb1lpenr, fmpi2c1lpen , apb1rstr, fmpi2c1rst ) ,
178
+ FMPI2C1 => ( apb1enr, apb1lpenr, apb1rstr, 24 ) ,
168
179
}
169
180
170
- // TODO: fix uart2rst, uart3rst
171
181
bus ! {
172
- USART1 => ( apb2enr, usart1en , apb2lpenr, usart1lpen , apb2rstr, usart1rst ) ,
173
- USART2 => ( apb1enr, usart2en , apb1lpenr, usart2lpen , apb1rstr, uart2rst ) ,
174
- USART6 => ( apb2enr, usart6en , apb2lpenr, usart6lpen , apb2rstr, usart6rst ) ,
182
+ USART1 => ( apb2enr, apb2lpenr, apb2rstr, 4 ) ,
183
+ USART2 => ( apb1enr, apb1lpenr, apb1rstr, 17 ) ,
184
+ USART6 => ( apb2enr, apb2lpenr, apb2rstr, 5 ) ,
175
185
}
176
186
#[ cfg( feature = "usart3" ) ]
177
- #[ cfg( any( feature = "stm32f412" , feature = "stm32f413" , feature = "stm32f423" ) ) ]
178
187
bus ! {
179
- USART3 => ( apb1enr, usart3en , apb1lpenr, usart3lpen , apb1rstr, usart3rst ) ,
188
+ USART3 => ( apb1enr, apb1lpenr, apb1rstr, 18 ) ,
180
189
}
181
- # [ cfg ( feature = "usart3" ) ]
182
- #[ cfg( not ( any( feature = "stm32f412 " , feature = "stm32f413" , feature = "stm32f423" ) ) ) ]
190
+
191
+ #[ cfg( any( feature = "uart4 " , feature = "uart5" ) ) ]
183
192
bus ! {
184
- USART3 => ( apb1enr, usart3en, apb1lpenr, usart3lpen, apb1rstr, uart3rst) ,
193
+ UART4 => ( apb1enr, apb1lpenr, apb1rstr, 19 ) ,
194
+ UART5 => ( apb1enr, apb1lpenr, apb1rstr, 20 ) ,
185
195
}
186
196
187
- #[ cfg( feature = "uart4" ) ]
188
- impl private:: Sealed for crate :: pac:: UART4 { }
189
- #[ cfg( feature = "uart4" ) ]
190
- bus_enable ! ( UART4 => ( apb1enr, uart4en) ) ;
191
- #[ cfg( feature = "uart5" ) ]
192
- impl private:: Sealed for crate :: pac:: UART5 { }
193
- #[ cfg( feature = "uart5" ) ]
194
- bus_enable ! ( UART5 => ( apb1enr, uart5en) ) ;
195
-
196
197
#[ cfg( any( feature = "uart7" , feature = "uart8" ) ) ]
197
198
bus ! {
198
- UART7 => ( apb1enr, uart7en , apb1lpenr, uart7lpen , apb1rstr, uart7rst ) ,
199
- UART8 => ( apb1enr, uart8en , apb1lpenr, uart8lpen , apb1rstr, uart8rst ) ,
199
+ UART7 => ( apb1enr, apb1lpenr, apb1rstr, 30 ) ,
200
+ UART8 => ( apb1enr, apb1lpenr, apb1rstr, 31 ) ,
200
201
}
201
202
#[ cfg( any( feature = "uart9" , feature = "uart10" ) ) ]
202
203
bus ! {
203
- UART9 => ( apb2enr, uart9en , apb2lpenr, uart9lpen , apb2rstr, uart9rst ) ,
204
- UART10 => ( apb2enr, uart10en , apb2lpenr, uart10lpen , apb2rstr, uart10rst ) ,
204
+ UART9 => ( apb2enr, apb2lpenr, apb2rstr, 6 ) ,
205
+ UART10 => ( apb2enr, apb2lpenr, apb2rstr, 7 ) ,
205
206
}
206
207
207
208
#[ cfg( any( feature = "can1" , feature = "can2" ) ) ]
208
209
bus ! {
209
- CAN1 => ( apb1enr, can1en , apb1lpenr, can1lpen , apb1rstr, can1rst ) ,
210
- CAN2 => ( apb1enr, can2en , apb1lpenr, can2lpen , apb1rstr, can2rst ) ,
210
+ CAN1 => ( apb1enr, apb1lpenr, apb1rstr, 25 ) ,
211
+ CAN2 => ( apb1enr, apb1lpenr, apb1rstr, 26 ) ,
211
212
}
212
213
#[ cfg( feature = "dac" ) ]
213
214
bus ! {
214
- DAC => ( apb1enr, dacen , apb1lpenr, daclpen , apb1rstr, dacrst ) ,
215
+ DAC => ( apb1enr, apb1lpenr, apb1rstr, 29 ) ,
215
216
}
216
217
217
218
bus ! {
218
- SYSCFG => ( apb2enr, syscfgen , apb2lpenr, syscfglpen , apb2rstr, syscfgrst ) ,
219
+ SYSCFG => ( apb2enr, apb2lpenr, apb2rstr, 14 ) ,
219
220
}
220
221
221
222
bus ! {
222
- ADC1 => ( apb2enr, adc1en , apb2lpenr, adc1lpen , apb2rstr, adcrst ) ,
223
+ ADC1 => ( apb2enr, apb2lpenr, apb2rstr, 8 ) ,
223
224
}
224
225
225
- #[ cfg( any( feature = "adc2" , feature = "adc3" ) ) ]
226
- bus ! {
227
- ADC2 => ( apb2enr, adc2en, apb2lpenr, adc2lpen, apb2rstr, adcrst) ,
228
- ADC3 => ( apb2enr, adc3en, apb2lpenr, adc3lpen, apb2rstr, adcrst) ,
229
- }
226
+ #[ cfg( feature = "adc2" ) ]
227
+ impl private:: Sealed for crate :: pac:: ADC2 { }
228
+ #[ cfg( feature = "adc2" ) ]
229
+ bus_enable ! ( ADC2 => ( apb2enr, 9 ) ) ;
230
+ #[ cfg( feature = "adc2" ) ]
231
+ bus_lpenable ! ( ADC2 => ( apb2lpenr, 9 ) ) ;
232
+ #[ cfg( feature = "adc2" ) ]
233
+ bus_reset ! ( ADC2 => ( apb2rstr, 8 ) ) ;
234
+
235
+ #[ cfg( feature = "adc3" ) ]
236
+ impl private:: Sealed for crate :: pac:: ADC3 { }
237
+ #[ cfg( feature = "adc3" ) ]
238
+ bus_enable ! ( ADC3 => ( apb2enr, 10 ) ) ;
239
+ #[ cfg( feature = "adc3" ) ]
240
+ bus_lpenable ! ( ADC3 => ( apb2lpenr, 10 ) ) ;
241
+ #[ cfg( feature = "adc3" ) ]
242
+ bus_reset ! ( ADC3 => ( apb2rstr, 8 ) ) ;
230
243
231
244
#[ cfg( feature = "sdio" ) ]
232
245
bus ! {
233
- SDIO => ( apb2enr, sdioen , apb2lpenr, sdiolpen , apb2rstr, sdiorst ) ,
246
+ SDIO => ( apb2enr, apb2lpenr, apb2rstr, 11 ) ,
234
247
}
235
248
236
249
bus ! {
237
- TIM1 => ( apb2enr, tim1en , apb2lpenr, tim1lpen , apb2rstr, tim1rst ) ,
238
- TIM5 => ( apb1enr, tim5en , apb1lpenr, tim5lpen , apb1rstr, tim5rst ) ,
239
- TIM9 => ( apb2enr, tim9en , apb2lpenr, tim9lpen , apb2rstr, tim9rst ) ,
240
- TIM11 => ( apb2enr, tim11en , apb2lpenr, tim11lpen , apb2rstr, tim11rst ) ,
250
+ TIM1 => ( apb2enr, apb2lpenr, apb2rstr, 0 ) ,
251
+ TIM5 => ( apb1enr, apb1lpenr, apb1rstr, 3 ) ,
252
+ TIM9 => ( apb2enr, apb2lpenr, apb2rstr, 16 ) ,
253
+ TIM11 => ( apb2enr, apb2lpenr, apb2rstr, 18 ) ,
241
254
}
242
255
243
256
#[ cfg( any(
@@ -259,10 +272,10 @@ bus! {
259
272
feature = "stm32f479"
260
273
) ) ]
261
274
bus ! {
262
- TIM2 => ( apb1enr, tim2en , apb1lpenr, tim2lpen , apb1rstr, tim2rst ) ,
263
- TIM3 => ( apb1enr, tim3en , apb1lpenr, tim3lpen , apb1rstr, tim3rst ) ,
264
- TIM4 => ( apb1enr, tim4en , apb1lpenr, tim4lpen , apb1rstr, tim4rst ) ,
265
- TIM10 => ( apb2enr, tim10en , apb2lpenr, tim10lpen , apb2rstr, tim10rst ) ,
275
+ TIM2 => ( apb1enr, apb1lpenr, apb1rstr, 0 ) ,
276
+ TIM3 => ( apb1enr, apb1lpenr, apb1rstr, 1 ) ,
277
+ TIM4 => ( apb1enr, apb1lpenr, apb1rstr, 2 ) ,
278
+ TIM10 => ( apb2enr, apb2lpenr, apb2rstr, 17 ) ,
266
279
}
267
280
268
281
#[ cfg( any(
@@ -283,7 +296,7 @@ bus! {
283
296
feature = "stm32f479"
284
297
) ) ]
285
298
bus ! {
286
- TIM6 => ( apb1enr, tim6en , apb1lpenr, tim6lpen , apb1rstr, tim6rst ) ,
299
+ TIM6 => ( apb1enr, apb1lpenr, apb1rstr, 4 ) ,
287
300
}
288
301
289
302
#[ cfg( any(
@@ -303,9 +316,9 @@ bus! {
303
316
feature = "stm32f479"
304
317
) ) ]
305
318
bus ! {
306
- TIM7 => ( apb1enr, tim7en , apb1lpenr, tim7lpen , apb1rstr, tim7rst ) ,
307
- TIM8 => ( apb2enr, tim8en , apb2lpenr, tim8lpen , apb2rstr, tim8rst ) ,
308
- TIM12 => ( apb1enr, tim12en , apb1lpenr, tim12lpen , apb1rstr, tim12rst ) ,
309
- TIM13 => ( apb1enr, tim13en , apb1lpenr, tim13lpen , apb1rstr, tim13rst ) ,
310
- TIM14 => ( apb1enr, tim14en , apb1lpenr, tim14lpen , apb1rstr, tim14rst ) ,
319
+ TIM7 => ( apb1enr, apb1lpenr, apb1rstr, 5 ) ,
320
+ TIM8 => ( apb2enr, apb2lpenr, apb2rstr, 1 ) ,
321
+ TIM12 => ( apb1enr, apb1lpenr, apb1rstr, 6 ) ,
322
+ TIM13 => ( apb1enr, apb1lpenr, apb1rstr, 7 ) ,
323
+ TIM14 => ( apb1enr, apb1lpenr, apb1rstr, 8 ) ,
311
324
}
0 commit comments