APM:Libraries
libraries
AC_PrecLand
AC_PrecLand_SITL.h
Go to the documentation of this file.
1
#pragma once
2
3
#if CONFIG_HAL_BOARD == HAL_BOARD_SITL
4
#include <
AP_Common/AP_Common.h
>
5
#include <
AP_Math/AP_Math.h
>
6
#include <
AC_PrecLand/AC_PrecLand_Backend.h
>
7
8
/*
9
* AC_PrecLand_SITL - supplies vectors to a fake landing target
10
*/
11
12
class
AC_PrecLand_SITL
:
public
AC_PrecLand_Backend
13
{
14
public
:
15
16
// Constructor
17
AC_PrecLand_SITL
(
const
AC_PrecLand
& frontend,
AC_PrecLand::precland_state
&
state
);
18
19
// perform any required initialisation of backend
20
void
init
()
override
;
21
22
// retrieve updates from sensor
23
void
update
()
override
;
24
25
// provides a unit vector towards the target in body frame
26
// returns same as have_los_meas()
27
bool
get_los_body
(
Vector3f
& ret)
override
;
28
29
// returns system time in milliseconds of last los measurement
30
uint32_t
los_meas_time_ms
()
override
{
return
_los_meas_time_ms
; }
31
32
// return true if there is a valid los measurement available
33
bool
have_los_meas
()
override
;
34
35
private
:
36
37
Vector3f
_los_meas_body
;
// unit vector in body frame pointing towards target
38
uint32_t
_los_meas_time_ms
;
// system time in milliseconds when los was measured
39
};
40
41
#endif
AC_PrecLand_SITL::los_meas_time_ms
uint32_t los_meas_time_ms() override
Definition:
AC_PrecLand_SITL.h:30
AC_PrecLand
Definition:
AC_PrecLand.h:18
AC_PrecLand_SITL::init
void init() override
Definition:
AC_PrecLand_SITL.cpp:17
AC_PrecLand_SITL::AC_PrecLand_SITL
AC_PrecLand_SITL(const AC_PrecLand &frontend, AC_PrecLand::precland_state &state)
Definition:
AC_PrecLand_SITL.cpp:11
AC_PrecLand_SITL::get_los_body
bool get_los_body(Vector3f &ret) override
Definition:
AC_PrecLand_SITL.cpp:54
AC_PrecLand_SITL::_los_meas_time_ms
uint32_t _los_meas_time_ms
Definition:
AC_PrecLand_SITL.h:38
AC_PrecLand_SITL::update
void update() override
Definition:
AC_PrecLand_SITL.cpp:22
state
static int state
Definition:
Util.cpp:20
AP_Math.h
AC_PrecLand_SITL::have_los_meas
bool have_los_meas() override
Definition:
AC_PrecLand_SITL.cpp:47
AP_Common.h
Common definitions and utility routines for the ArduPilot libraries.
AC_PrecLand_Backend
Definition:
AC_PrecLand_Backend.h:8
AC_PrecLand_SITL::_los_meas_body
Vector3f _los_meas_body
Definition:
AC_PrecLand_SITL.h:37
AC_PrecLand_Backend.h
AC_PrecLand::precland_state
Definition:
AC_PrecLand.h:145
Vector3< float >
AC_PrecLand_SITL
Definition:
AC_PrecLand_SITL.h:12
Generated on Sun Jun 17 2018 14:18:47 for APM:Libraries by
1.8.13