diff options
author | Andrew Tridgell <tridge@samba.org> | 2013-01-06 06:29:28 +1100 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2013-01-06 06:29:28 +1100 |
commit | 219ab05a707d8f2795dc91f5884a42f20dd6a640 (patch) | |
tree | 06cbc29edd9196a9e0dacea77884a38d5fe83a38 /apps/drivers/hil/hil.cpp | |
parent | 920608bf3671662f94b4939ffdaf6fde2b08edff (diff) | |
download | px4-firmware-219ab05a707d8f2795dc91f5884a42f20dd6a640.tar.gz px4-firmware-219ab05a707d8f2795dc91f5884a42f20dd6a640.tar.bz2 px4-firmware-219ab05a707d8f2795dc91f5884a42f20dd6a640.zip |
added PWM_SERVO_SET_UPDATE_RATE ioctl
this allows apps to set the PWM update rate. APM needs this to honor
the user configurable PWM rate setting for copters.
Diffstat (limited to 'apps/drivers/hil/hil.cpp')
-rw-r--r-- | apps/drivers/hil/hil.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/apps/drivers/hil/hil.cpp b/apps/drivers/hil/hil.cpp index 67b16aa42..32bdb0776 100644 --- a/apps/drivers/hil/hil.cpp +++ b/apps/drivers/hil/hil.cpp @@ -503,6 +503,10 @@ HIL::pwm_ioctl(file *filp, int cmd, unsigned long arg) // up_pwm_servo_arm(false); break; + case PWM_SERVO_SET_UPDATE_RATE: + g_hil->set_pwm_rate(arg); + break; + case PWM_SERVO_SET(2): case PWM_SERVO_SET(3): if (_mode != MODE_4PWM) { |