Taking photos with the Anafi AI

How would create a service that takes a picture using the vertical or frontal camera on the drone every 10 seconds or some arbitrary time interval to save to local mission storage? Any guidance would be appreciated. I assume it is a few lines of code but I have been unable to parse the docs.

Hi @kaeladair,

Please, take a look at this example (video photo mission example).

Regards,
Axel

Great, I got it working and removed the video recording features. How would I go about allowing this service to be controlled by another service? Ex. another service that specifies when this service should take a picture.

Hi @kaeladair,

One solution is to create a msghub server and a msghub client and an associated protobuf message to exchange messages between these two services.

Regards,
Axel

Got it. What would be the recommended set up if I am wanting the drone to do the following:

  1. Point front camera straight down
  2. Take a photo
  3. Collect telemetry data of drone

And wanted this to happen every x seconds.

Should I combine them into one service?

Hi @kaeladair,

I think it’s possible to combine them in one service.

Point front camera straight down → it’s possible with libairsdk
Take a photo → it’s possible with libairsdk
Collect telemetry data of drone → it’s possible with telemetry

Regards,
Axel

Important Note: If you send a command with libairsdk during a flight plan/ or if you send a command when you are piloting the drone with a controller, the drone’s behavior will be undefined. It’s best to use just one controller at a time/flightplan.

This topic was automatically closed after 30 days. New replies are no longer allowed.