<p>In the Marlin source code I found the function responsible for the report logs: <code>report_polled_driver_data</code> in <code>Marlin/src/feature/tmc_util.cpp</code>.</p>

<p>The values indicated appear to be:</p>

<pre><code>&lt;Axis&gt;:&lt;PWM scale&gt;/&lt;Current scale&gt;/&lt;StallGuard&gt;|&lt;Flags&gt;|&lt;OTPW count&gt;
</code></pre>

<p>Where possible flags are as follows (where “debug” indicates that they only appear if <code>TMC_DEBUG</code> is enabled):</p>

<ul>
<li>E: <strong>E</strong>rror</li>
<li>O: <strong>O</strong>ver-temperature</li>
<li>W: over-temperature pre-<strong>W</strong>arning</li>
<li>G: stall<strong>G</strong>uard (debug)</li>
<li>T: stealth<strong>C</strong>hop (debug)</li>
<li>I: standst<strong>I</strong>ll (debug)</li>
<li>F: otpw <strong>F</strong>lag</li>
</ul>

CC BY-SA 4.0
2020-04-27T10:35:27.697Z
2020-04-27T10:35:27.697Z
Ian Mackinnon
<p>In Marlin one can enable <a href="https://marlinfw.org/docs/gcode/M122.html" rel="nofollow noreferrer">continuous debug reporting of Trinamic drivers</a> with the command</p>

<p><code>M122 S1</code></p>

<p>This sends lines similar to the following over the serial connection:</p>

<pre><code>X:93/28/0||    Y:35/14/-|IF|   Z:54/28/0||    E:176/25/0||
</code></pre>

<p>Each driver appears to report three integer values and some flags. I understand the <code>F</code> flag indicates an error state, for example the overtemperature pre-warn condition (OTPW).</p>

<p>What do the other values mean? How can this information be interpreted to debug printing problems or improve performance?</p>

<marlin><stepper-driver><tmc2130>
How to interpret Trinamic driver continuous debug reporting?
Ian Mackinnon
# How to interpret Trinamic driver continuous debug reporting?

(Asked by: username_0 on 2020-04-26)

In Marlin one can enable [continuous debug reporting of Trinamic drivers](https://marlinfw.org/docs/gcode/M122.html) with the command

`M122 S1`

This sends lines similar to the following over the serial connection:

```
X:93/28/0||    Y:35/14/-|IF|   Z:54/28/0||    E:176/25/0||

```

Each driver appears to report three integer values and some flags. I understand the `F` flag indicates an error state, for example the overtemperature pre-warn condition (OTPW).

What do the other values mean? How can this information be interpreted to debug printing problems or improve performance?

**Tags:** marlin, stepper-driver, tmc2130


---

## 1 answers

### Answer by username_0 on 2020-04-27. Score: 2

In the Marlin source code I found the function responsible for the report logs: `report_polled_driver_data` in `Marlin/src/feature/tmc_util.cpp`.

The values indicated appear to be:

```
<Axis>:<PWM scale>/<Current scale>/<StallGuard>|<Flags>|<OTPW count>

```

Where possible flags are as follows (where “debug” indicates that they only appear if `TMC_DEBUG` is enabled):

* E: **E**rror
* O: **O**ver-temperature
* W: over-temperature pre-**W**arning
* G: stall**G**uard (debug)
* T: stealth**C**hop (debug)
* I: standst**I**ll (debug)
* F: otpw **F**lag


---

