c_suppress_logs.cfg modified - 19/04/25 - 13:51:14
This commit is contained in:
1 parent
5db1be5e7d
commit
d0a44b8501
1 file changed
+17
-46
@@ -1,58 +1,29 @@
|
|||||||
[suppress_logs]
|
|
||||||
|
|
||||||
########################################################################################################
|
########################################################################################################
|
||||||
# 🧰 SUPPRESS_LOGS MODULE — USAGE GUIDE #
|
# 🧰 SUPPRESS_CONSOLE_LOGS MODULE — USAGE GUIDE #
|
||||||
# #
|
# #
|
||||||
# This module lets you hide specific log lines from Klipper's logs using pattern matching — #
|
# This module disables all console log messages (e.g. Mainsail/Fluidd terminal) from Klipper internals #
|
||||||
# especially useful to suppress repeated output from commands like SET_TMC_CURRENT. #
|
# while keeping full log output in `klippy.log`. #
|
||||||
# #
|
# #
|
||||||
# ✅ Basic Setup: #
|
# ✅ Setup: #
|
||||||
# 1. Install suppress_logs.py in: #
|
# 1. Save `suppress_logs.py` to: #
|
||||||
# /home/pi/klipper/klippy/extras/suppress_logs.py #
|
# /home/pi/klipper/klippy/extras/suppress_logs.py #
|
||||||
# 2. Add this to your printer.cfg: #
|
# 2. Add this to your printer.cfg: #
|
||||||
# [suppress_logs] #
|
# [suppress_logs] #
|
||||||
# 3. Restart Klipper #
|
# 3. Restart Klipper #
|
||||||
# #
|
# #
|
||||||
# ✅ Usage: #
|
# ✅ Usage in G-code: #
|
||||||
# ENABLE_LOG_SUPPRESSION KEYWORDS="pattern1|pattern2" #
|
# ENABLE_LOG_SUPPRESSION ; suppress console messages #
|
||||||
# ... your commands here ... #
|
# ... your commands ... #
|
||||||
# DISABLE_LOG_SUPPRESSION #
|
# DISABLE_LOG_SUPPRESSION ; restore normal console output #
|
||||||
# #
|
# #
|
||||||
# ⚠️ KEYWORDS must be quoted! #
|
# ✅ Example: #
|
||||||
# #
|
# [gcode_macro QUIET_TMC] #
|
||||||
# ✅ Patterns are full Python regex #
|
|
||||||
# You can use wildcards and partial matches like these: #
|
|
||||||
# #
|
|
||||||
# ➤ Match both TMC messages: #
|
|
||||||
# ENABLE_LOG_SUPPRESSION KEYWORDS="Run Current:.*|Hold Current:.*" #
|
|
||||||
# #
|
|
||||||
# ➤ Match any line that contains 'Current': #
|
|
||||||
# ENABLE_LOG_SUPPRESSION KEYWORDS=".*Current:.*" #
|
|
||||||
# #
|
|
||||||
# ➤ Match lines starting with 'Run Current': #
|
|
||||||
# ENABLE_LOG_SUPPRESSION KEYWORDS="^Run Current:" #
|
|
||||||
# #
|
|
||||||
# ➤ Match anything ending in A (Amps): #
|
|
||||||
# ENABLE_LOG_SUPPRESSION KEYWORDS=".*A$" #
|
|
||||||
# #
|
|
||||||
# ✅ Example Macro: #
|
|
||||||
# #
|
|
||||||
# [gcode_macro QUIET_CURRENT_SET] #
|
|
||||||
# description: Set stepper current without TMC spam #
|
|
||||||
# gcode: #
|
# gcode: #
|
||||||
# ENABLE_LOG_SUPPRESSION KEYWORDS="Run Current:.*|Hold Current:.*" #
|
# ENABLE_LOG_SUPPRESSION #
|
||||||
# SET_TMC_CURRENT STEPPER=stepper_x CURRENT=0.89 HOLD_CURRENT=0.65 #
|
# SET_TMC_CURRENT STEPPER=stepper_x CURRENT=0.85 HOLD_CURRENT=0.65 #
|
||||||
# DISABLE_LOG_SUPPRESSION #
|
# DISABLE_LOG_SUPPRESSION #
|
||||||
# #
|
# #
|
||||||
# This prevents the log line like: #
|
# All TMC driver messages will be hidden from the console during execution, #
|
||||||
# Run Current: 0.89A Hold Current: 0.65A #
|
# but will still be recorded in klippy.log. #
|
||||||
# from appearing in your klippy.log #
|
|
||||||
# #
|
# #
|
||||||
# ✅ Notes: #
|
|
||||||
# - No output will appear in the console — this runs silently #
|
|
||||||
# - You can stack multiple patterns using `|` #
|
|
||||||
# - Regex is case-sensitive unless written to ignore it #
|
|
||||||
# #
|
|
||||||
# 🔄 Disable with: #
|
|
||||||
# DISABLE_LOG_SUPPRESSION #
|
|
||||||
########################################################################################################
|
########################################################################################################
|
||||||
Reference in new issue
Block a user