AP_Math: make the rotation numbers easier to find

This commit is contained in:
Andrew Tridgell 2013-07-08 12:07:36 +10:00
parent a6c7bd3612
commit 8c49ed78a5
1 changed files with 33 additions and 27 deletions

View File

@ -23,34 +23,40 @@
// also in the list. This is an important property. Please run the
// rotations test suite if you add to the list.
// these rotation values are stored to EEPROM, so be careful not to
// NOTE!! these rotation values are stored to EEPROM, so be careful not to
// change the numbering of any existing entry when adding a new entry.
enum Rotation {
ROTATION_NONE = 0,
ROTATION_YAW_45,
ROTATION_YAW_90,
ROTATION_YAW_135,
ROTATION_YAW_180,
ROTATION_YAW_225,
ROTATION_YAW_270,
ROTATION_YAW_315,
ROTATION_ROLL_180,
ROTATION_ROLL_180_YAW_45,
ROTATION_ROLL_180_YAW_90,
ROTATION_ROLL_180_YAW_135,
ROTATION_PITCH_180,
ROTATION_ROLL_180_YAW_225,
ROTATION_ROLL_180_YAW_270,
ROTATION_ROLL_180_YAW_315,
ROTATION_ROLL_90,
ROTATION_ROLL_90_YAW_45,
ROTATION_ROLL_90_YAW_90,
ROTATION_ROLL_90_YAW_135,
ROTATION_ROLL_270,
ROTATION_ROLL_270_YAW_45,
ROTATION_ROLL_270_YAW_90,
ROTATION_ROLL_270_YAW_135,
ROTATION_PITCH_90,
ROTATION_PITCH_270,
ROTATION_NONE = 0,
ROTATION_YAW_45 = 1,
ROTATION_YAW_90 = 2,
ROTATION_YAW_135 = 3,
ROTATION_YAW_180 = 4,
ROTATION_YAW_225 = 5,
ROTATION_YAW_270 = 6,
ROTATION_YAW_315 = 7,
ROTATION_ROLL_180 = 8,
ROTATION_ROLL_180_YAW_45 = 9,
ROTATION_ROLL_180_YAW_90 = 10,
ROTATION_ROLL_180_YAW_135 = 11,
ROTATION_PITCH_180 = 12,
ROTATION_ROLL_180_YAW_225 = 13,
ROTATION_ROLL_180_YAW_270 = 14,
ROTATION_ROLL_180_YAW_315 = 15,
ROTATION_ROLL_90 = 16,
ROTATION_ROLL_90_YAW_45 = 17,
ROTATION_ROLL_90_YAW_90 = 18,
ROTATION_ROLL_90_YAW_135 = 19,
ROTATION_ROLL_270 = 20,
ROTATION_ROLL_270_YAW_45 = 21,
ROTATION_ROLL_270_YAW_90 = 22,
ROTATION_ROLL_270_YAW_135 = 23,
ROTATION_PITCH_90 = 24,
ROTATION_PITCH_270 = 25,
ROTATION_MAX
};
/*
Here are the same values in a form sutable for a @Values attribute in
auto documentation:
@Values: 0:None,1:Yaw45,2:Yaw90,3:Yaw135,4:Yaw180,5:Yaw225,6:Yaw270,7:Yaw315,8:Roll180,9:Roll180Yaw45,10:Roll180Yaw90,11:Roll180Yaw135,12:Pitch180,13:Roll180Yaw225,14:Roll180Yaw270,15:Roll180Yaw315,16:Roll90,17:Roll90Yaw45,18:Roll90Yaw90,19:Roll90Yaw135,20:Roll270,21:Roll270Yaw45,22:Roll270Yaw90,23:Roll270Yaw136,24:Pitch90,25:Pitch270
*/