aboutsummaryrefslogtreecommitdiff
path: root/apps/px4io/registers.c
diff options
context:
space:
mode:
authorpx4dev <px4@purgatory.org>2013-03-10 23:06:36 -0700
committerpx4dev <px4@purgatory.org>2013-03-12 22:22:49 -0700
commit57429fd12cc4277c88948c1819b245d9e83523d2 (patch)
treefc036f102ba82aa654cf5b87c5fbe4cead7859e8 /apps/px4io/registers.c
parent6cf0758b24de1e0e28e1bb65fa33a0b49b1601b9 (diff)
downloadpx4-firmware-57429fd12cc4277c88948c1819b245d9e83523d2.tar.gz
px4-firmware-57429fd12cc4277c88948c1819b245d9e83523d2.tar.bz2
px4-firmware-57429fd12cc4277c88948c1819b245d9e83523d2.zip
Convert HIL and FMU drivers to the new multirate PWM interface.
Diffstat (limited to 'apps/px4io/registers.c')
-rw-r--r--apps/px4io/registers.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/px4io/registers.c b/apps/px4io/registers.c
index b09937300..6c09def9e 100644
--- a/apps/px4io/registers.c
+++ b/apps/px4io/registers.c
@@ -616,19 +616,19 @@ pwm_configure_rates(uint16_t map, uint16_t defaultrate, uint16_t altrate)
if (mask == 0)
continue;
- /* all channels in the group must be either high or low-rate */
- uint32_t high = map & mask;
+ /* all channels in the group must be either default or alt-rate */
+ uint32_t alt = map & mask;
if (pass == 0) {
/* preflight */
- if ((high != 0) && (high != mask)) {
+ if ((alt != 0) && (alt != mask)) {
/* not a legal map, bail with an alarm */
r_status_alarms |= PX4IO_P_STATUS_ALARMS_PWM_ERROR;
return;
}
} else {
/* set it - errors here are unexpected */
- if (high != 0) {
+ if (alt != 0) {
if (up_pwm_servo_set_rate_group_update(group, r_setup_pwm_altrate) != OK)
r_status_alarms |= PX4IO_P_STATUS_ALARMS_PWM_ERROR;
} else {