mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-06-01 21:07:40 +08:00
remove some old ets airspeed and baro cruft
This commit is contained in:
@@ -134,12 +134,6 @@ static void csc_main_init( void ) {
|
|||||||
#ifdef USE_AIRSPEED
|
#ifdef USE_AIRSPEED
|
||||||
airspeed_init();
|
airspeed_init();
|
||||||
#endif
|
#endif
|
||||||
#ifdef USE_AIRSPEED_ETS
|
|
||||||
airspeed_ets_init();
|
|
||||||
#endif
|
|
||||||
#ifdef USE_BARO_ETS
|
|
||||||
baro_ets_init();
|
|
||||||
#endif
|
|
||||||
#ifdef USE_AMS5812
|
#ifdef USE_AMS5812
|
||||||
csc_ams5812_init();
|
csc_ams5812_init();
|
||||||
#endif
|
#endif
|
||||||
@@ -181,19 +175,10 @@ static void csc_main_periodic( void )
|
|||||||
csc_adc_periodic();
|
csc_adc_periodic();
|
||||||
|
|
||||||
if ((csc_loops % AIRSPEED_TIMEOUT) == 0) {
|
if ((csc_loops % AIRSPEED_TIMEOUT) == 0) {
|
||||||
#ifdef USE_AIRSPEED_ETS
|
|
||||||
airspeed_ets_periodic();
|
|
||||||
#endif
|
|
||||||
#ifdef USE_BARO_ETS
|
|
||||||
baro_ets_read();
|
|
||||||
#endif
|
|
||||||
} else if ((csc_loops % AIRSPEED_TIMEOUT) == 1) {
|
} else if ((csc_loops % AIRSPEED_TIMEOUT) == 1) {
|
||||||
#ifdef USE_BARO_ETS
|
#ifdef USE_BARO_ETS
|
||||||
baro_ets_periodic();
|
baro_ets_periodic();
|
||||||
#endif
|
#endif
|
||||||
#ifdef USE_AIRSPEED_ETS
|
|
||||||
airspeed_ets_read();
|
|
||||||
#endif
|
|
||||||
#ifdef USE_AIRSPEED
|
#ifdef USE_AIRSPEED
|
||||||
csc_airspeed_periodic();
|
csc_airspeed_periodic();
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -95,10 +95,6 @@
|
|||||||
#include "usb_serial.h"
|
#include "usb_serial.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef USE_AIRSPEED_ETS
|
|
||||||
#include "airspeed_ets.h"
|
|
||||||
#endif // USE_AIRSPEED_ETS
|
|
||||||
|
|
||||||
#ifdef USE_BARO_ETS
|
#ifdef USE_BARO_ETS
|
||||||
#include "baro_ets.h"
|
#include "baro_ets.h"
|
||||||
#endif // USE_BARO_ETS
|
#endif // USE_BARO_ETS
|
||||||
@@ -501,30 +497,6 @@ void periodic_task_ap( void ) {
|
|||||||
#error "Only 20 and 60 allowed for CONTROL_RATE"
|
#error "Only 20 and 60 allowed for CONTROL_RATE"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef USE_I2C0
|
|
||||||
// I2C0 scheduler
|
|
||||||
switch (_20Hz) {
|
|
||||||
case 0:
|
|
||||||
#ifdef USE_AIRSPEED_ETS
|
|
||||||
airspeed_ets_periodic(); // process airspeed
|
|
||||||
#endif // USE_AIRSPEED_ETS
|
|
||||||
#ifdef USE_BARO_ETS
|
|
||||||
baro_ets_read(); // initiate next i2c read
|
|
||||||
#endif // USE_BARO_ETS
|
|
||||||
break;
|
|
||||||
case 1:
|
|
||||||
#ifdef USE_BARO_ETS
|
|
||||||
baro_ets_periodic(); // process altitude
|
|
||||||
#endif // USE_BARO_ETS
|
|
||||||
#ifdef USE_AIRSPEED_ETS
|
|
||||||
airspeed_ets_read(); // initiate next i2c read
|
|
||||||
#endif // USE_AIRSPEED_ETS
|
|
||||||
break;
|
|
||||||
case 2:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
#endif // USE_I2C0
|
|
||||||
|
|
||||||
#if CONTROL_RATE == 20
|
#if CONTROL_RATE == 20
|
||||||
if (!_20Hz)
|
if (!_20Hz)
|
||||||
#endif
|
#endif
|
||||||
@@ -534,9 +506,6 @@ void periodic_task_ap( void ) {
|
|||||||
gyro_update();
|
gyro_update();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined USE_AIRSPEED || defined MEASURE_AIRSPEED
|
|
||||||
airspeed_update();
|
|
||||||
#endif
|
|
||||||
#ifdef INFRARED
|
#ifdef INFRARED
|
||||||
ir_update();
|
ir_update();
|
||||||
estimator_update_state_infrared();
|
estimator_update_state_infrared();
|
||||||
@@ -581,9 +550,6 @@ void init_ap( void ) {
|
|||||||
#ifdef GYRO
|
#ifdef GYRO
|
||||||
gyro_init();
|
gyro_init();
|
||||||
#endif
|
#endif
|
||||||
#if defined USE_AIRSPEED || defined MEASURE_AIRSPEED
|
|
||||||
airspeed_init();
|
|
||||||
#endif
|
|
||||||
#ifdef GPS
|
#ifdef GPS
|
||||||
gps_init();
|
gps_init();
|
||||||
#endif
|
#endif
|
||||||
@@ -610,14 +576,6 @@ void init_ap( void ) {
|
|||||||
i2c1_init();
|
i2c1_init();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef USE_AIRSPEED_ETS
|
|
||||||
airspeed_ets_init();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef USE_BARO_ETS
|
|
||||||
baro_ets_init();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef USE_ADC_GENERIC
|
#ifdef USE_ADC_GENERIC
|
||||||
adc_generic_init();
|
adc_generic_init();
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user