diff --git a/klippy/extras/gcode_macro.py b/klippy/extras/gcode_macro.py index 3121024e47f8..b39b7570cb5e 100644 --- a/klippy/extras/gcode_macro.py +++ b/klippy/extras/gcode_macro.py @@ -4,8 +4,7 @@ # # This file may be distributed under the terms of the GNU GPLv3 license. import traceback, logging, ast, copy -import jinja2 - +import jinja2, math ###################################################################### # Template handling @@ -101,6 +100,7 @@ def create_template_context(self, eventtime=None): 'action_respond_info': self._action_respond_info, 'action_raise_error': self._action_raise_error, 'action_call_remote_method': self._action_call_remote_method, + 'math': math } def load_config(config):