Paparazzi UAS  v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
servo_cam_ctrl.c File Reference

Digital Camera Control. More...

#include "servo_cam_ctrl.h"
#include "generated/modules.h"
#include "std.h"
#include "inter_mcu.h"
#include "generated/airframe.h"
+ Include dependency graph for servo_cam_ctrl.c:

Go to the source code of this file.

Macros

#define DC_PUSH(X)   imcu_set_command(X, -MAX_PPRZ);
 
#define DC_RELEASE(X)   imcu_set_command(X, MAX_PPRZ);
 
#define DC_SHUTTER_DELAY   0.5
 how long to push shutter in seconds More...
 

Functions

void servo_cam_ctrl_init (void)
 
void servo_cam_ctrl_periodic (void)
 
void dc_send_command (uint8_t cmd)
 Send Command To Camera. More...
 

Variables

static uint8_t dc_timer
 

Detailed Description

Digital Camera Control.

Provides the control of the shutter and the zoom of a digital camera via servos.

Definition in file servo_cam_ctrl.c.

Macro Definition Documentation

◆ DC_PUSH

#define DC_PUSH (   X)    imcu_set_command(X, -MAX_PPRZ);

Definition at line 39 of file servo_cam_ctrl.c.

◆ DC_RELEASE

#define DC_RELEASE (   X)    imcu_set_command(X, MAX_PPRZ);

Definition at line 40 of file servo_cam_ctrl.c.

◆ DC_SHUTTER_DELAY

#define DC_SHUTTER_DELAY   0.5

how long to push shutter in seconds

Definition at line 44 of file servo_cam_ctrl.c.

Function Documentation

◆ dc_send_command()

void dc_send_command ( uint8_t  cmd)

Send Command To Camera.

Definition at line 96 of file servo_cam_ctrl.c.

References DC_ON, DC_PUSH, dc_send_command_common(), dc_send_shot_position(), DC_SHOOT, DC_SHUTTER_DELAY, DC_TALLER, dc_timer, and DC_WIDER.

+ Here is the call graph for this function:

◆ servo_cam_ctrl_init()

void servo_cam_ctrl_init ( void  )

Definition at line 56 of file servo_cam_ctrl.c.

References dc_init(), and dc_timer.

+ Here is the call graph for this function:

◆ servo_cam_ctrl_periodic()

void servo_cam_ctrl_periodic ( void  )

Definition at line 67 of file servo_cam_ctrl.c.

References dc_periodic(), DC_RELEASE, dc_send_shot_position(), and dc_timer.

+ Here is the call graph for this function:

Variable Documentation

◆ dc_timer

uint8_t dc_timer
static

Definition at line 53 of file servo_cam_ctrl.c.

Referenced by dc_send_command(), servo_cam_ctrl_init(), and servo_cam_ctrl_periodic().