torque.h 498 B

123456789101112131415161718192021
  1. #ifndef _TORQUE_LUT_H__
  2. #define _TORQUE_LUT_H__
  3. #include "os/os_types.h"
  4. #include "foc/core/PMSM_FOC_Core.h"
  5. typedef struct {
  6. float thro_prev;
  7. float speed_prev;
  8. float torque_prev;
  9. float accl_ref;
  10. bool accl;
  11. float thro_value; //油门开度百分比
  12. float spd_ref;
  13. u32 count;
  14. }torque_manager_t;
  15. void torque_init(void);
  16. void torque_reset(void);
  17. void torque_get_idq(float torque, float rpm, DQ_t *dq_out);
  18. void throttle_process(u8 run_mode, float f_throttle);
  19. #endif /*_TORQUE_LUT_H__ */