Calculator

Vref calculator for stepper drivers

Choose the driver, the sense resistor and the motor's rated current. You get the Vref to set with the potentiometer, the peak and RMS current and a warning when the driver needs cooling.

Driver
Set Vref to
1.275V
Peak current1.28 A
RMS current0.90 A
The driver sets the current asRMS

The current is within the driver's range without extra cooling.

How to measure Vref
  1. Power the board from the power supply (not only from USB).
  2. Multimeter on DC voltage, range up to 2 V.
  3. Black lead to the board's GND, red lead to the driver's potentiometer (for TMC check the measuring point in the documentation).
  4. Turn the potentiometer a little at a time with a small plastic or ceramic screwdriver until the reading is close to the result.

Formulas: A4988 and DRV8825 per the driver maker, TMC2208/2209 in standalone mode per the datasheet. When driven over UART or SPI, the current is set in firmware, not with the potentiometer.

How Vref is worked out

Formula

peak current = rated current x margin, RMS = peak / √2
A4988: Vref = I_peak x 8 x Rs
DRV8825: Vref = I_peak x 5 x Rs
TMC2208/2209: Vref = I_RMS x 2.5 x √2 x (Rs + 0.02) / 0.325

A stepper driver limits the current in the coils. The limit is set with a potentiometer, and the voltage on it, Vref, converts to current using the maker's formula and the sense resistor Rs on the driver board.

The A4988 and DRV8825 set the peak current. TMC2208 and TMC2209 drivers in standalone mode set the RMS current, which for a sine wave is √2 times lower than the peak. That is why the same motor needs a different Vref on each driver.

The motor's rated current is not set at 100%. Usually at least 10% margin is left, because the motor and driver then run cooler and the torque is normally enough. If the motor skips steps, raise the current gradually.

Read the sense resistor off the board: R100 is 0.1 Ω, R110 is 0.11 Ω. A wrong Rs in the calculation gives a wrong current, so check it before turning the potentiometer.

Example on the default values (1.5 A motor, 85%)

  1. Peak current: 1.5 x 85% = 1.275 A, RMS: 1.275 / √2 = 0.902 A.
  2. TMC2209 with Rs 0.11 Ω: Vref = 0.902 x 2.5 x √2 x 0.13 / 0.325 = 1.275 V.
  3. The same motor on an A4988 with Rs 0.1 Ω: 1.275 x 8 x 0.1 = 1.020 V.
  4. On a DRV8825 with Rs 0.1 Ω: 1.275 x 5 x 0.1 = 0.638 V.

Vref for common motors (85% of rated current)

Rated currentA4988 (0.1 Ω)DRV8825 (0.1 Ω)TMC2208/2209 (0.11 Ω)
0.8 A0.544 V0.340 V0.680 V
1.0 A0.680 V0.425 V0.850 V
1.2 A0.816 V0.510 V1.020 V
1.5 A1.020 V0.638 V1.275 V
2.0 A1.360 V0.850 V1.700 V

Practical tips

  • Measure Vref with the board powered from the power supply, not only from USB. Readings without motor voltage can differ.
  • Use a plastic or ceramic screwdriver. A metal one can easily short neighbouring pins and damage the driver.
  • After setting it, check the motor temperature after a quarter of an hour of printing. Warm is fine; too hot to touch means too much current.
  • Z and extruder motors often need a different current from X and Y. Set each driver separately.

Video tutorials: print it well

Short tutorials from my BnB3D channel (Polish audio, English subtitles).

Free 3D-printable QR code generator – Wi-Fi, reviews, keychain and magnet
Free 3D printed cookie cutter generator – from any shape
All tutorials on YouTube

Handy for this tool

Affiliate links: if you buy something I get a small commission, and you pay the same. As an Amazon Associate I earn from qualifying purchases.

Frequently asked questions

What happens if Vref is too high?+

The motor and driver get very hot, the driver may shut down thermally and the motor can heat up its mount. Too low a Vref causes skipped steps and layer shifts.

Do I need to set Vref on a TMC2209?+

Only in standalone mode without UART. If the board drives the TMC2209 over UART, the current is set in firmware, e.g. run_current in Klipper, and the potentiometer does nothing.

What Vref for an A4988 and a NEMA 17 motor?+

It depends on the motor current and the resistor. For a 1.5 A motor at 85% current and Rs 0.1 Ω it comes to about 1.02 V. Check the current on the motor datasheet and Rs on the board.

Peak or RMS current?+

Treat the motor's rated current as peak. The A4988 and DRV8825 set exactly the peak, while TMC drivers set RMS, the peak divided by √2. The calculator converts it for you.

Where do I measure Vref on a TMC2209?+

Usually on the potentiometer or on a marked VREF pin, depending on the board maker. Check your module's documentation, because pin layouts differ.