From e9d93264102287776f80e95990b2d4671061745f Mon Sep 17 00:00:00 2001 From: Randy Mackay Date: Tue, 14 Feb 2023 13:04:04 +0900 Subject: [PATCH] Sub: integrate camera frontend/backend split --- ArduSub/Parameters.cpp | 4 ++-- ArduSub/system.cpp | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ArduSub/Parameters.cpp b/ArduSub/Parameters.cpp index 01f6eb4a6e..45b297ae16 100644 --- a/ArduSub/Parameters.cpp +++ b/ArduSub/Parameters.cpp @@ -404,9 +404,9 @@ const AP_Param::Info Sub::var_info[] = { // variables not in the g class which contain EEPROM saved variables #if AP_CAMERA_ENABLED - // @Group: CAM_ + // @Group: CAM // @Path: ../libraries/AP_Camera/AP_Camera.cpp - GOBJECT(camera, "CAM_", AP_Camera), + GOBJECT(camera, "CAM", AP_Camera), #endif // @Group: RELAY_ diff --git a/ArduSub/system.cpp b/ArduSub/system.cpp index 55d571e553..7ac209a87f 100644 --- a/ArduSub/system.cpp +++ b/ArduSub/system.cpp @@ -103,6 +103,11 @@ void Sub::init_ardupilot() camera_mount.set_mode(MAV_MOUNT_MODE_RC_TARGETING); #endif +#if AP_CAMERA_ENABLED + // initialise camera + camera.init(); +#endif + #ifdef USERHOOK_INIT USERHOOK_INIT #endif