mirror of
https://github.com/apache/nuttx.git
synced 2026-05-20 04:16:35 +08:00
Merged in raiden00/nuttx_pe (pull request #734)
stm32_pwm: break and lock configuration and some cosmetics Approved-by: GregoryN <gnutt@nuttx.org>
This commit is contained in:
committed by
GregoryN
parent
632bba3af8
commit
6e18a32b3f
@@ -3158,7 +3158,7 @@ config STM32_ONESHOT_MAXTIMERS
|
||||
timers that you can use.
|
||||
|
||||
config STM32_PWM_LL_OPS
|
||||
bool "PWM low-lewel operations"
|
||||
bool "PWM low-level operations"
|
||||
default n
|
||||
---help---
|
||||
Enable low-level PWM ops.
|
||||
|
||||
@@ -1073,7 +1073,7 @@
|
||||
#define GTIM_EGR_CC2G (1 << 2) /* Bit 2: Capture/compare 2 generation (TIM2-5,9,12,&15 only) */
|
||||
#define GTIM_EGR_CC3G (1 << 3) /* Bit 3: Capture/compare 3 generation (TIM2-5 only) */
|
||||
#define GTIM_EGR_CC4G (1 << 4) /* Bit 4: Capture/compare 4 generation (TIM2-5 only) */
|
||||
#define GTIM_EGR_COMIG (1 << 5) /* Bit 5: Capture/Compare control update generation (TIM15-17 only) */
|
||||
#define GTIM_EGR_COMG (1 << 5) /* Bit 5: Capture/Compare control update generation (TIM15-17 only) */
|
||||
#define GTIM_EGR_TG (1 << 6) /* Bit 6: Trigger generation (TIM2-5,9,12&16-17 only) */
|
||||
#define GTIM_EGR_BG (1 << 7) /* Bit 7: Break generation (TIM15-17 only) */
|
||||
|
||||
@@ -1245,7 +1245,7 @@
|
||||
|
||||
#define GTIM_RCR_REP_MAX 128
|
||||
|
||||
/* Break and dead-time register (TIM15-17 only */
|
||||
/* Break and dead-time register (TIM15-17 only) */
|
||||
|
||||
#define GTIM_BDTR_DTG_SHIFT (0) /* Bits 7:0 [7:0]: Dead-Time Generator set-up */
|
||||
#define GTIM_BDTR_DTG_MASK (0xff << GTIM_BDTR_DTG_SHIFT)
|
||||
|
||||
+291
-116
File diff suppressed because it is too large
Load Diff
@@ -928,7 +928,6 @@ enum stm32_chan_e
|
||||
struct pwm_lowerhalf_s;
|
||||
struct stm32_pwm_ops_s
|
||||
{
|
||||
|
||||
/* Update CCR register */
|
||||
|
||||
int (*ccr_update)(FAR struct pwm_lowerhalf_s *dev, uint8_t index, uint32_t ccr);
|
||||
@@ -956,6 +955,16 @@ struct stm32_pwm_ops_s
|
||||
/* PWM configure */
|
||||
|
||||
int (*configure)(FAR struct pwm_lowerhalf_s *dev);
|
||||
|
||||
/* Software break */
|
||||
|
||||
int (*soft_break)(FAR struct pwm_lowerhalf_s *dev, bool state);
|
||||
|
||||
#ifdef HAVE_COMPLEMENTARY
|
||||
/* Deadtime update */
|
||||
|
||||
int (*dt_update)(FAR struct pwm_lowerhalf_s *dev, uint8_t dt);
|
||||
#endif
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user