I’m having a problem with the mission command DO_DIGICAM_CONTROL in APM:Copter V3.4.2-rc2. I can trigger the servo by pressing the “trigger camera now” button in mission planner “actions”,but the command DO_DIGICAM_CONTROL in flight plan does not trigger the servo/camera. When I do the Trigger Camera Now in Mission Planner, it uses the command DO_DIGICAM_CONTROL, so I think the issue isn’t in ArduPilot.when I write waypoints into UAV,a strange thing happened:
In mission planner/flight plan, I set param5=1(shutter_cmd) in command DO_DIGICAM_CONTROL,and I write waypoints(with DO_DIGICAM_CONTROL) by pressing the “write wps” button ,
after that,I press the “Read wps” button to confirm the mission,but the value of param5 in command DO_DIGICAM_CONTROL has changed,1.28E-05 as shown in the figure below.And DO_DIGICAM_CONTROL does not work while flying in auto mode.
I think I have find some reason of the problem,by adding code to output the result of some parameters in code source file ,ardupilot-master\libraries\AP_Mission\AP_Mission.cpp. Where the problem occurred is in the function MAV_MISSION_RESULT AP_Mission::mavlink_int_to_mission_cmd(const mavlink_mission_item_int_t& packet, AP_Mission::Mission_Command& cmd)—case MAV_CMD_DO_DIGICAM_CONTROL—cmd.content.digicam_control.shooting_cmd = packet.x.The type of shooting_cmd is uint8_t, the type ofpacket.x is int32_t,and this problem may be due to the different types of data caused.In mission planner/flight plan,when I set param5=1(shutter_cmd) in command DO_DIGICAM_CONTROL,and I write waypoints(with DO_DIGICAM_CONTROL) by pressing the “write wps” button , the value of shooting_cmd should be equal to packet.x ,but the output of my test code shows that the value of it has changed.Tomorrow, I will continue to debug the code to find the real reason.
Thanks for the report. I’ve recreated the issue and confirmed that it’s a new problem in AC3.4 (AC3.3 doesn’t have the problem). I suspect it’s related to us adding support for mission-item-int messages.
Can anyone point me to docs on “Shutter CMDs”? I too am getting “1.7E-05” in the Command ID when trying to use DO_DIGICAM_CONTROL in a copter WP mission.
I’m trying to control when the camera is triggered during a mission.