1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2025-01-17 02:52:12 +01:00

Update android objects

This commit is contained in:
James Cotton 2012-10-05 08:48:12 -05:00
parent dae9cbc76d
commit 4284701b35
5 changed files with 72 additions and 17 deletions

View File

@ -104,6 +104,66 @@ public class FirmwareIAPObj extends UAVDataObject {
DescriptionElemNames.add("37");
DescriptionElemNames.add("38");
DescriptionElemNames.add("39");
DescriptionElemNames.add("40");
DescriptionElemNames.add("41");
DescriptionElemNames.add("42");
DescriptionElemNames.add("43");
DescriptionElemNames.add("44");
DescriptionElemNames.add("45");
DescriptionElemNames.add("46");
DescriptionElemNames.add("47");
DescriptionElemNames.add("48");
DescriptionElemNames.add("49");
DescriptionElemNames.add("50");
DescriptionElemNames.add("51");
DescriptionElemNames.add("52");
DescriptionElemNames.add("53");
DescriptionElemNames.add("54");
DescriptionElemNames.add("55");
DescriptionElemNames.add("56");
DescriptionElemNames.add("57");
DescriptionElemNames.add("58");
DescriptionElemNames.add("59");
DescriptionElemNames.add("60");
DescriptionElemNames.add("61");
DescriptionElemNames.add("62");
DescriptionElemNames.add("63");
DescriptionElemNames.add("64");
DescriptionElemNames.add("65");
DescriptionElemNames.add("66");
DescriptionElemNames.add("67");
DescriptionElemNames.add("68");
DescriptionElemNames.add("69");
DescriptionElemNames.add("70");
DescriptionElemNames.add("71");
DescriptionElemNames.add("72");
DescriptionElemNames.add("73");
DescriptionElemNames.add("74");
DescriptionElemNames.add("75");
DescriptionElemNames.add("76");
DescriptionElemNames.add("77");
DescriptionElemNames.add("78");
DescriptionElemNames.add("79");
DescriptionElemNames.add("80");
DescriptionElemNames.add("81");
DescriptionElemNames.add("82");
DescriptionElemNames.add("83");
DescriptionElemNames.add("84");
DescriptionElemNames.add("85");
DescriptionElemNames.add("86");
DescriptionElemNames.add("87");
DescriptionElemNames.add("88");
DescriptionElemNames.add("89");
DescriptionElemNames.add("90");
DescriptionElemNames.add("91");
DescriptionElemNames.add("92");
DescriptionElemNames.add("93");
DescriptionElemNames.add("94");
DescriptionElemNames.add("95");
DescriptionElemNames.add("96");
DescriptionElemNames.add("97");
DescriptionElemNames.add("98");
DescriptionElemNames.add("99");
fields.add( new UAVObjectField("Description", "", UAVObjectField.FieldType.UINT8, DescriptionElemNames, null) );
List<String> CPUSerialElemNames = new ArrayList<String>();
@ -201,7 +261,7 @@ public class FirmwareIAPObj extends UAVDataObject {
}
// Constants
protected static final long OBJID = 0x3CCDFB68l;
protected static final long OBJID = 0x5E6E8FDCl;
protected static final String NAME = "FirmwareIAPObj";
protected static String DESCRIPTION = "Queries board for SN, model, revision, and sends reset command";
protected static final boolean ISSINGLEINST = 1 > 0;

View File

@ -252,7 +252,7 @@ public class PipXSettings extends UAVDataObject {
getField("VCPConfig").setValue("Disabled");
getField("VCPSpeed").setValue("57600");
getField("RFSpeed").setValue("115200");
getField("MaxRFPower").setValue("100");
getField("MaxRFPower").setValue("1.25");
getField("MinPacketSize").setValue(50);
getField("FrequencyCalibration").setValue(127);
getField("AESKey").setValue(0,0);

View File

@ -67,10 +67,6 @@ public class PipXStatus extends UAVDataObject {
DeviceIDElemNames.add("0");
fields.add( new UAVObjectField("DeviceID", "", UAVObjectField.FieldType.UINT32, DeviceIDElemNames, null) );
List<String> AFCElemNames = new ArrayList<String>();
AFCElemNames.add("0");
fields.add( new UAVObjectField("AFC", "", UAVObjectField.FieldType.INT32, AFCElemNames, null) );
List<String> PairIDsElemNames = new ArrayList<String>();
PairIDsElemNames.add("0");
PairIDsElemNames.add("1");
@ -86,10 +82,6 @@ public class PipXStatus extends UAVDataObject {
RetriesElemNames.add("0");
fields.add( new UAVObjectField("Retries", "", UAVObjectField.FieldType.UINT16, RetriesElemNames, null) );
List<String> ErrorsElemNames = new ArrayList<String>();
ErrorsElemNames.add("0");
fields.add( new UAVObjectField("Errors", "", UAVObjectField.FieldType.UINT16, ErrorsElemNames, null) );
List<String> UAVTalkErrorsElemNames = new ArrayList<String>();
UAVTalkErrorsElemNames.add("0");
fields.add( new UAVObjectField("UAVTalkErrors", "", UAVObjectField.FieldType.UINT16, UAVTalkErrorsElemNames, null) );
@ -180,6 +172,10 @@ public class PipXStatus extends UAVDataObject {
RSSIElemNames.add("0");
fields.add( new UAVObjectField("RSSI", "dBm", UAVObjectField.FieldType.INT8, RSSIElemNames, null) );
List<String> LinkQualityElemNames = new ArrayList<String>();
LinkQualityElemNames.add("0");
fields.add( new UAVObjectField("LinkQuality", "", UAVObjectField.FieldType.UINT8, LinkQualityElemNames, null) );
List<String> LinkStateElemNames = new ArrayList<String>();
LinkStateElemNames.add("0");
List<String> LinkStateEnumOptions = new ArrayList<String>();
@ -243,13 +239,11 @@ public class PipXStatus extends UAVDataObject {
getField("MaxFrequency").setValue(0);
getField("FrequencyStepSize").setValue(0);
getField("DeviceID").setValue(0);
getField("AFC").setValue(0);
getField("PairIDs").setValue(0,0);
getField("PairIDs").setValue(0,1);
getField("PairIDs").setValue(0,2);
getField("PairIDs").setValue(0,3);
getField("Retries").setValue(0);
getField("Errors").setValue(0);
getField("UAVTalkErrors").setValue(0);
getField("Dropped").setValue(0);
getField("Resets").setValue(0);
@ -257,6 +251,7 @@ public class PipXStatus extends UAVDataObject {
getField("RXRate").setValue(0);
getField("FrequencyBand").setValue(0);
getField("RSSI").setValue(0);
getField("LinkQuality").setValue(0);
getField("LinkState").setValue("Disconnected");
getField("PairSignalStrengths").setValue(-127,0);
getField("PairSignalStrengths").setValue(-127,1);
@ -290,7 +285,7 @@ public class PipXStatus extends UAVDataObject {
}
// Constants
protected static final long OBJID = 0x3FC68A86l;
protected static final long OBJID = 0x85D29F8Al;
protected static final String NAME = "PipXStatus";
protected static String DESCRIPTION = "PipXtreme device status.";
protected static final boolean ISSINGLEINST = 1 > 0;

View File

@ -88,7 +88,7 @@ public class RelayTuning extends UAVDataObject {
UAVObject.Metadata metadata = new UAVObject.Metadata();
metadata.flags =
UAVObject.Metadata.AccessModeNum(UAVObject.AccessMode.ACCESS_READWRITE) << UAVOBJ_ACCESS_SHIFT |
UAVObject.Metadata.AccessModeNum(UAVObject.AccessMode.ACCESS_READWRITE) << UAVOBJ_GCS_ACCESS_SHIFT |
UAVObject.Metadata.AccessModeNum(UAVObject.AccessMode.ACCESS_READONLY) << UAVOBJ_GCS_ACCESS_SHIFT |
0 << UAVOBJ_TELEMETRY_ACKED_SHIFT |
0 << UAVOBJ_GCS_TELEMETRY_ACKED_SHIFT |
UAVObject.Metadata.UpdateModeNum(UAVObject.UpdateMode.UPDATEMODE_PERIODIC) << UAVOBJ_TELEMETRY_UPDATE_MODE_SHIFT |

View File

@ -74,8 +74,8 @@ public class TaskInfo extends UAVDataObject {
StackRemainingElemNames.add("ModemRx");
StackRemainingElemNames.add("ModemTx");
StackRemainingElemNames.add("ModemStat");
StackRemainingElemNames.add("EventDispatcher");
StackRemainingElemNames.add("Autotune");
StackRemainingElemNames.add("EventDispatcher");
fields.add( new UAVObjectField("StackRemaining", "bytes", UAVObjectField.FieldType.UINT16, StackRemainingElemNames, null) );
List<String> RunningElemNames = new ArrayList<String>();
@ -101,8 +101,8 @@ public class TaskInfo extends UAVDataObject {
RunningElemNames.add("ModemRx");
RunningElemNames.add("ModemTx");
RunningElemNames.add("ModemStat");
RunningElemNames.add("EventDispatcher");
RunningElemNames.add("Autotune");
RunningElemNames.add("EventDispatcher");
List<String> RunningEnumOptions = new ArrayList<String>();
RunningEnumOptions.add("False");
RunningEnumOptions.add("True");
@ -131,8 +131,8 @@ public class TaskInfo extends UAVDataObject {
RunningTimeElemNames.add("ModemRx");
RunningTimeElemNames.add("ModemTx");
RunningTimeElemNames.add("ModemStat");
RunningTimeElemNames.add("EventDispatcher");
RunningTimeElemNames.add("Autotune");
RunningTimeElemNames.add("EventDispatcher");
fields.add( new UAVObjectField("RunningTime", "%", UAVObjectField.FieldType.UINT8, RunningTimeElemNames, null) );