PWM
Generate ideal pulse width modulated signal corresponding to input duty cycle
Since R2020b
Libraries:
Simulink /
Discontinuities
Description
Use the PWM block to generate an ideal pulse width modulated signal.
Pulse-width modulation (PWM) is a technique for encoding an analog signal using square pulses. This encoding is achieved by controlling the fraction of one period of the square wave that is set to high. This fraction is the duty cycle of the signal. The relationship between the modulated signal and the input duty cycle can be simply described as:
where ymax and ymin are the upper and lower bounds of the output signal, respectively. For
the PWM block, the duty cycle is constrained to [0,1]
.
The ideal PWM signal is proportional to the duty cycle D.
Ports
Input
Output
Parameters
Block Characteristics
Data Types |
|
Direct Feedthrough |
|
Multidimensional Signals |
|
Variable-Size Signals |
|
Zero-Crossing Detection |
|
Algorithms
Extended Capabilities
Version History
Introduced in R2020b