Commit Graph
32 Commits
Author SHA1 Message Date
Andrew Tridgell 6434442671 AP_Camera: relay MAVLink cameras and resolve camera selectors
Cache bounded stream lists and resume replies independently on each
GCS link after transmit backpressure. Expire remote capture status
after three seconds, retain locally scheduled interval capture, and
back off unanswered status requests.

Preserve native camera identity in cached replies and isolated-link
broadcasts, and suppress synthetic FC-owned status for native cameras.
Restore configured mount associations in cached information only when
a same-system camera advertises none.

Add CAMn_COMPID (0 or 7-255) so camera-v2 discovery can use a
non-default component ID. The first slot owns a colliding ID; duplicate
or invalid IDs warn and disable discovery.

Resolve command selectors as component IDs or legacy slots 1-6 with the
same rules for live commands and missions. NaN in formerly reserved
selector fields means unset. Video commands with a nonzero camera
selector treat param1 as a stream ID and pass the status frequency
through; without one they keep the old camera-slot interpretation.

Fill camera_device_id in camera information, settings, capture status,
field of view and stream messages, and document the routing and
selector design.
2026-09-23 08:59:12 +10:00
Peter Barker 5becbdd49f AP_Camera: report interval capture when capturing until stopped
CAMERA_CAPTURE_STATUS.image_status was calculated from num_remaining
being positive, but take_multiple_pictures sets num_remaining to -1 when
asked to capture until stopped, so a camera capturing on an interval
forever reported itself idle.  Test num_remaining the same way update()
does when deciding whether to take the next image.
2026-07-31 09:16:30 +10:00
Peter Barker b2a8989171 AP_Camera: log angles in degrees rather than cd, check angle limit using deg 2025-11-04 14:30:22 +11:00
Peter Barker 3133623cd5 AP_Camera: avoid using cd when sending camera feedback message 2025-06-07 11:15:01 +10:00
Peter Barker e455d3fa8b AP_Camera: rename AHRS get_roll etc accessors to include _rad 2025-06-05 17:28:41 +10:00
Peter Barker 81d33e7127 AP_Camera: use get_roll_deg in place of roll_sensor (etc.) 2025-06-03 09:48:53 +10:00
Peter Barker 7b10206b6e AP_Camera: use get_roll_deg in place of roll_sensor (etc.) 2025-06-03 09:48:53 +10:00
Randy Mackay dd37065bb5 AP_Camera: camera-status-fov attitude in earth frame 2024-12-10 19:57:06 +09:00
Randy Mackay a9f561ac78 AP_Camera: always send camera-fov-status 2024-12-10 19:57:06 +09:00
Randy Mackay 6f6613fefd AP_Camera: set-stream-information loses send-text 2024-12-05 16:46:48 +09:00
Nick Exton cb620126b3 AP_Camera: Add capability to set VIDEO_STREAM_INFORMATION from Lua 2024-10-01 08:18:54 +09:00
Nick Exton 30a212b4cf AP_Camera: Add capability to set CAMERA_INFORMATION from Lua 2024-10-01 08:18:54 +09:00
Peter Barker 08b4cc1374 AP_Camera: add and use global NaNf float value 2024-09-26 19:26:59 +10:00
Peter Barker b86380bbc6 AP_Camera: create and use an option_is_enabled 2024-08-20 14:50:23 +10:00
Bob Long 078a86ad96 AP_Camera: fix altitude units in CAMERA_FOV_STATUS 2024-08-07 17:08:49 +10:00
Peter Barker bc80358e9b AP_Camera: rely on AHRS for position, not GPS
our location may not be coming from a GPS
2024-08-06 12:11:30 +10:00
Randy Mackay a16d71ced4 AP_Camera: fix video recording while armed 2024-02-15 12:17:44 +11:00
Peter Barker 4b30963d1d AP_Camera: allow compilation with HAL_LOGGING_ENABLED false 2024-01-17 18:25:55 +11:00
Nick Exton 477534b446 AP_Camera: Add handler for CAMERA_CAPTURE_STATUS request 2023-11-09 13:00:57 +09:00
Randy Mackay 73589a276e AP_Camera: camera_fov_status includes field-of-view 2023-11-02 21:23:12 +09:00
Asif Khan 2235a8e063 AP_Camera: add send_camera_fov_status support 2023-11-02 15:54:37 +11:00
Peter Barker 0e2261832e autotest: more test for emitted digicam command-long messages 2023-11-02 15:54:13 +11:00
Peter Barker 685bdd3d3d AP_Camera: handle camera messages as COMMAND_INT as well as COMMAND_LONG 2023-11-02 15:54:13 +11:00
Asif KhanandZachary Zalass f30af5e072 AP_Camera: add MAV_CMD_IMAGE_STOP_CAPTURE support
Co-authored-by: Zachary Zalass <zachzalass@gmail.com>
2023-09-21 21:05:01 +10:00
Peter Barker ad105614bc AP_Camera: allow more libraries to compile with no HAL_GCS_ENABLED 2023-09-05 22:23:51 +10:00
davidsastresas 9bca2740b2 AP_Camera: backend sends gimbal_device_id in camera_information 2023-08-10 14:37:30 +09:00
Asif Khan 47977b1635 AP_Camera: add parameter CAMx_MNT_INST for associating camera with corresponding mount 2023-08-09 10:03:34 +09:00
Asif Khan 2141f06967 AP_Camera: add time based triggering support 2023-08-05 18:52:57 +10:00
Asif Khan 82b709083c AP_Camera: add CAMx_OPTION support for start/stop recording when arm/Disarm 2023-07-05 09:07:53 +10:00
Randy Mackay 63b4b8b7d3 AP_Camera: support camera info and settings 2023-06-16 14:30:46 +10:00
Randy Mackay de4b1890f5 AP_Camera: add semaphore to allow multi-threaded access 2023-04-13 07:04:46 +10:00
Randy Mackay 50bcf1f278 AP_Camera: frontend-backend split
logging gets instance and shorten Pitch field name to Pit
2023-03-01 18:18:51 +11:00