diff options
-rw-r--r-- | platforms/stm32/f1.yaml | 8 | ||||
-rw-r--r-- | platforms/stm32/f3.yaml | 8 | ||||
-rw-r--r-- | platforms/stm32/f4.yaml | 8 | ||||
-rw-r--r-- | platforms/stm32/wb.yaml | 4 | ||||
-rw-r--r-- | timer/SConscript | 4 |
5 files changed, 3 insertions, 29 deletions
diff --git a/platforms/stm32/f1.yaml b/platforms/stm32/f1.yaml index 8d4962b..ed97844 100644 --- a/platforms/stm32/f1.yaml +++ b/platforms/stm32/f1.yaml @@ -2,26 +2,18 @@ - periph: stm32_timer: TIM1: - type: v1 offset: 0x40012c00 TIM2: - type: v1 offset: 0x40000000 TIM3: - type: v1 offset: 0x40000400 TIM4: - type: v1 offset: 0x40000800 TIM5: - type: v1 offset: 0x40000c00 TIM6: - type: v1 offset: 0x40001000 TIM7: - type: v1 offset: 0x40001400 TIM8: - type: v1 offset: 0x40013400 diff --git a/platforms/stm32/f3.yaml b/platforms/stm32/f3.yaml index 8d4962b..ed97844 100644 --- a/platforms/stm32/f3.yaml +++ b/platforms/stm32/f3.yaml @@ -2,26 +2,18 @@ - periph: stm32_timer: TIM1: - type: v1 offset: 0x40012c00 TIM2: - type: v1 offset: 0x40000000 TIM3: - type: v1 offset: 0x40000400 TIM4: - type: v1 offset: 0x40000800 TIM5: - type: v1 offset: 0x40000c00 TIM6: - type: v1 offset: 0x40001000 TIM7: - type: v1 offset: 0x40001400 TIM8: - type: v1 offset: 0x40013400 diff --git a/platforms/stm32/f4.yaml b/platforms/stm32/f4.yaml index 96731e4..d362fa4 100644 --- a/platforms/stm32/f4.yaml +++ b/platforms/stm32/f4.yaml @@ -32,28 +32,20 @@ stm32_timer: TIM1: - type: v1 offset: 0x40010000 TIM2: - type: v1 offset: 0x40000000 TIM3: - type: v1 offset: 0x40000400 TIM4: - type: v1 offset: 0x40000800 TIM5: - type: v1 offset: 0x40000c00 TIM6: - type: v1 offset: 0x40001000 TIM7: - type: v1 offset: 0x40001400 TIM8: - type: v1 offset: 0x40010400 stm32_uart: diff --git a/platforms/stm32/wb.yaml b/platforms/stm32/wb.yaml index 65eafea..6aee549 100644 --- a/platforms/stm32/wb.yaml +++ b/platforms/stm32/wb.yaml @@ -30,16 +30,12 @@ periph: stm32_timer: TIM1: - type: v1 offset: 0x40012C00 TIM2: - type: v1 offset: 0x40000000 TIM16: - type: v1 offset: 0x40014400 TIM17: - type: v1 offset: 0x40014800 stm32_uart: diff --git a/timer/SConscript b/timer/SConscript index 7f5afbc..1490575 100644 --- a/timer/SConscript +++ b/timer/SConscript @@ -10,8 +10,10 @@ periph = env['PLATFORM_SPEC'].get('periph', {}) if 'stm32_timer' in periph: headers.append('stm32_timer.h') for name, data in periph['stm32_timer'].items(): + # ~everyone so far has v1 timers, don't require it until we need it + real_type = data.get('type', 'v1') instances.append({ - 'type': 'STM32_TIMER_t<STM32_TIMER_reg_%s_t>' % data['type'], + 'type': 'STM32_TIMER_t<STM32_TIMER_reg_%s_t>' % real_type, 'name': name, 'args': [data['offset']], }) |