[fix] fix macro

It was not making issues since by default PWM_FREQUENCY is also 1M.
This commit is contained in:
Gautier Hattenberger
2020-01-13 13:43:09 +01:00
parent 9b14ce423b
commit f646737d61
@@ -44,7 +44,7 @@
* in milliseconds to microseconds (required by pwmEnableChannel())
*/
#ifndef PWM_CMD_TO_US
#define PWM_CMD_TO_US(_t) (1000000 * _t / PWM_FREQUENCY)
#define PWM_CMD_TO_US(_t) (PWM_FREQUENCY * _t / 1000000)
#endif
int32_t actuators_pwm_values[ACTUATORS_PWM_NB];