Interactive PWM Calculator

Interactive PWM Calculator

animation
actuators
pwm
Try Leave Target Output (%) at 50, PWM Resolution at 8-bit and PWM Frequency at 5 kHz, then adjust the target.
Observe The opening settings give PWM Value 128 / 255 and a 200.00 microsecond period split into equal ON and OFF times.
Explain PWM Resolution sets the maximum count; Target Output (%) scales and rounds that count, while PWM Frequency sets the period.

Technical boundaries. Average-voltage calculation assumes ideal switching of fixed 5 V and 12 V supplies. Timing uses the requested percentage rather than the rounded PWM count; motor speed and switching losses are not calculated.

Interactive PWM Calculator

Calculated Values

ESP32 Code

Back to the chapter