What M204 means

Feed rate is the requested cruising speed; acceleration controls how quickly motion can approach or leave that speed. Short segments may never reach their programmed feed rate. Higher acceleration can reduce time but may increase vibration, ringing, noise or skipped steps if the machine cannot follow it.

On modern Marlin, P sets printing acceleration, R retract acceleration and T travel acceleration; legacy S sets print and travel together. Klipper accepts M204 S, but when given both P and T it uses the lower value rather than maintaining separate print and travel states. The same line can therefore produce different planning behavior across firmware.

Syntax and parameters

M204 P<print-accel> T<travel-accel> [R<retract-accel>]
M204 S<accel>
P

Printing-move acceleration in current units per second squared on Marlin.

T

Travel-move acceleration on Marlin; part of a minimum calculation on Klipper's P/T compatibility form.

R

Extruder-only retract/recover acceleration on Marlin.

S

Legacy or common single acceleration value; exact scope is firmware-specific.

Practical examples

Separate print and travel

M204 P1200 T3000

Marlin uses 1200 for printing and 3000 for travel; Klipper documents a different compatibility interpretation.

Set one value

M204 S1500

A broadly recognized form, though firmware limits can still constrain the effective acceleration.

Firmware context

SystemStatusWhat changes
MarlinCommonP, R and T select print, retract and travel starting acceleration; legacy S is deprecated.
KlipperCheck dialectS sets acceleration; with both P and T, Klipper sets the minimum of the two rather than separate modes.
RepRapFirmwareCheck dialectSupports motion tuning with firmware-specific M204 meanings and limits.
CNC controllersCheck dialectAcceleration is usually controller configuration, not a portable M204 contract.

What this viewer can show

Used for motion-time planning

The viewer tracks M204 where supported and uses the active print or travel acceleration when estimating each move. It labels the result as an estimate because firmware limits and kinematics still matter.

Common mistakes

  • Do not confuse F feed rate in mm/min with acceleration in mm/s².
  • A requested value can be capped by axis limits, firmware configuration or input shaping constraints.
  • Marlin P/T and Klipper P/T are not equivalent even though the line parses on both.

Primary sources

This page is an original explanation, reviewed against the firmware documentation below. Always confirm commands against the firmware and configuration on the machine that will execute them.