Paparazzi UAS
v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
|
Pan/Tilt camera API. More...
Go to the source code of this file.
Macros | |
#define | CAM_MODE_OFF 0 /* Do nothing */ |
#define | CAM_MODE_ANGLES 1 /* Input: servo angles */ |
#define | CAM_MODE_NADIR 2 /* Input: () */ |
#define | CAM_MODE_XY_TARGET 3 /* Input: target_x, target_y */ |
#define | CAM_MODE_WP_TARGET 4 /* Input: waypoint no */ |
#define | CAM_MODE_AC_TARGET 5 /* Input: ac id */ |
#define | CAM_MODE_STABILIZED 6 |
#define | CAM_MODE_RC 7 |
#define | CAM_PAN_MAX 90 |
#define | CAM_PAN_MIN -90 |
#define | CAM_TILT_MAX 90 |
#define | CAM_TILT_MIN -90 |
#define | cam_SetPanCommand(x) { cam_pan_command = x; imcu_set_command(COMMAND_CAM_PAN, cam_pan_command);} |
#define | cam_SetTiltCommand(x) { cam_tilt_command = x; imcu_set_command(COMMAND_CAM_TILT, cam_tilt_command);} |
Functions | |
void | cam_periodic (void) |
For CAM_MODE_AC_TARGET mode. More... | |
void | cam_init (void) |
Variables | |
uint8_t | cam_mode |
uint8_t | cam_lock |
float | cam_phi_c |
float | cam_theta_c |
float | cam_pan_c |
float | cam_tilt_c |
float | cam_target_x |
Radians, for CAM_MODE_ANGLES mode. More... | |
float | cam_target_y |
float | cam_target_alt |
uint8_t | cam_target_wp |
For CAM_MODE_XY_TARGET mode. More... | |
uint8_t | cam_target_ac |
For CAM_MODE_WP_TARGET mode. More... | |
int16_t | cam_pan_command |
int16_t | cam_tilt_command |
Pan/Tilt camera API.
Definition in file cam.h.
#define cam_SetPanCommand | ( | x | ) | { cam_pan_command = x; imcu_set_command(COMMAND_CAM_PAN, cam_pan_command);} |
#define cam_SetTiltCommand | ( | x | ) | { cam_tilt_command = x; imcu_set_command(COMMAND_CAM_TILT, cam_tilt_command);} |
void cam_init | ( | void | ) |
Definition at line 119 of file cam.c.
References cam_mode, CAM_MODE0, DefaultPeriodic, register_periodic_telemetry(), and send_cam().
void cam_periodic | ( | void | ) |
For CAM_MODE_AC_TARGET mode.
Definition at line 129 of file cam.c.
References AP_MODE_AUTO1, AP_MODE_AUTO2, autopilot_get_mode(), cam_ac_target(), cam_angles(), cam_mode, CAM_MODE_AC_TARGET, CAM_MODE_ANGLES, CAM_MODE_NADIR, CAM_MODE_OFF, CAM_MODE_RC, CAM_MODE_STABILIZED, CAM_MODE_WP_TARGET, CAM_MODE_XY_TARGET, cam_nadir(), CAM_PAN0, cam_pan_c, cam_target(), CAM_TILT0, cam_tilt_c, cam_waypoint_target(), LED_OFF, LED_ON, MAX_PPRZ, and MIN_PPRZ.
uint8_t cam_mode |
Definition at line 90 of file cam.c.
Referenced by cam_init(), cam_periodic(), cam_segment_periodic(), cam_segment_stop(), and vPoint().
float cam_pan_c |
Definition at line 72 of file cam.c.
Referenced by cam_angles(), cam_periodic(), and cam_target().
float cam_phi_c |
Definition at line 80 of file cam.c.
Referenced by cam_angles(), and send_cam().
uint8_t cam_target_wp |
For CAM_MODE_XY_TARGET mode.
Definition at line 84 of file cam.c.
Referenced by cam_waypoint_target().
float cam_target_x |
Radians, for CAM_MODE_ANGLES mode.
Definition at line 83 of file cam.c.
Referenced by cam_nadir(), cam_segment_periodic(), cam_target(), cam_waypoint_target(), and send_cam().