PWM configuration structure.
Data Fields | |
uint32_t | pwmMode |
Sets the PWM mode. More... | |
uint32_t | clockPrescaler |
Sets the clock prescaler inside the TCWPM block. More... | |
uint32_t | pwmAlignment |
Sets the PWM alignment. More... | |
uint32_t | deadTimeClocks |
The number of dead time-clocks if PWM with dead time is chosen. | |
uint32_t | runMode |
Sets the PWM run mode. More... | |
uint32_t | period0 |
Sets the period0 of the pwm. | |
uint32_t | period1 |
Sets the period1 of the pwm. | |
bool | enablePeriodSwap |
Enables swapping of period 0 and period 1 on terminal count. | |
uint32_t | compare0 |
Sets the value for Compare 0. | |
uint32_t | compare1 |
Sets the value for the buffered Compare 0. | |
bool | enableCompareSwap |
If enabled, the compare values are swapped on the terminal count. | |
uint32_t | interruptSources |
Enables an interrupt on the terminal count, capture or compare. More... | |
uint32_t | invertPWMOut |
Inverts the PWM output. More... | |
uint32_t | invertPWMOutN |
Inverts the PWM_n output. More... | |
uint32_t | killMode |
Configures the PWM kill modes. More... | |
uint32_t | swapInputMode |
Configures how the swap input behaves. More... | |
uint32_t | swapInput |
Selects which input the swap uses. More... | |
uint32_t | reloadInputMode |
Configures how the reload input behaves. More... | |
uint32_t | reloadInput |
Selects which input the reload uses. More... | |
uint32_t | startInputMode |
Configures how the start input behaves. More... | |
uint32_t | startInput |
Selects which input the start uses. More... | |
uint32_t | killInputMode |
Configures how the kill input behaves. More... | |
uint32_t | killInput |
Selects which input the kill uses. More... | |
uint32_t | countInputMode |
Configures how the count input behaves. More... | |
uint32_t | countInput |
Selects which input the count uses. More... | |
bool | swapOverflowUnderflow |
If enabled, line output is set on underflow and cleared on overflow. More... | |
bool | buffer_swap_enable |
Configures swapping mechanism between CC0 and buffered CC0, CC1 and buffered CC1, PERIOD and buffered PERIOD, DT and buffered DT. | |
cy_en_tcpwm_dithering_t | dithering_mode |
Dithering mode is group specific configuration and will be applicable if the group supports dithering. | |
uint8_t | period_dithering_value |
Dithering value for period LFSR. More... | |
uint8_t | duty_dithering_value |
Dithering value for duty LFSR. More... | |
cy_en_dithering_limiter_t | limiter |
Magnitude of the pseudo-random value to be added to period/CC0/CC1 cy_en_dithering_limiter_t. | |
bool | hrpwm_enable |
If enabled, high resolution PWM path is enabled. | |
cy_en_hrpwm_operating_frequency_t | hrpwm_input_freq |
Frequency of operation for HRPWM. | |
cy_en_kill_line_polarity_t | kill_line_polarity |
Outputs line_out and line_out_compl_out while the TCPWM counter is disabled or stopped. More... | |
uint32_t | deadTimeClocksBuff |
Buffer value for the number of dead time-clocks if PWM with dead time is chosen. More... | |
uint16_t | deadTimeClocksBuff_linecompl_out |
The number of dead time-clocks for line compl out if PWM with dead time is chosen. | |
bool | glitch_filter_enable |
Enables Glitch filter for input triggers. More... | |
cy_en_gf_depth_value_t | gf_depth |
Glitch filter depth value. More... | |
uint32_t cy_stc_tcpwm_pwm_config_t::pwmMode |
Sets the PWM mode.
See PWM modes
uint32_t cy_stc_tcpwm_pwm_config_t::clockPrescaler |
Sets the clock prescaler inside the TCWPM block.
uint32_t cy_stc_tcpwm_pwm_config_t::pwmAlignment |
Sets the PWM alignment.
See PWM Alignment
uint32_t cy_stc_tcpwm_pwm_config_t::runMode |
Sets the PWM run mode.
See PWM run modes
uint32_t cy_stc_tcpwm_pwm_config_t::interruptSources |
Enables an interrupt on the terminal count, capture or compare.
uint32_t cy_stc_tcpwm_pwm_config_t::invertPWMOut |
Inverts the PWM output.
This field also defines the state of the PWM output while PWM is enabled, but not running.
uint32_t cy_stc_tcpwm_pwm_config_t::invertPWMOutN |
Inverts the PWM_n output.
This field also defines the state of the PWM_n output while PWM is enabled, but not running.
uint32_t cy_stc_tcpwm_pwm_config_t::killMode |
Configures the PWM kill modes.
See PWM kill modes
uint32_t cy_stc_tcpwm_pwm_config_t::swapInputMode |
Configures how the swap input behaves.
See Input Modes
uint32_t cy_stc_tcpwm_pwm_config_t::swapInput |
Selects which input the swap uses.
Inputs are device-specific. See TCPWM Input Selection
uint32_t cy_stc_tcpwm_pwm_config_t::reloadInputMode |
Configures how the reload input behaves.
See Input Modes
uint32_t cy_stc_tcpwm_pwm_config_t::reloadInput |
Selects which input the reload uses.
The inputs are device-specific. See TCPWM Input Selection
uint32_t cy_stc_tcpwm_pwm_config_t::startInputMode |
Configures how the start input behaves.
See Input Modes
uint32_t cy_stc_tcpwm_pwm_config_t::startInput |
Selects which input the start uses.
The inputs are device-specific. See TCPWM Input Selection
uint32_t cy_stc_tcpwm_pwm_config_t::killInputMode |
Configures how the kill input behaves.
See Input Modes
uint32_t cy_stc_tcpwm_pwm_config_t::killInput |
Selects which input the kill uses.
The inputs are device-specific. See TCPWM Input Selection
uint32_t cy_stc_tcpwm_pwm_config_t::countInputMode |
Configures how the count input behaves.
See Input Modes
uint32_t cy_stc_tcpwm_pwm_config_t::countInput |
Selects which input the count uses.
The inputs are device-specific. See TCPWM Input Selection
bool cy_stc_tcpwm_pwm_config_t::swapOverflowUnderflow |
If enabled, line output is set on underflow and cleared on overflow.
This configuration is available only in center and asymmetric alignment modes.
uint8_t cy_stc_tcpwm_pwm_config_t::period_dithering_value |
Dithering value for period LFSR.
Should be non zero value.
uint8_t cy_stc_tcpwm_pwm_config_t::duty_dithering_value |
Dithering value for duty LFSR.
Should be non zero value.
cy_en_kill_line_polarity_t cy_stc_tcpwm_pwm_config_t::kill_line_polarity |
Outputs line_out and line_out_compl_out while the TCPWM counter is disabled or stopped.
uint32_t cy_stc_tcpwm_pwm_config_t::deadTimeClocksBuff |
Buffer value for the number of dead time-clocks if PWM with dead time is chosen.
Can be swapped with Line out on a terminal count event.
bool cy_stc_tcpwm_pwm_config_t::glitch_filter_enable |
Enables Glitch filter for input triggers.
cy_en_gf_depth_value_t cy_stc_tcpwm_pwm_config_t::gf_depth |
Glitch filter depth value.