set-attitude-target support in Guided mode

724 views
Skip to first unread message

Randy Mackay

unread,
Oct 8, 2015, 9:22:08 AM10/8/15
to drones-...@googlegroups.com

 

     Because of a few people asking for it on the dronekit Gitter channel I’ve created a PR to add support for the set-attitude-target message (http://mavlink.org/messages/common#SET_ATTITUDE_TARGET) in Guided mode.  https://github.com/diydrones/ardupilot/pull/2959.

 

     This is much like AltHold for use by a GCS or companion computer.  So the caller can specify the lean angle using a quaternion and a thrust value.  The thrust value is a number from 0 to 1.0.  0 = descend at WPNAV_SPEED_DN, 0.5=maintain alt and 1.0 = climb at WPNAV_SPEED_UP cm/s.

 

     There’s a corresponding PR for MAVProxy to allow testing the new feature:

           https://github.com/Dronecode/MAVProxy/pull/208

 

     All feedback welcome here or in the PR.

 

     This is a Copter-3.4 feature.

 

-Randy

Kristian Klausen

unread,
Oct 8, 2015, 10:23:21 AM10/8/15
to drones-discuss
Hi,

On a similar note, I have some local changes here wich enables acceleration input. (Using the same conversion from accel -> lean angles as in loiter-mode). Is this a feature more people are interessted in?

Regards,
Kristian

Randy Mackay

unread,
Oct 9, 2015, 2:06:58 AM10/9/15
to drones-...@googlegroups.com

Kristian,

 

     I’ve seen some requests to add support for the acceleration fields in the SET_POSITION_TARGET_* messages so there’s definitely interest but I think those people also expect the control to be “closed loop” and what I mean by that is that the vehicle would lean over to generate the acceleration but it would also integrate that desired acceleration up to the velocity and position and maintain those as well.  In this way the caller could make the vehicle fly a nice circle for example without having to worry about externally checking the vehicle’s position.

-Randy

--
You received this message because you are subscribed to the Google Groups "drones-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to drones-discus...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Robertwz

unread,
Oct 10, 2015, 11:01:16 PM10/10/15
to drones-discuss

Can I in guide mode using optical flow ,you see guide mode can not used at indoor there no gps.
在 2015年10月8日星期四 UTC+8下午9:22:08,Randy Mackay写道:

foobarbecue

unread,
Oct 15, 2015, 12:24:54 AM10/15/15
to drones-discuss
Excellent, this would be really useful! I have an unusual use case but I think set-attitude-target would solve my problem and avoid me having to hack something together myself.

The deal is that I'm flying UV spectrometers to measure SO2 in volcanic plumes. The spectrometer is hard-mounted to the copter. To make the processing math feasible, we need the spectrometer attitude to stay roughly constant during measurements. We're not concerned about position drift during measurements. So being able to command a certain attitude instead of position would do the trick. I'd actually like to be able to do this using pre-programmed missions, so it'd be good if this ended up in a mission command.

Aaron
Reply all
Reply to author
Forward
0 new messages