Doing some input shaping calibrations on my printers and found (what I think may be) an outdated section in the Klipper documentation under the ‘Measuring Resonances’ section:
When trying to create the graphs for the shaper it seems the two data files in the /tmp/ folder are now called “calibration_data_” instead of “resonances_”, so the two lengths of code don’t find the correct files.
or perhaps have both lines mentioned as if the script throws a FileNotFoundError with the ‘resonances_’ commands then use the ‘calibration_data_’ commands.
Anyways, just wanted to point that out! Really appreciate the documentation work and coding all you folks have done!
calibration_data_* is output by the automatic calibration command SHAPER_CALIBRATE, which is documented elsewhere in this file. The examples given are not out of date, they are part of this specific process which does not use this command so cannot generate those output files. You can’t expect to arbitrarily jam parts of two different processes together with zero effort on your part.
Each of these commands and the corresponding filenames is mentioned in the correct context in the documentation.
The SHAPER_CALIBRATE command is explicitly for autotuning from a web interface without the need to drop to the shell and perform manual work.
The need to mention that calibrate_shaper.py can be used with all three output formats is debatable, but would not hurt. Feel free to submit a PR to improve this section.
Rephrase this section and move the information to the end of this chapter, something like:
The SHAPER_CALIBRATE command also generates csv output (/tmp/calibration_data_*.csv), which can be processed using the calibrate_shaper.py script, for example:
As stated before, I would think that all the needed information is already present, so duplicating it at various places might be debatable as it will blow up the chapter, which is already quite unwieldy. Maybe something like the following is already enough:
The SHAPER_CALIBRATE command also generates csv output, but with different filenames (/tmp/calibration_data_*.csv). These files can also be processed using the scripts as shown in the chapters above.
Or even shorter, leaving the whole structure as is:
This will run the full test for both axes and generate the csv output (/tmp/calibration_data_*.csv by default , which is also compatible with the analysis scripts above) for the frequency response and the suggested input shapers.
It definitely would keep things a bit more organized to have the commands down in the SHAPER_CALIBRATE section, so I can update the PR for that! I do think it’s worth having the command lines like in the rephrase you have as I’ve always found it handy to have the commands to transpose into SSH when working through the Klipper manual!
I guess my thinking with having it up under the ‘Measuring Resonances’ section is that is where I’d be reading on how to generate the graphs and with both TEST_RESONANCES and SHAPER_CALIBRATE being capable of producing the raw data for the scripts it made sense to have that information close together.
Moved the edit down to the end of the section and merged it with the existing reference to SHAPER_CALIBRATE. Only adds a line and the two commands, much more compact, but still near the section on generating the graphs!