1 """Test CoM admittance control as described in paper"""
6 from dynamic_graph.sot_talos_balance.utils.run_test_utils
import (
24 print(
"Compensating flexibility")
27 print(
"Not compensating flexibility")
30 run_test(
"appli_dcm_zmp_control_flex_openloop.py")
35 input(
"Wait before activating flexibility")
36 cmd_l =
"robot.hipComp.K_l.value = hipFlexCompConfig.flexibility_left"
37 cmd_r =
"robot.hipComp.K_r.value = hipFlexCompConfig.flexibility_right"
40 input(
"Wait before running the test")
43 print(
"Connect ZMP reference")
44 runCommandClient(
"plug(robot.zmp_estimator.emergencyStop,robot.cm.emergencyStop_zmp)")
45 runCommandClient(
"plug(robot.dcm_control.zmpRef,robot.com_admittance_control.zmpDes)")
47 "robot.com_admittance_control.setState(robot.wp.comDes.value,[0.0,0.0,0.0])"
54 if test_folder
is not None:
57 print(
"Executing the trajectory")
60 print(
"Not executing the trajectory")
64 print(
"Putting the robot in position...")
67 print(
"Robot is in position!")
71 print(
"Executing the sinusoid...")
73 print(
"Sinusoid started!")
75 print(
"Not executing the sinusoid")
79 print(
"Stopping the robot...")
82 print(
"Putting the robot back...")
85 print(
"The robot is back in position!")
87 print(
"Not putting the robot back")
89 print(
"Not executing the sinusoid")
93 print(
"Putting the robot in position...")
96 print(
"Robot is in position!")
102 print(
"Raising the foot...")
107 print(
"Foot has been raised!")
108 foot_on_ground =
False
111 print(
"Putting the foot back...")
115 print(
"The foot is back in position!")
116 foot_on_ground =
True
118 print(
"Not putting the foot back")
120 print(
"Not raising the foot")
125 print(
"Putting the robot back...")
128 print(
"The robot is back in position!")
130 print(
"Not putting the robot back")
132 print(
"Not raising the foot")
134 input(
"Wait before dumping the data")
def ask_for_confirmation(text)
def run_ft_calibration(sensor_name, force=False)
def run_test(appli, verbosity=1, interactive=True)
def get_file_folder(argv, send=True)