industry/foc/*/foc_angle.c: run method should return int
This commit is contained in:
parent
27c282a58a
commit
cb78f6d0df
@ -76,9 +76,9 @@ struct foc_angle_ops_b16_s
|
|||||||
|
|
||||||
/* Run */
|
/* Run */
|
||||||
|
|
||||||
CODE void (*run)(FAR foc_angle_b16_t *h,
|
CODE int (*run)(FAR foc_angle_b16_t *h,
|
||||||
FAR struct foc_angle_in_b16_s *in,
|
FAR struct foc_angle_in_b16_s *in,
|
||||||
FAR struct foc_angle_out_b16_s *out);
|
FAR struct foc_angle_out_b16_s *out);
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Angle handler - sensor or sensorless */
|
/* Angle handler - sensor or sensorless */
|
||||||
@ -135,8 +135,8 @@ int foc_angle_cfg_b16(FAR foc_angle_b16_t *h, FAR void *cfg);
|
|||||||
* Name: foc_angle_run_b16
|
* Name: foc_angle_run_b16
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
void foc_angle_run_b16(FAR foc_angle_b16_t *h,
|
int foc_angle_run_b16(FAR foc_angle_b16_t *h,
|
||||||
FAR struct foc_angle_in_b16_s *in,
|
FAR struct foc_angle_in_b16_s *in,
|
||||||
FAR struct foc_angle_out_b16_s *out);
|
FAR struct foc_angle_out_b16_s *out);
|
||||||
|
|
||||||
#endif /* __INDUSTRY_FOC_FIXED16_FOC_ANGLE_H */
|
#endif /* __INDUSTRY_FOC_FIXED16_FOC_ANGLE_H */
|
||||||
|
@ -76,9 +76,9 @@ struct foc_angle_ops_f32_s
|
|||||||
|
|
||||||
/* Run angle handler */
|
/* Run angle handler */
|
||||||
|
|
||||||
CODE void (*run)(FAR foc_angle_f32_t *h,
|
CODE int (*run)(FAR foc_angle_f32_t *h,
|
||||||
FAR struct foc_angle_in_f32_s *in,
|
FAR struct foc_angle_in_f32_s *in,
|
||||||
FAR struct foc_angle_out_f32_s *out);
|
FAR struct foc_angle_out_f32_s *out);
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Angle handler - sensor or sensorless */
|
/* Angle handler - sensor or sensorless */
|
||||||
@ -135,8 +135,8 @@ int foc_angle_cfg_f32(FAR foc_angle_f32_t *h, FAR void *cfg);
|
|||||||
* Name: foc_angle_run_f32
|
* Name: foc_angle_run_f32
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
void foc_angle_run_f32(FAR foc_angle_f32_t *h,
|
int foc_angle_run_f32(FAR foc_angle_f32_t *h,
|
||||||
FAR struct foc_angle_in_f32_s *in,
|
FAR struct foc_angle_in_f32_s *in,
|
||||||
FAR struct foc_angle_out_f32_s *out);
|
FAR struct foc_angle_out_f32_s *out);
|
||||||
|
|
||||||
#endif /* __INDUSTRY_FOC_FLOAT_FOC_ANGLE_H */
|
#endif /* __INDUSTRY_FOC_FLOAT_FOC_ANGLE_H */
|
||||||
|
@ -143,7 +143,7 @@ int foc_angle_cfg_b16(FAR foc_angle_b16_t *h, FAR void *cfg)
|
|||||||
*
|
*
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
void foc_angle_run_b16(FAR foc_angle_b16_t *h,
|
int foc_angle_run_b16(FAR foc_angle_b16_t *h,
|
||||||
FAR struct foc_angle_in_b16_s *in,
|
FAR struct foc_angle_in_b16_s *in,
|
||||||
FAR struct foc_angle_out_b16_s *out)
|
FAR struct foc_angle_out_b16_s *out)
|
||||||
{
|
{
|
||||||
@ -153,5 +153,5 @@ void foc_angle_run_b16(FAR foc_angle_b16_t *h,
|
|||||||
|
|
||||||
/* Run angle handler */
|
/* Run angle handler */
|
||||||
|
|
||||||
h->ops->run(h, in, out);
|
return h->ops->run(h, in, out);
|
||||||
}
|
}
|
||||||
|
@ -143,9 +143,9 @@ int foc_angle_cfg_f32(FAR foc_angle_f32_t *h, FAR void *cfg)
|
|||||||
*
|
*
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
void foc_angle_run_f32(FAR foc_angle_f32_t *h,
|
int foc_angle_run_f32(FAR foc_angle_f32_t *h,
|
||||||
FAR struct foc_angle_in_f32_s *in,
|
FAR struct foc_angle_in_f32_s *in,
|
||||||
FAR struct foc_angle_out_f32_s *out)
|
FAR struct foc_angle_out_f32_s *out)
|
||||||
{
|
{
|
||||||
DEBUGASSERT(h);
|
DEBUGASSERT(h);
|
||||||
DEBUGASSERT(in);
|
DEBUGASSERT(in);
|
||||||
@ -153,5 +153,5 @@ void foc_angle_run_f32(FAR foc_angle_f32_t *h,
|
|||||||
|
|
||||||
/* Run angle handler */
|
/* Run angle handler */
|
||||||
|
|
||||||
h->ops->run(h, in, out);
|
return h->ops->run(h, in, out);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user