mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-07-02 17:50:35 +08:00
simulator: make sensor update rate dependent of the HIL_SENSOR bitmask
This commit is contained in:
@@ -198,7 +198,7 @@ private:
|
||||
void send_controls();
|
||||
void send_heartbeat();
|
||||
void send_mavlink_message(const mavlink_message_t &aMsg);
|
||||
void update_sensors(const hrt_abstime &time, const mavlink_hil_sensor_t &imu);
|
||||
void update_sensors(const hrt_abstime &time, const mavlink_hil_sensor_t &sensors);
|
||||
|
||||
static void *sending_trampoline(void *);
|
||||
|
||||
@@ -245,6 +245,15 @@ private:
|
||||
WaitingForActuatorControls = 1,
|
||||
WaitingForEkf2Timestamp = 2,
|
||||
};
|
||||
|
||||
///! Enumeration to use on the bitmask in HIL_SENSOR
|
||||
enum SensorSource {
|
||||
ACCEL = 0x0007,
|
||||
GYRO = 0x0038,
|
||||
MAG = 0x01C0,
|
||||
BARO = 0x1A00,
|
||||
DIFF_PRESS = 0x0400
|
||||
};
|
||||
#endif
|
||||
|
||||
DEFINE_PARAMETERS(
|
||||
|
||||
Reference in New Issue
Block a user