diff --git a/flight/modules/CameraControl/cameracontrol.c b/flight/modules/CameraControl/cameracontrol.c new file mode 100644 index 000000000..7b3bde0ba --- /dev/null +++ b/flight/modules/CameraControl/cameracontrol.c @@ -0,0 +1,63 @@ +/** + ****************************************************************************** + * + * @file cameracontrol.c + * @author The LibrePilot Project, http://www.librepilot.org Copyright (C) 2016. + * @brief camera control module. triggers cameras with multiple options + * + * @see The GNU Public License (GPL) Version 3 + * + *****************************************************************************/ +/* + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * Additional note on redistribution: The copyright and license notices above + * must be maintained in each individual source file that is a derivative work + * of this source file; otherwise redistribution is prohibited. + */ + +#include +#include "inc/cameracontrol.h" +#include +#include +#include +#include + +/* +// Private variables +static struct CameraControl_data { + portTickType lastSysTime; +} *ccd; +*/ + +//static void setOutput(); + + +/** + * Initialise the module, called on startup + * \returns 0 on success or -1 if initialisation failed + */ +int32_t CameraControlInitialize(void) +{ + return 0; +} + +/* stub: module has no module thread */ +int32_t CameraControlStart(void) +{ + return 0; +} + +MODULE_INITCALL(CameraControlInitialize, CameraControlStart); diff --git a/flight/modules/CameraControl/inc/cameracontrol.h b/flight/modules/CameraControl/inc/cameracontrol.h new file mode 100644 index 000000000..c3d61f0cc --- /dev/null +++ b/flight/modules/CameraControl/inc/cameracontrol.h @@ -0,0 +1,36 @@ +/** + ****************************************************************************** + * + * @file cameracontrol.h + * @author The LibrePilot Project, http://www.librepilot.org Copyright (C) 2016. + * @brief camera control module. triggers cameras with multiple options + * + * @see The GNU Public License (GPL) Version 3 + * + *****************************************************************************/ +/* + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * Additional note on redistribution: The copyright and license notices above + * must be maintained in each individual source file that is a derivative work + * of this source file; otherwise redistribution is prohibited. + */ + +#ifndef FLIGHT_MODULES_CAMERACONTROL_INC_CAMERACONTROL_H +#define FLIGHT_MODULES_CAMERACONTROL_INC_CAMERACONTROL_H + + + +#endif /* FLIGHT_MODULES_CAMERACONTROL_INC_CAMERACONTROL_H */ diff --git a/flight/targets/boards/revolution/firmware/UAVObjects.inc b/flight/targets/boards/revolution/firmware/UAVObjects.inc index 6100c4750..5774e7ae4 100644 --- a/flight/targets/boards/revolution/firmware/UAVObjects.inc +++ b/flight/targets/boards/revolution/firmware/UAVObjects.inc @@ -112,6 +112,8 @@ UAVOBJSRCFILENAMES += receiveractivity UAVOBJSRCFILENAMES += receiverstatus UAVOBJSRCFILENAMES += cameradesired UAVOBJSRCFILENAMES += camerastabsettings +UAVOBJSRCFILENAMES += cameracontrolsettings +UAVOBJSRCFILENAMES += cameracontrolactivity UAVOBJSRCFILENAMES += altitudeholdsettings UAVOBJSRCFILENAMES += oplinksettings UAVOBJSRCFILENAMES += oplinkstatus diff --git a/ground/gcs/src/plugins/uavobjects/uavobjects.pro b/ground/gcs/src/plugins/uavobjects/uavobjects.pro index 92be03832..942e79742 100644 --- a/ground/gcs/src/plugins/uavobjects/uavobjects.pro +++ b/ground/gcs/src/plugins/uavobjects/uavobjects.pro @@ -59,6 +59,8 @@ UAVOBJS = \ $${UAVOBJ_XML_DIR}/auxmagsettings.xml \ $${UAVOBJ_XML_DIR}/barosensor.xml \ $${UAVOBJ_XML_DIR}/callbackinfo.xml \ + $${UAVOBJ_XML_DIR}/cameracontrolactivity.xml \ + $${UAVOBJ_XML_DIR}/cameracontrolsettings.xml \ $${UAVOBJ_XML_DIR}/cameradesired.xml \ $${UAVOBJ_XML_DIR}/camerastabsettings.xml \ $${UAVOBJ_XML_DIR}/debuglogcontrol.xml \ diff --git a/shared/uavobjectdefinition/cameracontrolactivity.xml b/shared/uavobjectdefinition/cameracontrolactivity.xml new file mode 100644 index 000000000..8dcf89213 --- /dev/null +++ b/shared/uavobjectdefinition/cameracontrolactivity.xml @@ -0,0 +1,24 @@ + + + Contains position and timestamp of each camera operation + + + + + + + + + + + + + + + + + + + + + diff --git a/shared/uavobjectdefinition/cameracontrolsettings.xml b/shared/uavobjectdefinition/cameracontrolsettings.xml new file mode 100644 index 000000000..3e0bb9a73 --- /dev/null +++ b/shared/uavobjectdefinition/cameracontrolsettings.xml @@ -0,0 +1,19 @@ + + + Settings for the @ref CameraControl module + + + + + + + + + + + + + + + +