This commit is contained in:
trung09122002
2026-09-21 10:23:51 +07:00
parent dea92c46d2
commit 641db2e914
6 changed files with 49 additions and 6 deletions

View File

@@ -242,10 +242,23 @@ struct BaseConfig {
std::string dcf_path;
// Encoder resolution cua ZLAC8015D, dem/vong SAU hop so, doc qua 0x6064.
// 0 = doc tu thiet bi luc Open() (0x608F:1 Encoder Increments) thay vi tin
// mot hang so chep tay.
//
// ⚠️ 0 = dung mac dinh 16384 trong zlac_base.cc (4096 wire x 4 cau phuong),
// va con so do CHUA duoc kiem chung. base_kit KHONG giup duoc gi o day: ho
// chi doc van toc (0x606C, don vi rpm) nen khong bao gio can biet count/vong
// -- tham so nay khong ton tai trong motor_params.yaml cua ho.
// Cach do: quay banh tay dung mot vong, so hieu 0x6064:1 truoc/sau.
uint32_t encoder_counts_per_rev = 0;
// Thoi gian ramp gui xuong 0x6083/0x6084 (Profile acceleration/deceleration),
// don vi ms tu 0 den toc do dinh muc. SO CANG LON, RAMP CANG CHAM.
//
// 1200 la gia tri base_kit dung (motor_params.yaml: acc_dec_val). Mac dinh
// cua ZlacMotorDriver::enableHardware() la 500, tuc tang toc NHANH GAP 2.4
// LAN, du de banh truot that tren san tron. base_kit da chinh so nay tren
// chinh con robot nay nen no thang -- day la tham so cua THIET BI.
uint32_t accel_ramp_ms = 1200;
// --- Dung khi protocol = kVendorSerial ---
std::string port = "/dev/ttyUSB0";
uint32_t baud = 115200;