File tree Expand file tree Collapse file tree 3 files changed +16
-2
lines changed Expand file tree Collapse file tree 3 files changed +16
-2
lines changed Original file line number Diff line number Diff line change 27
27
/* Each of the 4 channels uses 1 nibble of CCER */
28
28
#define CCER_MASK (TIM_CC1P | TIM_CC1E)
29
29
30
+ #ifdef TIM2_CTLR1_CEN
31
+ /* ch32fun.h uses a different set of names for the CH32V00x series. Remap. */
32
+ typedef GPTM_TypeDef TIM_TypeDef ;
33
+ #define TIM_CEN TIM2_CTLR1_CEN
34
+ #define TIM_OC1M TIM2_CHCTLR1_OC1M
35
+ #define TIM_OC2M TIM2_CHCTLR1_OC2M
36
+ #define TIM_OC3M TIM2_CHCTLR2_OC3M
37
+ #define TIM_OC4M TIM2_CHCTLR2_OC4M
38
+ #define TIM_CC1P TIM2_CCER_CC1P
39
+ #define TIM_CC1E TIM2_CCER_CC1E
40
+ #define TIM_CC1E TIM2_CCER_CC1E
41
+ #define TIM_ARPE TIM2_CTLR1_ARPE
42
+ #endif
43
+
30
44
struct pwm_wch_gptm_config {
31
45
TIM_TypeDef * regs ;
32
46
const struct device * clock_dev ;
Original file line number Diff line number Diff line change 13
13
#endif
14
14
15
15
#if defined(CONFIG_SOC_SERIES_CH32V00X )
16
- #define CH32V003 1
16
+ #define CH32V00x 1
17
17
#include <ch32fun.h>
18
18
#endif
19
19
Original file line number Diff line number Diff line change @@ -265,7 +265,7 @@ manifest:
265
265
groups :
266
266
- hal
267
267
- name : hal_wch
268
- revision : 941f5182b5577d168e0cbcc0c9dd26294c1806a5
268
+ revision : 6dd313768b5f4cc69baeac4ce6e59f2038eb8ce5
269
269
path : modules/hal/wch
270
270
groups :
271
271
- hal
You can’t perform that action at this time.
0 commit comments