2010-07-04 04:21:34 +02:00
|
|
|
/**
|
|
|
|
******************************************************************************
|
|
|
|
*
|
|
|
|
* @file ahrsstatus.h
|
|
|
|
* @author The OpenPilot Team, http://www.openpilot.org Copyright (C) 2010.
|
|
|
|
* @brief Implementation of the AhrsStatus object. This file has been
|
|
|
|
* automatically generated by the UAVObjectGenerator.
|
|
|
|
*
|
|
|
|
* @note Object definition file: ahrsstatus.xml.
|
|
|
|
* This is an automatically generated file.
|
|
|
|
* DO NOT modify manually.
|
|
|
|
*
|
|
|
|
* @see The GNU Public License (GPL) Version 3
|
|
|
|
*
|
|
|
|
*****************************************************************************/
|
|
|
|
/*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful, but
|
|
|
|
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
|
|
|
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
|
|
* for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License along
|
|
|
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
|
|
|
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef AHRSSTATUS_H
|
|
|
|
#define AHRSSTATUS_H
|
|
|
|
|
|
|
|
// Object constants
|
2010-08-21 23:46:02 +02:00
|
|
|
#define AHRSSTATUS_OBJID 1556283776U
|
2010-07-04 04:21:34 +02:00
|
|
|
#define AHRSSTATUS_NAME "AhrsStatus"
|
|
|
|
#define AHRSSTATUS_METANAME "AhrsStatusMeta"
|
|
|
|
#define AHRSSTATUS_ISSINGLEINST 1
|
|
|
|
#define AHRSSTATUS_ISSETTINGS 0
|
|
|
|
#define AHRSSTATUS_NUMBYTES sizeof(AhrsStatusData)
|
|
|
|
|
|
|
|
// Object access macros
|
|
|
|
#define AhrsStatusGet(dataOut) UAVObjGetData(AhrsStatusHandle(), dataOut)
|
|
|
|
#define AhrsStatusSet(dataIn) UAVObjSetData(AhrsStatusHandle(), dataIn)
|
|
|
|
#define AhrsStatusInstGet(instId, dataOut) UAVObjGetInstanceData(AhrsStatusHandle(), instId, dataOut)
|
|
|
|
#define AhrsStatusInstSet(instId, dataIn) UAVObjSetInstanceData(AhrsStatusHandle(), instId, dataIn)
|
|
|
|
#define AhrsStatusConnectQueue(queue) UAVObjConnectQueue(AhrsStatusHandle(), queue, EV_MASK_ALL_UPDATES)
|
|
|
|
#define AhrsStatusConnectCallback(cb) UAVObjConnectCallback(AhrsStatusHandle(), cb, EV_MASK_ALL_UPDATES)
|
|
|
|
#define AhrsStatusCreateInstance() UAVObjCreateInstance(AhrsStatusHandle())
|
|
|
|
#define AhrsStatusRequestUpdate() UAVObjRequestUpdate(AhrsStatusHandle())
|
|
|
|
#define AhrsStatusRequestInstUpdate(instId) UAVObjRequestInstanceUpdate(AhrsStatusHandle(), instId)
|
|
|
|
#define AhrsStatusUpdated() UAVObjUpdated(AhrsStatusHandle())
|
|
|
|
#define AhrsStatusInstUpdated(instId) UAVObjUpdated(AhrsStatusHandle(), instId)
|
|
|
|
#define AhrsStatusGetMetadata(dataOut) UAVObjGetMetadata(AhrsStatusHandle(), dataOut)
|
|
|
|
#define AhrsStatusSetMetadata(dataIn) UAVObjSetMetadata(AhrsStatusHandle(), dataIn)
|
|
|
|
|
|
|
|
// Object data
|
|
|
|
typedef struct {
|
|
|
|
uint8_t SerialNumber[25];
|
2010-08-21 23:46:02 +02:00
|
|
|
uint8_t CommErrors[6];
|
|
|
|
uint8_t HomeSet;
|
|
|
|
uint8_t CalibrationSet;
|
2010-07-04 04:21:34 +02:00
|
|
|
|
|
|
|
} __attribute__((packed)) AhrsStatusData;
|
|
|
|
|
|
|
|
// Field information
|
|
|
|
// Field SerialNumber information
|
|
|
|
/* Number of elements for field SerialNumber */
|
|
|
|
#define AHRSSTATUS_SERIALNUMBER_NUMELEM 25
|
2010-08-21 11:21:39 +02:00
|
|
|
// Field CommErrors information
|
|
|
|
/* Array element names for field CommErrors */
|
2010-08-21 23:46:02 +02:00
|
|
|
typedef enum { AHRSSTATUS_COMMERRORS_ATTITUDE=0, AHRSSTATUS_COMMERRORS_ATTITUDERAW=1, AHRSSTATUS_COMMERRORS_POSITIONACTUAL=2, AHRSSTATUS_COMMERRORS_HOMELOCATION=3, AHRSSTATUS_COMMERRORS_ALTITUDE=4, AHRSSTATUS_COMMERRORS_CALIBRATION=5 } AhrsStatusCommErrorsElem;
|
2010-08-21 11:21:39 +02:00
|
|
|
/* Number of elements for field CommErrors */
|
2010-08-21 23:46:02 +02:00
|
|
|
#define AHRSSTATUS_COMMERRORS_NUMELEM 6
|
|
|
|
// Field HomeSet information
|
|
|
|
/* Enumeration options for field HomeSet */
|
|
|
|
typedef enum { AHRSSTATUS_HOMESET_FALSE=0, AHRSSTATUS_HOMESET_TRUE=1 } AhrsStatusHomeSetOptions;
|
|
|
|
// Field CalibrationSet information
|
|
|
|
/* Enumeration options for field CalibrationSet */
|
|
|
|
typedef enum { AHRSSTATUS_CALIBRATIONSET_FALSE=0, AHRSSTATUS_CALIBRATIONSET_TRUE=1 } AhrsStatusCalibrationSetOptions;
|
2010-07-04 04:21:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
// Generic interface functions
|
|
|
|
int32_t AhrsStatusInitialize();
|
|
|
|
UAVObjHandle AhrsStatusHandle();
|
|
|
|
|
|
|
|
#endif // AHRSSTATUS_H
|