[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Paparazzi-devel] Configuration of a distance based autoshoot functi

From: Christophe De Wagter
Subject: Re: [Paparazzi-devel] Configuration of a distance based autoshoot function with Yapa2
Date: Tue, 18 Sep 2012 08:43:28 +0200


Most of your comments below are correct, except the camera-pin / indicator. 

I know it is confusing but in paparazzi all digital IO channels are called LED. So in this case DC_SHUTTER_LED does not mean "light emitting diode indicator" but "digital output to the camera". At this point the digital camera trigger does not have an indicator, unless you add a LED+resistor on the same wire as the one that goes to your camera. (I don't think you can run the module twice in parallel but an indicator could be added)

On LPC21 based boards almost every unused pin can be turned into a digital output by defining:

LED_x_PIN = pin_nr_on_schematics
LED_x_BANK = pin_bank_on_schematics

e.g. if you do not use your adc channels, they can become digital outputs to your camera. 

The title of your post suggests you want to do distance based instead of time based triggering. In that case your flightplan should use:

 LINE_START_FUNCTION dc_autoshoot = DC_AUTOSHOOT_DISTANCE; instead of PERIODIC. It can also do angle based, grid based etc triggering. See dc_autoshoot for all options. 


On Mon, Sep 17, 2012 at 11:42 PM, Jorn Anke <address@hidden> wrote:
Hi again,

I want to configure one of the servo-pins on the Yapa to trigger a Canon camera using chdk. From the wiki, I think the S2 is supposed to be used for this. The LED 1 is also unused, so I want to use that as an indicator of the trigger event.

From what I have found in other threads, I think what I have to configure in the airframe file is something like this:

 <section name="DIGITAL_CAMERA" prefix="DC_">
    <define name="AUTOSHOOT_QUARTERSEC_PERIOD" value="8" unit="quarter_second"/>    
    => Meaning "distance" between each shot is 2 seconds ?

    <define name="AUTOSHOOT_METER_GRID" value="40" unit="meter"/>

    <load name="ins_chimu_spi.xml" >
    <!-- <define name="CHIMU_BIG_ENDIAN" /> -->
    <load name="digital_cam.xml">
      <define name="DC_SHUTTER_LED" value="1"/>
      => LED 1 will be used as indicator ?
      <define name="LED_1_PIN" value="2"/>
      => Defining physical pin S2 as camera pin ?

      <define name="PUSH" value="LED_ON" />
      <define name="RELEASE" value="LED_OFF" />
      <define name="DC_SHUTTER_DELAY" value="2" unit="quarter_second"/>
      => Trigger will be active for 0,5 seconds ?


And I the flight plan, maybe this: (?)

#include "subsystems/navigation/nav_line.h"
#include "subsystems/datalink/datalink.h"
#include "generated/airframe.h"
#include "modules/digital_cam/dc.h"
//#define LINE_START_FUNCTION dc_Survey(dc_gps_dist);



Paparazzi-devel mailing list

reply via email to

[Prev in Thread] Current Thread [Next in Thread]