Updated to NI image v18

Change-Id: If120eee63c7815bfcf2f05fdf48a0399497a645d
This commit is contained in:
Fredric Silberberg
2015-12-11 17:18:41 -05:00
parent 7ba89306ca
commit 82d89d3b70
28 changed files with 184 additions and 158 deletions

View File

@@ -4,6 +4,6 @@
#ifndef __RoboRIO_FRC_ChipObject_Aliases_h__
#define __RoboRIO_FRC_ChipObject_Aliases_h__
#define nRoboRIO_FPGANamespace nFRC_2016_16_0_0
#define nRoboRIO_FPGANamespace nFRC_2016_16_1_0
#endif // __RoboRIO_FRC_ChipObject_Aliases_h__

View File

@@ -1,15 +1,15 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_nInterfaceGlobals_h__
#define __nFRC_2016_16_0_0_nInterfaceGlobals_h__
#ifndef __nFRC_2016_16_1_0_nInterfaceGlobals_h__
#define __nFRC_2016_16_1_0_nInterfaceGlobals_h__
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
extern unsigned int g_currentTargetClass;
}
}
#endif // __nFRC_2016_16_0_0_nInterfaceGlobals_h__
#endif // __nFRC_2016_16_1_0_nInterfaceGlobals_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_AI_h__
#define __nFRC_2016_16_0_0_AI_h__
#ifndef __nFRC_2016_16_1_0_AI_h__
#define __nFRC_2016_16_1_0_AI_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tAI
@@ -140,4 +140,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_AI_h__
#endif // __nFRC_2016_16_1_0_AI_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_AO_h__
#define __nFRC_2016_16_0_0_AO_h__
#ifndef __nFRC_2016_16_1_0_AO_h__
#define __nFRC_2016_16_1_0_AO_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tAO
@@ -47,4 +47,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_AO_h__
#endif // __nFRC_2016_16_1_0_AO_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Accel_h__
#define __nFRC_2016_16_0_0_Accel_h__
#ifndef __nFRC_2016_16_1_0_Accel_h__
#define __nFRC_2016_16_1_0_Accel_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tAccel
@@ -99,4 +99,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Accel_h__
#endif // __nFRC_2016_16_1_0_Accel_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Accumulator_h__
#define __nFRC_2016_16_0_0_Accumulator_h__
#ifndef __nFRC_2016_16_1_0_Accumulator_h__
#define __nFRC_2016_16_1_0_Accumulator_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tAccumulator
@@ -84,4 +84,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Accumulator_h__
#endif // __nFRC_2016_16_1_0_Accumulator_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Alarm_h__
#define __nFRC_2016_16_0_0_Alarm_h__
#ifndef __nFRC_2016_16_1_0_Alarm_h__
#define __nFRC_2016_16_1_0_Alarm_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tAlarm
@@ -54,4 +54,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Alarm_h__
#endif // __nFRC_2016_16_1_0_Alarm_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_AnalogTrigger_h__
#define __nFRC_2016_16_0_0_AnalogTrigger_h__
#ifndef __nFRC_2016_16_1_0_AnalogTrigger_h__
#define __nFRC_2016_16_1_0_AnalogTrigger_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tAnalogTrigger
@@ -126,4 +126,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_AnalogTrigger_h__
#endif // __nFRC_2016_16_1_0_AnalogTrigger_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_BIST_h__
#define __nFRC_2016_16_0_0_BIST_h__
#ifndef __nFRC_2016_16_1_0_BIST_h__
#define __nFRC_2016_16_1_0_BIST_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tBIST
@@ -87,4 +87,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_BIST_h__
#endif // __nFRC_2016_16_1_0_BIST_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Counter_h__
#define __nFRC_2016_16_0_0_Counter_h__
#ifndef __nFRC_2016_16_1_0_Counter_h__
#define __nFRC_2016_16_1_0_Counter_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tCounter
@@ -216,4 +216,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Counter_h__
#endif // __nFRC_2016_16_1_0_Counter_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_DIO_h__
#define __nFRC_2016_16_0_0_DIO_h__
#ifndef __nFRC_2016_16_1_0_DIO_h__
#define __nFRC_2016_16_1_0_DIO_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tDIO
@@ -245,4 +245,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_DIO_h__
#endif // __nFRC_2016_16_1_0_DIO_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_DMA_h__
#define __nFRC_2016_16_0_0_DMA_h__
#ifndef __nFRC_2016_16_1_0_DMA_h__
#define __nFRC_2016_16_1_0_DMA_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tDMA
@@ -46,13 +46,17 @@ public:
unsigned Enable_Counters_High : 1;
unsigned Enable_CounterTimers_Low : 1;
unsigned Enable_CounterTimers_High : 1;
unsigned Enable_Encoders : 1;
unsigned Enable_EncoderTimers : 1;
unsigned Enable_Encoders_Low : 1;
unsigned Enable_Encoders_High : 1;
unsigned Enable_EncoderTimers_Low : 1;
unsigned Enable_EncoderTimers_High : 1;
unsigned ExternalClock : 1;
#else
unsigned ExternalClock : 1;
unsigned Enable_EncoderTimers : 1;
unsigned Enable_Encoders : 1;
unsigned Enable_EncoderTimers_High : 1;
unsigned Enable_EncoderTimers_Low : 1;
unsigned Enable_Encoders_High : 1;
unsigned Enable_Encoders_Low : 1;
unsigned Enable_CounterTimers_High : 1;
unsigned Enable_CounterTimers_Low : 1;
unsigned Enable_Counters_High : 1;
@@ -73,7 +77,7 @@ public:
#endif
};
struct{
unsigned value : 20;
unsigned value : 22;
};
} tConfig;
typedef
@@ -130,8 +134,10 @@ public:
virtual void writeConfig_Enable_Counters_High(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_CounterTimers_Low(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_CounterTimers_High(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_Encoders(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_EncoderTimers(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_Encoders_Low(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_Encoders_High(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_EncoderTimers_Low(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_Enable_EncoderTimers_High(bool value, tRioStatusCode *status) = 0;
virtual void writeConfig_ExternalClock(bool value, tRioStatusCode *status) = 0;
virtual tConfig readConfig(tRioStatusCode *status) = 0;
virtual bool readConfig_Pause(tRioStatusCode *status) = 0;
@@ -151,30 +157,33 @@ public:
virtual bool readConfig_Enable_Counters_High(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_CounterTimers_Low(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_CounterTimers_High(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_Encoders(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_EncoderTimers(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_Encoders_Low(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_Encoders_High(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_EncoderTimers_Low(tRioStatusCode *status) = 0;
virtual bool readConfig_Enable_EncoderTimers_High(tRioStatusCode *status) = 0;
virtual bool readConfig_ExternalClock(tRioStatusCode *status) = 0;
typedef enum
{
kNumExternalTriggersRegisters = 2,
kNumExternalTriggersElements = 4,
} tExternalTriggers_IfaceConstants;
virtual void writeExternalTriggers(unsigned char bitfield_index, tExternalTriggers value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_ExternalClockSource_Channel(unsigned char bitfield_index, unsigned char value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_ExternalClockSource_Module(unsigned char bitfield_index, unsigned char value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_ExternalClockSource_AnalogTrigger(unsigned char bitfield_index, bool value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_RisingEdge(unsigned char bitfield_index, bool value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_FallingEdge(unsigned char bitfield_index, bool value, tRioStatusCode *status) = 0;
virtual tExternalTriggers readExternalTriggers(unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual unsigned char readExternalTriggers_ExternalClockSource_Channel(unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual unsigned char readExternalTriggers_ExternalClockSource_Module(unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual bool readExternalTriggers_ExternalClockSource_AnalogTrigger(unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual bool readExternalTriggers_RisingEdge(unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual bool readExternalTriggers_FallingEdge(unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers(unsigned char reg_index, unsigned char bitfield_index, tExternalTriggers value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_ExternalClockSource_Channel(unsigned char reg_index, unsigned char bitfield_index, unsigned char value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_ExternalClockSource_Module(unsigned char reg_index, unsigned char bitfield_index, unsigned char value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_ExternalClockSource_AnalogTrigger(unsigned char reg_index, unsigned char bitfield_index, bool value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_RisingEdge(unsigned char reg_index, unsigned char bitfield_index, bool value, tRioStatusCode *status) = 0;
virtual void writeExternalTriggers_FallingEdge(unsigned char reg_index, unsigned char bitfield_index, bool value, tRioStatusCode *status) = 0;
virtual tExternalTriggers readExternalTriggers(unsigned char reg_index, unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual unsigned char readExternalTriggers_ExternalClockSource_Channel(unsigned char reg_index, unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual unsigned char readExternalTriggers_ExternalClockSource_Module(unsigned char reg_index, unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual bool readExternalTriggers_ExternalClockSource_AnalogTrigger(unsigned char reg_index, unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual bool readExternalTriggers_RisingEdge(unsigned char reg_index, unsigned char bitfield_index, tRioStatusCode *status) = 0;
virtual bool readExternalTriggers_FallingEdge(unsigned char reg_index, unsigned char bitfield_index, tRioStatusCode *status) = 0;
private:
@@ -185,4 +194,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_DMA_h__
#endif // __nFRC_2016_16_1_0_DMA_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Encoder_h__
#define __nFRC_2016_16_0_0_Encoder_h__
#ifndef __nFRC_2016_16_1_0_Encoder_h__
#define __nFRC_2016_16_1_0_Encoder_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tEncoder
@@ -196,4 +196,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Encoder_h__
#endif // __nFRC_2016_16_1_0_Encoder_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Global_h__
#define __nFRC_2016_16_0_0_Global_h__
#ifndef __nFRC_2016_16_1_0_Global_h__
#define __nFRC_2016_16_1_0_Global_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tGlobal
@@ -101,4 +101,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Global_h__
#endif // __nFRC_2016_16_1_0_Global_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Interrupt_h__
#define __nFRC_2016_16_0_0_Interrupt_h__
#ifndef __nFRC_2016_16_1_0_Interrupt_h__
#define __nFRC_2016_16_1_0_Interrupt_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tInterrupt
@@ -97,4 +97,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Interrupt_h__
#endif // __nFRC_2016_16_1_0_Interrupt_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_PWM_h__
#define __nFRC_2016_16_0_0_PWM_h__
#ifndef __nFRC_2016_16_1_0_PWM_h__
#define __nFRC_2016_16_1_0_PWM_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tPWM
@@ -117,4 +117,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_PWM_h__
#endif // __nFRC_2016_16_1_0_PWM_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Power_h__
#define __nFRC_2016_16_0_0_Power_h__
#ifndef __nFRC_2016_16_1_0_Power_h__
#define __nFRC_2016_16_1_0_Power_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tPower
@@ -46,19 +46,21 @@ public:
union{
struct{
#ifdef __vxworks
unsigned OverCurrentFaultCount3V3 : 10;
unsigned OverCurrentFaultCount5V : 10;
unsigned OverCurrentFaultCount6V : 10;
unsigned OverCurrentFaultCount3V3 : 8;
unsigned OverCurrentFaultCount5V : 8;
unsigned OverCurrentFaultCount6V : 8;
unsigned UnderVoltageFaultCount5V : 8;
#else
unsigned OverCurrentFaultCount6V : 10;
unsigned OverCurrentFaultCount5V : 10;
unsigned OverCurrentFaultCount3V3 : 10;
unsigned UnderVoltageFaultCount5V : 8;
unsigned OverCurrentFaultCount6V : 8;
unsigned OverCurrentFaultCount5V : 8;
unsigned OverCurrentFaultCount3V3 : 8;
#endif
};
struct{
unsigned value : 30;
unsigned value : 32;
};
} tOverCurrentFaultCounts;
} tFaultCounts;
typedef
union{
struct{
@@ -124,16 +126,6 @@ public:
virtual void strobeResetFaultCounts(tRioStatusCode *status) = 0;
typedef enum
{
} tOverCurrentFaultCounts_IfaceConstants;
virtual tOverCurrentFaultCounts readOverCurrentFaultCounts(tRioStatusCode *status) = 0;
virtual unsigned short readOverCurrentFaultCounts_OverCurrentFaultCount3V3(tRioStatusCode *status) = 0;
virtual unsigned short readOverCurrentFaultCounts_OverCurrentFaultCount5V(tRioStatusCode *status) = 0;
virtual unsigned short readOverCurrentFaultCounts_OverCurrentFaultCount6V(tRioStatusCode *status) = 0;
typedef enum
{
} tIntegratedIO_IfaceConstants;
@@ -183,6 +175,17 @@ public:
virtual unsigned short readAOVoltage(tRioStatusCode *status) = 0;
typedef enum
{
} tFaultCounts_IfaceConstants;
virtual tFaultCounts readFaultCounts(tRioStatusCode *status) = 0;
virtual unsigned char readFaultCounts_OverCurrentFaultCount3V3(tRioStatusCode *status) = 0;
virtual unsigned char readFaultCounts_OverCurrentFaultCount5V(tRioStatusCode *status) = 0;
virtual unsigned char readFaultCounts_OverCurrentFaultCount6V(tRioStatusCode *status) = 0;
virtual unsigned char readFaultCounts_UnderVoltageFaultCount5V(tRioStatusCode *status) = 0;
typedef enum
{
} tVinCurrent_IfaceConstants;
@@ -214,4 +217,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Power_h__
#endif // __nFRC_2016_16_1_0_Power_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_Relay_h__
#define __nFRC_2016_16_0_0_Relay_h__
#ifndef __nFRC_2016_16_1_0_Relay_h__
#define __nFRC_2016_16_1_0_Relay_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tRelay
@@ -65,4 +65,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_Relay_h__
#endif // __nFRC_2016_16_1_0_Relay_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_SPI_h__
#define __nFRC_2016_16_0_0_SPI_h__
#ifndef __nFRC_2016_16_1_0_SPI_h__
#define __nFRC_2016_16_1_0_SPI_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tSPI
@@ -65,4 +65,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_SPI_h__
#endif // __nFRC_2016_16_1_0_SPI_h__

View File

@@ -1,14 +1,14 @@
// Copyright (c) National Instruments 2008. All Rights Reserved.
// Do Not Edit... this file is generated!
#ifndef __nFRC_2016_16_0_0_SysWatchdog_h__
#define __nFRC_2016_16_0_0_SysWatchdog_h__
#ifndef __nFRC_2016_16_1_0_SysWatchdog_h__
#define __nFRC_2016_16_1_0_SysWatchdog_h__
#include "tSystemInterface.h"
namespace nFPGA
{
namespace nFRC_2016_16_0_0
namespace nFRC_2016_16_1_0
{
class tSysWatchdog
@@ -105,4 +105,4 @@ private:
}
}
#endif // __nFRC_2016_16_0_0_SysWatchdog_h__
#endif // __nFRC_2016_16_1_0_SysWatchdog_h__

View File

@@ -73,7 +73,10 @@ namespace nUsageReporting
kResourceType_VictorSP,
kResourceType_TalonSRX,
kResourceType_CANTalonSRX,
kResourceType_DigitalGlitchFilter,
kResourceType_ADXL362,
kResourceType_ADXRS450,
kResourceType_RevSPARK,
kResourceType_MindsensorsSD540,
} tResourceType;
typedef enum
@@ -88,6 +91,7 @@ namespace nUsageReporting
kFramework_Iterative = 1,
kFramework_Simple = 2,
kFramework_CommandControl = 3,
kRobotDrive_ArcadeStandard = 1,
kRobotDrive_ArcadeButtonSpin = 2,

View File

@@ -54,7 +54,7 @@ bool getUserActive6V(int32_t *status) {
*/
int getUserCurrentFaults6V(int32_t *status) {
initializePower(status);
return (int)power->readOverCurrentFaultCounts_OverCurrentFaultCount6V(status);
return (int)power->readFaultCounts_OverCurrentFaultCount6V(status);
}
/**
@@ -86,7 +86,7 @@ bool getUserActive5V(int32_t *status) {
*/
int getUserCurrentFaults5V(int32_t *status) {
initializePower(status);
return (int)power->readOverCurrentFaultCounts_OverCurrentFaultCount5V(status);
return (int)power->readFaultCounts_OverCurrentFaultCount5V(status);
}
unsigned char getUserStatus5V(int32_t *status) {
@@ -123,5 +123,5 @@ bool getUserActive3V3(int32_t *status) {
*/
int getUserCurrentFaults3V3(int32_t *status) {
initializePower(status);
return (int)power->readOverCurrentFaultCounts_OverCurrentFaultCount3V3(status);
return (int)power->readFaultCounts_OverCurrentFaultCount3V3(status);
}

View File

@@ -3,23 +3,26 @@
#define MAX_STRING_LEN 64
#define SUPPORT_UNIQUE_ID (1) /* depends entirely on old vs new build */
#define USE_NTH_ORDER (0) /* zero to user deviceId */
#define SUPPORT_MOTOR_CONTROLLER_PROFILE (1)
namespace CANDeviceInterface1
{
struct PIDSlot
{
// Proportional gain
float pGain;
// Integral gain
float iGain;
// Differential gain
float dGain;
// Feed-forward gain
float fGain;
// Integral zone
float iZone;
// Closed-loop ramp rate
float clRampRate;
// Proportional gain
float pGain;
// Integral gain
float iGain;
// Differential gain
float dGain;
// Feed-forward gain
float fGain;
// Integral zone
float iZone;
// Closed-loop ramp rate
float clRampRate;
};
struct DeviceDescriptor
@@ -27,9 +30,11 @@ struct DeviceDescriptor
// The full device ID, including the device number, manufacturer, and device type.
// The mask of a message the device supports is 0x1FFF003F.
unsigned int deviceID;
#if SUPPORT_UNIQUE_ID != 0
// This is the ID that uniquely identifies the device node in the UI.
// The purpose of this is to be able to track the device across renames or deviceID changes.
unsigned int uniqueID;
#endif
// An dynamically assigned ID that will make setting deviceIDs robust,
// Never again will you need to isolate a CAN node just to fix it's ID.
unsigned int dynamicID;
@@ -54,23 +59,28 @@ struct DeviceDescriptor
char softwareStatus[MAX_STRING_LEN];
// Is the LED currently on?
bool led;
// Reserved fields for use by CTRE. Not touched by frccansae
// Reserved fields for future use by CTRE. Not touched by frccansae
unsigned int dynFlags;
unsigned int flags; /* bitfield */
unsigned int ptrToString;
// Motor controller properties (ignored if SupportsMotorControllerProperties is false or unset for this model)
unsigned int brakeMode; // 0=Coast, 1=Brake
unsigned int limitSwitchFwdMode; // 0=disabled, 1=Normally Closed, 2=Normally Open
unsigned int limitSwitchRevMode; // 0=disabled, 1=Normally Closed, 2=Normally Open
// Limit-switch soft limits
bool bFwdSoftLimitEnable;
bool bRevSoftLimitEnable;
float softLimitFwd;
float softLimitRev;
// PID constants for slot 0
struct PIDSlot slot0;
// PID constants for slot 1
struct PIDSlot slot1;
//unsigned int reserved0;
//unsigned int reserved1;
//unsigned int reserved2;
#if SUPPORT_MOTOR_CONTROLLER_PROFILE != 0
// Motor controller properties (ignored if SupportsMotorControllerProperties is false or unset for this model)
unsigned int brakeMode; // 0=Coast, 1=Brake
unsigned int limitSwitchFwdMode; // 0=disabled, 1=Normally Closed, 2=Normally Open
unsigned int limitSwitchRevMode; // 0=disabled, 1=Normally Closed, 2=Normally Open
// Limit-switch soft limits
bool bFwdSoftLimitEnable;
bool bRevSoftLimitEnable;
float softLimitFwd;
float softLimitRev;
// PID constants for slot 0
struct PIDSlot slot0;
// PID constants for slot 1
struct PIDSlot slot1;
#endif
};
#define kLimitSwitchMode_Disabled (0)
@@ -88,7 +98,7 @@ int getNumberOfDevices();
// populated before returning. The numDescriptors input describes how many
// elements were allocated to prevent memory corruption. The number of devices
// populated should be returned from this function as well.
int getListOfDevices(struct DeviceDescriptor *devices, int numDescriptors);
int getListOfDevices(DeviceDescriptor *devices, int numDescriptors);
// When the user requests to update the firmware of a device a thread will be
// spawned and this function is called from that thread. This function should
@@ -97,13 +107,13 @@ int getListOfDevices(struct DeviceDescriptor *devices, int numDescriptors);
// error message string can be filled with a NULL-terminated message to show the
// user if there was a problem updating firmware. The error message is only
// displayed if a non-zero value is returned from this function.
int updateFirmware(const struct DeviceDescriptor *device, const unsigned char *imageContents, unsigned int imageSize, char *errorMessage, int errorMessageMaxSize);
int updateFirmware(const DeviceDescriptor *device, const unsigned char *imageContents, unsigned int imageSize, char *errorMessage, int errorMessageMaxSize);
// This function is called periodically from the UI thread while the firmware
// update is in progress. The percentComplete parameter should the filled in
// with the current progress of the firmware update process to update a progress
// bar in the UI.
void checkUpdateProgress(const struct DeviceDescriptor *device, int *percentComplete);
void checkUpdateProgress(const DeviceDescriptor *device, int *percentComplete);
// This is called when the user selects a new ID to assign on the bus and
// chooses to save. The newDeviceID is really just the device number. The
@@ -114,13 +124,13 @@ int assignBroadcastDeviceID(unsigned int newDeviceID);
// also change in the descriptor and will be updated in the UI immediately.
// Be sure to modify the descriptor first since the refresh from the UI is
// asynchronous.
int assignDeviceID(struct DeviceDescriptor *device, unsigned int newDeviceID);
int assignDeviceID(DeviceDescriptor *device, unsigned int newDeviceID);
// This entry-point will get called when the user chooses to change the value
// of the device's LED. This will allow the user to identify devices which
// support dynamic addresses or are otherwise unknown. If this function returns
// a non-zero value, the UI will report an error.
int saveLightLed(const struct DeviceDescriptor *device, bool newLEDStatus);
int saveLightLed(const DeviceDescriptor *device, bool newLEDStatus);
// This entry-point will get called when the user chooses to change the alias
// of the device with the device specified. If this function returns a non-
@@ -128,18 +138,18 @@ int saveLightLed(const struct DeviceDescriptor *device, bool newLEDStatus);
// updated with the new name that was selected. If a different name is saved
// to the descriptor than the user specified, this will require a manual
// refresh by the user. This is reported as CAR #505139
int saveDeviceName(struct DeviceDescriptor *device, const char *newName);
int saveDeviceName(DeviceDescriptor *device, const char *newName);
// This entry-point will get called when the user changes any of the motor
// controller specific properties. If this function returns a non-zero value,
// the UI will report an error. The device descriptor may be updated with
// coerced values.
int saveMotorParameters(struct DeviceDescriptor *device);
int saveMotorParameters(DeviceDescriptor *device);
// Run some sort of self-test functionality on the device. This can be anything
// and the results will be displayed to the user. A non-zero return value
// indicates an error.
int selfTest(const struct DeviceDescriptor *device, char *detailedResults, int detailedResultsMaxSize);
int selfTest(const DeviceDescriptor *device, char *detailedResults, int detailedResultsMaxSize);
} /* CANDeviceInterface */

View File

@@ -57,7 +57,7 @@ RobotBase::RobotBase() : m_ds(DriverStation::GetInstance()) {
file = fopen("/tmp/frc_versions/FRC_Lib_Version.ini", "w");
if (file != nullptr) {
fputs("2016 C++ Beta2.0", file);
fputs("2016 C++ Beta5.0", file);
fclose(file);
}
}

View File

@@ -222,7 +222,7 @@ public abstract class RobotBase {
output = new FileOutputStream(file);
output.write("2016 Java Beta2.0".getBytes());
output.write("2016 Java Beta5.0".getBytes());
} catch (IOException ex) {
ex.printStackTrace();