From b58d169acc2933054ccb0e88ae80655e9cf0d73d Mon Sep 17 00:00:00 2001 From: Unknown Date: Fri, 10 Jul 2020 16:30:37 -0400 Subject: [PATCH] CTRL_MODE --> CONTROL_MODE in utils.py --- tools/odrive/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/odrive/utils.py b/tools/odrive/utils.py index a8b402a4..5b9ff4c8 100755 --- a/tools/odrive/utils.py +++ b/tools/odrive/utils.py @@ -201,14 +201,14 @@ def step_and_plot( axis, step_size=100.0, settle_time=0.5, data_rate=500.0, - ctrl_mode=CTRL_MODE_POSITION_CONTROL): + ctrl_mode=CONTROL_MODE_POSITION_CONTROL): - if ctrl_mode is CTRL_MODE_POSITION_CONTROL: + if ctrl_mode is CONTROL_MODE_POSITION_CONTROL: get_var_callback = lambda :[axis.encoder.pos_estimate, axis.controller.pos_setpoint] initial_setpoint = axis.encoder.pos_estimate def set_setpoint(setpoint): axis.controller.pos_setpoint = setpoint - elif ctrl_mode is CTRL_MODE_VELOCITY_CONTROL: + elif ctrl_mode is CONTROL_MODE_VELOCITY_CONTROL: get_var_callback = lambda :[axis.encoder.vel_estimate, axis.controller.vel_setpoint] initial_setpoint = 0 def set_setpoint(setpoint):