/* * BikeRatioCal.h * * Created on: 2025年3月27日 * Author: zhouxiong9 */ #ifndef BIKERATIOCAL_H_ #define BIKERATIOCAL_H_ #include "typedefine.h" //传动比计算参数 typedef struct { UWORD RatioPer; //实时传动比,车轮转速 / 牙盘转速 * 1024 UWORD RatioFlt; //传动比滤波值 SLONG RatioFltSum; UWORD RatioDefault; //传动比默認值 UWORD RatioResult; //传动比输出 }Bike_RatioCal_Struct_t; extern Bike_RatioCal_Struct_t Bike_RatioCalParam; extern void BikeRatioCal_Init(UWORD Teeth_F, UWORD Teeth_B); extern void BikeRatioCal_Process(UWORD MotorSpeed, UWORD Cadence, UWORD BikeSpeedRpm, UWORD PedalTorqueNm, UWORD Current, Bike_RatioCal_Struct_t* p_Bike_RatioCal); #endif /* 3_BASICFUNCTION_INCLUDE_BIKERATIOCAL_H_ */