mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-11 02:18:29 -04:00
uncrustify libraries/RC_Channel/RC_Channel.cpp
This commit is contained in:
parent
a3e1c70801
commit
79e1b84b4f
@ -1,12 +1,12 @@
|
||||
/*
|
||||
RC_Channel.cpp - Radio library for Arduino
|
||||
Code by Jason Short. DIYDrones.com
|
||||
|
||||
This library is free software; you can redistribute it and / or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
* RC_Channel.cpp - Radio library for Arduino
|
||||
* Code by Jason Short. DIYDrones.com
|
||||
*
|
||||
* This library is free software; you can redistribute it and / or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
*/
|
||||
|
||||
#include <math.h>
|
||||
@ -141,13 +141,13 @@ RC_Channel::set_pwm(int16_t pwm)
|
||||
{
|
||||
|
||||
/*if(_filter){
|
||||
if(radio_in == 0)
|
||||
radio_in = pwm;
|
||||
else
|
||||
radio_in = (pwm + radio_in) >> 1; // Small filtering
|
||||
}else{
|
||||
radio_in = pwm;
|
||||
}*/
|
||||
* if(radio_in == 0)
|
||||
* radio_in = pwm;
|
||||
* else
|
||||
* radio_in = (pwm + radio_in) >> 1; // Small filtering
|
||||
* }else{
|
||||
* radio_in = pwm;
|
||||
* }*/
|
||||
|
||||
radio_in = pwm;
|
||||
|
||||
@ -172,12 +172,12 @@ RC_Channel::set_pwm(int16_t pwm)
|
||||
}
|
||||
|
||||
/*
|
||||
// coming soon ??
|
||||
if(expo) {
|
||||
long temp = control_in;
|
||||
temp = (temp * temp) / (long)_high;
|
||||
control_in = (int16_t)((control_in >= 0) ? temp : -temp);
|
||||
}*/
|
||||
* // coming soon ??
|
||||
* if(expo) {
|
||||
* long temp = control_in;
|
||||
* temp = (temp * temp) / (long)_high;
|
||||
* control_in = (int16_t)((control_in >= 0) ? temp : -temp);
|
||||
* }*/
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user