Searched refs:int_tofp (Results 1 – 1 of 1) sorted by relevance
42 #define int_tofp(X) ((int64_t)(X) << FRAC_BITS) macro160 .max_perf = int_tofp(1),173 pid->integral = int_tofp(integral); in pid_reset()174 pid->last_err = int_tofp(setpoint) - int_tofp(busy); in pid_reset()179 pid->p_gain = div_fp(int_tofp(percent), int_tofp(100)); in pid_p_gain_set()184 pid->i_gain = div_fp(int_tofp(percent), int_tofp(100)); in pid_i_gain_set()189 pid->d_gain = div_fp(int_tofp(percent), int_tofp(100)); in pid_d_gain_set()198 fp_error = int_tofp(pid->setpoint) - busy; in pid_calc()200 if (abs(fp_error) <= int_tofp(pid->deadband)) in pid_calc()215 integral_limit = int_tofp(30); in pid_calc()[all …]