Skip to content

Commit

Permalink
AP_Mount: Use AP_MAVLINK_MSG_VIDEO_STREAM_INFORMATION_ENABLED guard
Browse files Browse the repository at this point in the history
  • Loading branch information
nexton-winjeel committed Jul 25, 2024
1 parent 8403ca8 commit 40a132f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libraries/AP_Mount/AP_Mount.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -905,6 +905,7 @@ void AP_Mount::send_camera_capture_status(uint8_t instance, mavlink_channel_t ch
backend->send_camera_capture_status(chan);
}

#if AP_MAVLINK_MSG_VIDEO_STREAM_INFORMATION_ENABLED
// send a VIDEO_STREAM_INFORMATION message to GCS
bool AP_Mount::send_video_stream_information(uint8_t instance, mavlink_channel_t chan)
{
Expand All @@ -914,6 +915,7 @@ bool AP_Mount::send_video_stream_information(uint8_t instance, mavlink_channel_t
}
return backend->send_video_stream_information(chan);
}
#endif

// get rangefinder distance. Returns true on success
bool AP_Mount::get_rangefinder_distance(uint8_t instance, float& distance_m) const
Expand Down
2 changes: 2 additions & 0 deletions libraries/AP_Mount/AP_Mount.h
Original file line number Diff line number Diff line change
Expand Up @@ -272,9 +272,11 @@ class AP_Mount
// send camera capture status message to GCS
void send_camera_capture_status(uint8_t instance, mavlink_channel_t chan) const;

#if AP_MAVLINK_MSG_VIDEO_STREAM_INFORMATION_ENABLED
// send camera information message to GCS
// returns true if the message was sent
bool send_video_stream_information(uint8_t instance, mavlink_channel_t chan);
#endif

//
// rangefinder
Expand Down

0 comments on commit 40a132f

Please sign in to comment.