mirror of
https://github.com/odriverobotics/ODrive.git
synced 2026-09-25 11:06:48 +08:00
Merge remote-tracking branch 'madcowswe/devel' into feature/anticogging_usb_function
This commit is contained in:
@@ -142,6 +142,13 @@ const Endpoint endpoints[] = {
|
||||
Endpoint::make_property("Iq_measured", &motors[0].current_control.Iq_measured),
|
||||
Endpoint::make_property("Ibus", const_cast<const float*>(&motors[0].current_control.Ibus)),
|
||||
Endpoint::close_tree(),
|
||||
Endpoint::make_object("gate_driver"),
|
||||
Endpoint::make_property("drv_fault", reinterpret_cast<int32_t*>(&motors[0].drv_fault)),
|
||||
Endpoint::make_property("status_reg_1", (&motors[0].gate_driver_regs.Stat_Reg_1_Value)),
|
||||
Endpoint::make_property("status_reg_2", (&motors[0].gate_driver_regs.Stat_Reg_2_Value)),
|
||||
Endpoint::make_property("ctrl_reg_1", (&motors[0].gate_driver_regs.Ctrl_Reg_1_Value)),
|
||||
Endpoint::make_property("ctrl_reg_2", (&motors[0].gate_driver_regs.Ctrl_Reg_2_Value)),
|
||||
Endpoint::close_tree(),
|
||||
Endpoint::make_object("encoder"),
|
||||
Endpoint::make_property("phase", const_cast<const float*>(&motors[0].encoder.phase)),
|
||||
Endpoint::make_property("pll_pos", &motors[0].encoder.pll_pos),
|
||||
@@ -199,6 +206,13 @@ const Endpoint endpoints[] = {
|
||||
Endpoint::make_property("Iq_measured", &motors[1].current_control.Iq_measured),
|
||||
Endpoint::make_property("Ibus", const_cast<const float*>(&motors[1].current_control.Ibus)),
|
||||
Endpoint::close_tree(),
|
||||
Endpoint::make_object("gate_driver"),
|
||||
Endpoint::make_property("drv_fault", reinterpret_cast<int32_t*>(&motors[1].drv_fault)),
|
||||
Endpoint::make_property("status_reg_1", (&motors[1].gate_driver_regs.Stat_Reg_1_Value)),
|
||||
Endpoint::make_property("status_reg_2", (&motors[1].gate_driver_regs.Stat_Reg_2_Value)),
|
||||
Endpoint::make_property("ctrl_reg_1", (&motors[1].gate_driver_regs.Ctrl_Reg_1_Value)),
|
||||
Endpoint::make_property("ctrl_reg_2", (&motors[1].gate_driver_regs.Ctrl_Reg_2_Value)),
|
||||
Endpoint::close_tree(),
|
||||
Endpoint::make_object("encoder"),
|
||||
Endpoint::make_property("phase", const_cast<const float*>(&motors[1].encoder.phase)),
|
||||
Endpoint::make_property("pll_pos", &motors[1].encoder.pll_pos),
|
||||
|
||||
Reference in New Issue
Block a user