» S
h
o
w
 
M
e
n
u

PWM Frequencies

AutoQuad will use fast PWM frequencies on the motor ports. For now the frequency is fixed on 400Hz when using the port for motors.  Connecting a standard (analog) servo for use as a gimbal can result in a non working servo because most (analog) servo’s will accept a PWM frequency between 30-100Hz.  Digital servos can go as high as 400Hz, but typically work best in the 300-333Hz range. You can set the desired gimbal servo PWM frequency using the ground control software (QGC), on the Gimbal parameters page.

AQ uses 6 different timers within it’s infrastructure. Within a timer you can only use one frequency. So, for using a lower pwm rate on a port you must use a timer that is not used by a motor.

Port numbers and timers reference

AQ-ports-reference

Examples

That raises the question about motor timers. It is possible to occupy all timers for motors, but you could also concentrate them for using as low as 1 timer (for a quad). A table can be made to spot the possibilities;

timer GPIO GPIO_PIN pwm port example
1 E 9 M01 motor
1 E 11 M02 motor
1 E 13 M03  
1 E 14 M04 external led
4 D 12 M05 motor
4 D 13 M06  
4 D 14 M07  
4 D 15 M08 motor
9 E 5 M09  
9 E 6 M10 gimbal servo
2 B 10 M11  
2 B 11 M12 motor
10 B 8 M13  
11 B 9 M14 gimbal servo

In this example 3 timers (1, 4 & 2) are used for 4 motors. The gimbals have separate timers.
if you want to use a minimum of timers you could use this example;

timer GPIO GPIO_PIN pwm port example
1 E 9 M01 motor
1 E 11 M02 motor
1 E 13 M03 motor
1 E 14 M04 motor
4 D 12 M05  
4 D 13 M06  
4 D 14 M07 gimbal servo
4 D 15 M08 gimbal servo
9 E 5 M09  
9 E 6 M10  
2 B 10 M11  
2 B 11 M12  
10 B 8 M13  
11 B 9 M14  
This page was created on 18-Jun-12 by menno. Last modified on 17-Oct-14 by jussi.