libdsp/lib_observer.c: update some comments
The angle observer always refer to a motor electrical angle, while the speed observer can be applied to a motor electrical speed or a motor mechanical speed.
This commit is contained in:
parent
26f1be27dd
commit
01cbe9133e
@ -289,9 +289,9 @@ struct motor_aobserver_f32_s
|
|||||||
|
|
||||||
struct motor_sobserver_div_f32_s
|
struct motor_sobserver_div_f32_s
|
||||||
{
|
{
|
||||||
float angle_diff; /* Mechanical angle difference */
|
float angle_diff; /* Angle difference */
|
||||||
float angle_acc; /* Accumulated mechanical angle */
|
float angle_acc; /* Accumulated angle */
|
||||||
float angle_prev; /* Previous mechanical angle */
|
float angle_prev; /* Previous angle */
|
||||||
float one_by_dt; /* Frequency of observer execution */
|
float one_by_dt; /* Frequency of observer execution */
|
||||||
float cntr; /* Sample counter */
|
float cntr; /* Sample counter */
|
||||||
float samples; /* Number of samples for observer */
|
float samples; /* Number of samples for observer */
|
||||||
|
@ -410,7 +410,7 @@ void motor_aobserver_smo(FAR struct motor_aobserver_f32_s *o,
|
|||||||
*
|
*
|
||||||
* Input Parameters:
|
* Input Parameters:
|
||||||
* so - (in/out) pointer to the DIV speed observer data
|
* so - (in/out) pointer to the DIV speed observer data
|
||||||
* sample - (in) number of mechanical angle samples
|
* sample - (in) number of angle samples
|
||||||
* filter - (in) low-pass filter for final omega
|
* filter - (in) low-pass filter for final omega
|
||||||
* per - (in) speed observer execution period
|
* per - (in) speed observer execution period
|
||||||
*
|
*
|
||||||
@ -447,13 +447,13 @@ void motor_sobserver_div_init(FAR struct motor_sobserver_div_f32_s *so,
|
|||||||
* Name: motor_sobserver_div
|
* Name: motor_sobserver_div
|
||||||
*
|
*
|
||||||
* Description:
|
* Description:
|
||||||
* Estimate motor mechanical speed based on motor mechanical angle
|
* Estimate motor speed based on motor angle difference (electrical
|
||||||
* difference.
|
* or mechanical)
|
||||||
*
|
*
|
||||||
* Input Parameters:
|
* Input Parameters:
|
||||||
* o - (in/out) pointer to the speed observer data
|
* o - (in/out) pointer to the speed observer data
|
||||||
* angle - (in) mechanical angle normalized to <0.0, 2PI>
|
* angle - (in) angle normalized to <0.0, 2PI>
|
||||||
* dir - (in) mechanical rotation direction. Valid values:
|
* dir - (in) rotation direction. Valid values:
|
||||||
* DIR_CW (1.0f) or DIR_CCW(-1.0f)
|
* DIR_CW (1.0f) or DIR_CCW(-1.0f)
|
||||||
*
|
*
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
@ -731,13 +731,13 @@ void motor_sobserver_pll(FAR struct motor_sobserver_f32_s *o,
|
|||||||
* Name: motor_sobserver_speed_get
|
* Name: motor_sobserver_speed_get
|
||||||
*
|
*
|
||||||
* Description:
|
* Description:
|
||||||
* Get the estmiated motor mechanical speed from the observer
|
* Get the estmiated motor speed from the observer
|
||||||
*
|
*
|
||||||
* Input Parameters:
|
* Input Parameters:
|
||||||
* o - (in/out) pointer to the speed observer data
|
* o - (in/out) pointer to the speed observer data
|
||||||
*
|
*
|
||||||
* Returned Value:
|
* Returned Value:
|
||||||
* Return estimated motor mechanical speed from observer
|
* Return estimated motor speed from observer
|
||||||
*
|
*
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
@ -758,7 +758,7 @@ float motor_sobserver_speed_get(FAR struct motor_sobserver_f32_s *o)
|
|||||||
* o - (in/out) pointer to the angle observer data
|
* o - (in/out) pointer to the angle observer data
|
||||||
*
|
*
|
||||||
* Returned Value:
|
* Returned Value:
|
||||||
* Return estimated motor mechanical angle from observer
|
* Return estimated motor electrical angle from observer
|
||||||
*
|
*
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user