aboutsummaryrefslogtreecommitdiff
path: root/src/drivers/drv_pwm_output.h
diff options
context:
space:
mode:
authorJulian Oes <julian@oes.ch>2013-10-07 18:03:05 +0200
committerJulian Oes <julian@oes.ch>2013-10-07 18:03:05 +0200
commit19879432ad6cf709af25192401829719defd2983 (patch)
tree567bda3cb54df9c177ac1d2e47ece0c30ba03bce /src/drivers/drv_pwm_output.h
parent03edf901617c5f5785ef7d78d8fa74e2bfdd45fc (diff)
downloadpx4-firmware-19879432ad6cf709af25192401829719defd2983.tar.gz
px4-firmware-19879432ad6cf709af25192401829719defd2983.tar.bz2
px4-firmware-19879432ad6cf709af25192401829719defd2983.zip
Trying to get rid of magic PWM numbers
Diffstat (limited to 'src/drivers/drv_pwm_output.h')
-rw-r--r--src/drivers/drv_pwm_output.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/drivers/drv_pwm_output.h b/src/drivers/drv_pwm_output.h
index 76e98597a..5a3a126d0 100644
--- a/src/drivers/drv_pwm_output.h
+++ b/src/drivers/drv_pwm_output.h
@@ -65,6 +65,26 @@ __BEGIN_DECLS
#define PWM_OUTPUT_MAX_CHANNELS 16
/**
+ * Minimum PWM in us
+ */
+#define PWM_MIN 900
+
+/**
+ * Highest PWM allowed as the minimum PWM
+ */
+#define PWM_HIGHEST_MIN 1300
+
+/**
+ * Maximum PWM in us
+ */
+#define PWM_MAX 2100
+
+/**
+ * Lowest PWM allowed as the maximum PWM
+ */
+#define PWM_LOWEST_MAX 1700
+
+/**
* Servo output signal type, value is actual servo output pulse
* width in microseconds.
*/