Paparazzi UAS  v6.2_unstable
Paparazzi is a free software Unmanned Aircraft System.
nps_sensors.c
Go to the documentation of this file.
1 #include "nps_sensors.h"
2 
4 
5 void nps_sensors_init(double time)
6 {
7 
8  struct DoubleEulers body_to_imu_eulers =
9  { NPS_BODY_TO_IMU_PHI, NPS_BODY_TO_IMU_THETA, NPS_BODY_TO_IMU_PSI };
10  double_rmat_of_eulers(&sensors.body_to_imu_rmat, &body_to_imu_eulers);
11 
22 }
23 
24 
25 void nps_sensors_run_step(double time)
26 {
37 }
38 
39 
41 {
44  return TRUE;
45  }
46  return FALSE;
47 }
48 
50 {
53  return TRUE;
54  }
55  return FALSE;
56 }
57 
59 {
62  return TRUE;
63  }
64  return FALSE;
65 }
66 
68 {
71  return TRUE;
72  }
73  return FALSE;
74 }
75 
77 {
80  return TRUE;
81  }
82  return FALSE;
83 }
84 
86 {
89  return TRUE;
90  }
91  return FALSE;
92 }
93 
95 {
98  return TRUE;
99  }
100  return FALSE;
101 }
102 
104 {
105  if (sensors.aoa.data_available) {
107  return TRUE;
108  }
109  return FALSE;
110 }
111 
113 {
116  return TRUE;
117  }
118  return FALSE;
119 }
double_rmat_of_eulers
static void double_rmat_of_eulers(struct DoubleRMat *rm, struct DoubleEulers *e)
Definition: pprz_algebra_double.h:190
nps_sensor_sonar_run_step
void nps_sensor_sonar_run_step(struct NpsSensorSonar *sonar, double time)
Definition: nps_sensor_sonar.c:63
NpsSensors::temp
struct NpsSensorTemperature temp
Definition: nps_sensors.h:31
nps_sensors_aoa_available
bool nps_sensors_aoa_available(void)
Definition: nps_sensors.c:103
nps_sensor_gps_init
void nps_sensor_gps_init(struct NpsSensorGps *gps, double time)
Definition: nps_sensor_gps.c:10
NpsSensors::gyro
struct NpsSensorGyro gyro
Definition: nps_sensors.h:24
nps_sensor_airspeed_init
void nps_sensor_airspeed_init(struct NpsSensorAirspeed *airspeed, double time)
Definition: nps_sensor_airspeed.c:53
nps_sensors_sonar_available
bool nps_sensors_sonar_available(void)
Definition: nps_sensors.c:76
nps_sensors_init
void nps_sensors_init(double time)
Definition: nps_sensors.c:5
NpsSensors::airspeed
struct NpsSensorAirspeed airspeed
Definition: nps_sensors.h:30
NpsSensors::baro
struct NpsSensorBaro baro
Definition: nps_sensors.h:27
nps_sensors_sideslip_available
bool nps_sensors_sideslip_available(void)
Definition: nps_sensors.c:112
NpsSensors::accel
struct NpsSensorAccel accel
Definition: nps_sensors.h:25
nps_sensors_gyro_available
bool nps_sensors_gyro_available(void)
Definition: nps_sensors.c:40
NpsSensorGps::data_available
bool data_available
Definition: nps_sensor_gps.h:30
NpsSensorSonar::data_available
bool data_available
Definition: nps_sensor_sonar.h:42
nps_sensor_gps_run_step
void nps_sensor_gps_run_step(struct NpsSensorGps *gps, double time)
Definition: nps_sensor_gps.c:39
nps_sensors_temperature_available
bool nps_sensors_temperature_available(void)
Definition: nps_sensors.c:94
NpsSensorBaro::data_available
bool data_available
Definition: nps_sensor_baro.h:13
nps_sensors_mag_available
bool nps_sensors_mag_available(void)
Definition: nps_sensors.c:49
nps_sensor_aoa_run_step
void nps_sensor_aoa_run_step(struct NpsSensorAngleOfAttack *aoa, double time)
Definition: nps_sensor_aoa.c:62
nps_sensors_baro_available
bool nps_sensors_baro_available(void)
Definition: nps_sensors.c:58
nps_sensor_sideslip_run_step
void nps_sensor_sideslip_run_step(struct NpsSensorSideSlip *sideslip, double time)
Definition: nps_sensor_sideslip.c:63
nps_sensors_airspeed_available
bool nps_sensors_airspeed_available(void)
Definition: nps_sensors.c:85
nps_sensor_gyro_run_step
void nps_sensor_gyro_run_step(struct NpsSensorGyro *gyro, double time, struct DoubleRMat *body_to_imu)
Definition: nps_sensor_gyro.c:31
NpsSensorGyro::data_available
bool data_available
Definition: nps_sensor_gyro.h:20
NpsSensors::aoa
struct NpsSensorAngleOfAttack aoa
Definition: nps_sensors.h:32
nps_sensor_aoa_init
void nps_sensor_aoa_init(struct NpsSensorAngleOfAttack *aoa, double time)
Definition: nps_sensor_aoa.c:52
NpsSensors::body_to_imu_rmat
struct DoubleRMat body_to_imu_rmat
Definition: nps_sensors.h:23
nps_sensor_mag_init
void nps_sensor_mag_init(struct NpsSensorMag *mag, double time)
Definition: nps_sensor_mag.c:8
NpsSensorMag::data_available
bool data_available
Definition: nps_sensor_mag.h:18
nps_sensors_gps_available
bool nps_sensors_gps_available(void)
Definition: nps_sensors.c:67
nps_sensor_gyro_init
void nps_sensor_gyro_init(struct NpsSensorGyro *gyro, double time)
Definition: nps_sensor_gyro.c:9
nps_sensor_baro_init
void nps_sensor_baro_init(struct NpsSensorBaro *baro, double time)
Definition: nps_sensor_baro.c:14
NpsSensorAngleOfAttack::data_available
bool data_available
Definition: nps_sensor_aoa.h:41
nps_sensors.h
nps_sensor_sonar_init
void nps_sensor_sonar_init(struct NpsSensorSonar *sonar, double time)
Definition: nps_sensor_sonar.c:53
nps_sensors_run_step
void nps_sensors_run_step(double time)
Definition: nps_sensors.c:25
nps_sensor_baro_run_step
void nps_sensor_baro_run_step(struct NpsSensorBaro *baro, double time)
Definition: nps_sensor_baro.c:23
nps_sensor_temperature_init
void nps_sensor_temperature_init(struct NpsSensorTemperature *temperature, double time)
Definition: nps_sensor_temperature.c:19
sensors
struct NpsSensors sensors
Definition: nps_sensors.c:3
NpsSensorTemperature::data_available
bool data_available
Definition: nps_sensor_temperature.h:13
nps_sensor_airspeed_run_step
void nps_sensor_airspeed_run_step(struct NpsSensorAirspeed *airspeed, double time)
Definition: nps_sensor_airspeed.c:63
nps_sensor_accel_init
void nps_sensor_accel_init(struct NpsSensorAccel *accel, double time)
Definition: nps_sensor_accel.c:8
nps_sensor_accel_run_step
void nps_sensor_accel_run_step(struct NpsSensorAccel *accel, double time, struct DoubleRMat *body_to_imu)
Definition: nps_sensor_accel.c:25
nps_sensor_temperature_run_step
void nps_sensor_temperature_run_step(struct NpsSensorTemperature *temperature, double time)
Definition: nps_sensor_temperature.c:28
NpsSensors::sonar
struct NpsSensorSonar sonar
Definition: nps_sensors.h:29
NpsSensors::mag
struct NpsSensorMag mag
Definition: nps_sensors.h:26
NpsSensorAirspeed::data_available
bool data_available
Definition: nps_sensor_airspeed.h:42
NpsSensors::gps
struct NpsSensorGps gps
Definition: nps_sensors.h:28
NpsSensors::sideslip
struct NpsSensorSideSlip sideslip
Definition: nps_sensors.h:33
FALSE
#define FALSE
Definition: std.h:5
TRUE
#define TRUE
Definition: std.h:4
nps_sensor_mag_run_step
void nps_sensor_mag_run_step(struct NpsSensorMag *mag, double time, struct DoubleRMat *body_to_imu)
Definition: nps_sensor_mag.c:26
NpsSensorSideSlip::data_available
bool data_available
Definition: nps_sensor_sideslip.h:41
nps_sensor_sideslip_init
void nps_sensor_sideslip_init(struct NpsSensorSideSlip *sideslip, double time)
Definition: nps_sensor_sideslip.c:53
NpsSensors
Definition: nps_sensors.h:22
DoubleEulers
euler angles
Definition: pprz_algebra_double.h:76