Skip to content

Commit

Permalink
Camera: allow camera managed by an autopilot
Browse files Browse the repository at this point in the history
By querying autopilot for the CAMERA_INFORMATION message, we allow an
autopilot to be a proxy for a MAVLink or non-MAVLink camera.

The idea is similar to a gimbal manager implemented by an autopilot.
  • Loading branch information
julianoes committed May 30, 2024
1 parent b02c0dd commit f20f05e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Camera/QGCCameraManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@ void
QGCCameraManager::_mavlinkMessageReceived(const mavlink_message_t& message)
{
//-- Only pay attention to camera components, as identified by their compId
if(message.sysid == _vehicle->id() && (message.compid >= MAV_COMP_ID_CAMERA && message.compid <= MAV_COMP_ID_CAMERA6)) {
if(message.sysid == _vehicle->id() && (message.compid == MAV_COMP_ID_AUTOPILOT1 ||
(message.compid >= MAV_COMP_ID_CAMERA && message.compid <= MAV_COMP_ID_CAMERA6))) {
switch (message.msgid) {
case MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS:
_handleCaptureStatus(message);
Expand Down

0 comments on commit f20f05e

Please sign in to comment.