@@ -16,62 +16,61 @@ The command ids used by the commander interface are defined in the library sourc
1616``` cpp
1717
1818// list of commands
19- #define CMD_C_D_PID 'D' //!< current d PID & LPF
20- #define CMD_C_Q_PID 'Q' //!< current q PID & LPF
21- #define CMD_V_PID 'V' //!< velocity PID & LPF
22- #define CMD_A_PID 'A' //!< angle PID & LPF
23- #define CMD_STATUS 'E' //!< motor status enable/disable
24- #define CMD_LIMITS 'L' //!< limits current/voltage/velocity
25- #define CMD_MOTION_TYPE 'C' //!< motion control type
26- #define CMD_TORQUE_TYPE 'T' //!< torque control type
27- #define CMD_SENSOR 'S' //!< sensor offsets
28- #define CMD_MONITOR 'M' //!< monitoring
29- #define CMD_RESIST 'R' //!< motor phase resistance
30- #define CMD_INDUCTANCE 'I' //!< motor phase inductance
31- #define CMD_KV_RATING 'K' //!< motor kv rating
32- #define CMD_PWMMOD 'W' //!< pwm modulation
33- #define CMD_FOC_PARAMS 'F' //!< time parameters
19+ #define CMD_C_D_PID 'D' //!< current d PID & LPF
20+ #define CMD_C_Q_PID 'Q' //!< current q PID & LPF
21+ #define CMD_V_PID 'V' //!< velocity PID & LPF
22+ #define CMD_A_PID 'A' //!< angle PID & LPF
23+ #define CMD_STATUS 'E' //!< motor status enable/disable
24+ #define CMD_LIMITS 'L' //!< limits current/voltage/velocity
25+ #define CMD_MOTION_TYPE 'C' //!< motion control type
26+ #define CMD_TORQUE_TYPE 'T' //!< torque control type
27+ #define CMD_SENSOR 'S' //!< sensor offsets
28+ #define CMD_MONITOR 'M' //!< monitoring
29+ #define CMD_RESIST 'R' //!< motor phase resistance
30+ #define CMD_INDUCTANCE 'I' //!< motor phase inductance
31+ #define CMD_KV_RATING 'K' //!< motor kv rating
32+ #define CMD_PWMMOD 'W' //!< pwm modulation
33+ #define CMD_FOC_PARAMS 'F' //!< time parameters
3434
35- // commander configuration
36- #define CMD_SCAN '?' //!< command scaning the network - only for commander
37- #define CMD_VERBOSE '@' //!< command setting output mode - only for commander
38- #define CMD_DECIMAL '#' //!< command setting decimal places - only for commander
35+ // commander configuration
36+ #define CMD_SCAN '?' //!< command scaning the network - only for commander
37+ #define CMD_VERBOSE '@' //!< command setting output mode - only for commander
38+ #define CMD_DECIMAL '#' //!< command setting decimal places - only for commander
3939
40- // subcomands
41- // pid - lpf
42- #define SCMD_PID_P 'P' //!< PID gain P
43- #define SCMD_PID_I 'I' //!< PID gain I
44- #define SCMD_PID_D 'D' //!< PID gain D
45- #define SCMD_PID_RAMP 'R' //!< PID ramp
46- #define SCMD_PID_LIM 'L' //!< PID limit
47- #define SCMD_LPF_TF 'F' //!< LPF time constant
48- // limits
49- #define SCMD_LIM_CURR 'C' //!< Limit current
50- #define SCMD_LIM_VOLT 'U' //!< Limit voltage
51- #define SCMD_LIM_VEL 'V' //!< Limit velocity
52- //sensor
53- #define SCMD_SENS_MECH_OFFSET 'M' //!< Sensor offset
54- #define SCMD_SENS_ELEC_OFFSET 'E' //!< Sensor electrical zero offset
55- // monitoring
56- #define SCMD_DOWNSAMPLE 'D' //!< Monitoring downsample value
57- #define SCMD_CLEAR 'C' //!< Clear all monitored variables
58- #define SCMD_GET 'G' //!< Get variable only one value
59- #define SCMD_SET 'S' //!< Set variables to be monitored
40+ // subcomands
41+ // pid - lpf
42+ #define SCMD_PID_P 'P' //!< PID gain P
43+ #define SCMD_PID_I 'I' //!< PID gain I
44+ #define SCMD_PID_D 'D' //!< PID gain D
45+ #define SCMD_PID_RAMP 'R' //!< PID ramp
46+ #define SCMD_PID_LIM 'L' //!< PID limit
47+ #define SCMD_LPF_TF 'F' //!< LPF time constant
48+ // limits
49+ #define SCMD_LIM_CURR 'C' //!< Limit current
50+ #define SCMD_LIM_VOLT 'U' //!< Limit voltage
51+ #define SCMD_LIM_VEL 'V' //!< Limit velocity
52+ // sensor
53+ #define SCMD_SENS_MECH_OFFSET 'M' //!< Sensor offset
54+ #define SCMD_SENS_ELEC_OFFSET 'E' //!< Sensor electrical zero offset
55+ // monitoring
56+ #define SCMD_DOWNSAMPLE 'D' //!< Monitoring downsample value
57+ #define SCMD_CLEAR 'C' //!< Clear all monitored variables
58+ #define SCMD_GET 'G' //!< Get variable only one value
59+ #define SCMD_SET 'S' //!< Set variables to be monitored
60+ #define SCMD_TIME 'T' //!< Time between executions (filtered)
6061
61- // pwm modulation
62- #define SCMD_PWMMOD_TYPE 'T' //!<< Pwm modulation type
63- #define SCMD_PWMMOD_CENTER 'C' //!<< Pwm modulation center flag
62+ // pwm modulation
63+ #define SCMD_PWMMOD_TYPE 'T' //!<< Pwm modulation type
64+ #define SCMD_PWMMOD_CENTER 'C' //!<< Pwm modulation center flag
6465
65- // foc control parameters
66- #define SCMD_LOOPFOC_TIME 'L' //!< loopFOC time between executions (filtered)
67- #define SCMD_MOVE_TIME 'M' //!< move time between executions (filtered)
68- #define SCMD_REINIT_FOC 'R' //!< reinitialize FOC
69- #define SCMD_TUNE_CURR 'C' //!< tune current controller
70- #define SCMD_MEAS_PARAMS 'P' //!< measure motor parameters (resistance and inductance)
66+ // foc control parameters
67+ #define SCMD_REINIT_FOC 'R' //!< reinitialize FOC
68+ #define SCMD_TUNE_CURR 'C' //!< tune current controller
69+ #define SCMD_MEAS_PARAMS 'P' //!< measure motor parameters (resistance and inductance)
7170
72- // subcommands for motor parameters measurement
73- #define SCMD_INDUCT_D 'D' //!< inductance d axis
74- #define SCMD_INDUCT_Q 'Q' //!< inductance q axis
71+ // subcommands for motor parameters measurement
72+ #define SCMD_INDUCT_D 'D' //!< inductance d axis
73+ #define SCMD_INDUCT_Q 'Q' //!< inductance q axis
7574```
7675
7776By modifying this header file you can modify the default command character for the whole library.
0 commit comments