decode from cpp
This commit is contained in:
@@ -58,9 +58,10 @@ if SDK_FAST_LOW_CMD.exists():
|
||||
sys.path.insert(0, str(SDK_FAST_LOW_CMD))
|
||||
try:
|
||||
from fast_lowcmd import FastLowCmdBuilder
|
||||
from fast_mcu import FastMCUClient
|
||||
except ImportError as exc:
|
||||
raise RuntimeError(
|
||||
"C++ fast LowCmd backend is required for this entrypoint. "
|
||||
"C++ fast LowCmd/LowState backend is required for this entrypoint. "
|
||||
"Build it first: cd /root/go1_pro_sdk/fast_lowcmd_cpp && "
|
||||
"PYTHONPATH=/root/go1_pro_sdk python3 setup.py build_ext --inplace"
|
||||
) from exc
|
||||
@@ -69,7 +70,7 @@ DEFAULT_BPU_MODEL = (
|
||||
HERE.parent / "bpu_quantization" / "mapper_output_6500_gemm" /
|
||||
"policy_robotlab_6500_int16_gemm.bin"
|
||||
)
|
||||
LOWCMD_BACKEND = "cpp_checked_servo12"
|
||||
LOWCMD_BACKEND = "cpp_lowcmd_cpp_lowstate"
|
||||
SPORT_KILL_CMD = (
|
||||
'ssh pi@192.168.123.161 "sudo pkill -9 -f keep_sport_alive; '
|
||||
'sudo pkill -9 -f Legged_sport; sudo pkill -9 -f appTransit"'
|
||||
@@ -602,7 +603,7 @@ def connect_client(args):
|
||||
|
||||
print(f"[INFO] LowCmd backend: {LOWCMD_BACKEND}")
|
||||
print("[INFO] Connecting to MCU...")
|
||||
client = MCUClient()
|
||||
client = FastMCUClient()
|
||||
print("[INFO] Waking MCU...")
|
||||
client.wake_mcu(n_frames=50, dt=0.01)
|
||||
state = client.recv_state(timeout=2.0)
|
||||
|
||||
@@ -55,15 +55,16 @@ if SDK_FAST_LOW_CMD.exists():
|
||||
sys.path.insert(0, str(SDK_FAST_LOW_CMD))
|
||||
try:
|
||||
from fast_lowcmd import FastLowCmdBuilder
|
||||
from fast_mcu import FastMCUClient
|
||||
except ImportError as exc:
|
||||
raise RuntimeError(
|
||||
"C++ fast LowCmd backend is required for this entrypoint. "
|
||||
"C++ fast LowCmd/LowState backend is required for this entrypoint. "
|
||||
"Build it first: cd /root/go1_pro_sdk/fast_lowcmd_cpp && "
|
||||
"PYTHONPATH=/root/go1_pro_sdk python3 setup.py build_ext --inplace"
|
||||
) from exc
|
||||
|
||||
DEFAULT_ONNX = HERE / "policy_robotlab_6500.onnx"
|
||||
LOWCMD_BACKEND = "cpp_checked_servo12"
|
||||
LOWCMD_BACKEND = "cpp_lowcmd_cpp_lowstate"
|
||||
SPORT_KILL_CMD = (
|
||||
'ssh pi@192.168.123.161 "sudo pkill -9 -f keep_sport_alive; '
|
||||
'sudo pkill -9 -f Legged_sport; sudo pkill -9 -f appTransit"'
|
||||
@@ -631,7 +632,7 @@ def connect_client(args):
|
||||
|
||||
print(f"[INFO] LowCmd backend: {LOWCMD_BACKEND}")
|
||||
print("[INFO] Connecting to MCU...")
|
||||
client = MCUClient()
|
||||
client = FastMCUClient()
|
||||
print("[INFO] Waking MCU...")
|
||||
client.wake_mcu(n_frames=50, dt=0.01)
|
||||
state = client.recv_state(timeout=2.0)
|
||||
|
||||
Reference in New Issue
Block a user