Home / Learn Verilog / PWM for Servos
PWM for Servos
1-2 ms pulse every 20 ms.
The gist1-2 ms pulse every 20 ms.
The idea, explained simply
What it is
Hobby servos read a pulse width from 1 ms (0 degrees) to 2 ms (180 degrees) every 20 ms.
Why it matters
Robots and mechanisms.
Mechanically speaking
Counter to 20 ms, compare with the pulse width.
Shows up in
- Everyday RTL design
- FPGA and ASIC projects
- Testbenches and debugging
Try it
Servo pulse (1 time unit = 100 us)Verilog: edit and run
Width 15 ticks = 1.5 ms: servo centre.
Check yourself
1. Servo period?
Standard.