mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-28 02:11:43 +00:00
Take 2 on usage reporting.
The previous commit missed the MindsensorsSD540 value. Remove wpilibc/Athena/include/NetworkCommunication/UsageReporting.h copy; it was not actually used (all references except the one in DriverStation.cpp had been commented out), and has been superseded by the one in HAL.hpp. Change-Id: I51e2eafa85ee5e40050d702aa0bf69171e887a60
This commit is contained in:
@@ -98,6 +98,7 @@ namespace HALUsageReporting
|
||||
kResourceType_ADXL362,
|
||||
kResourceType_ADXRS450,
|
||||
kResourceType_RevSPARK,
|
||||
kResourceType_MindsensorsSD540,
|
||||
kResourceType_DigitalGlitchFilter,
|
||||
};
|
||||
|
||||
|
||||
@@ -77,6 +77,7 @@ namespace nUsageReporting
|
||||
kResourceType_ADXRS450,
|
||||
kResourceType_RevSPARK,
|
||||
kResourceType_MindsensorsSD540,
|
||||
kResourceType_DigitalGlitchFilter,
|
||||
} tResourceType;
|
||||
|
||||
typedef enum
|
||||
|
||||
@@ -1,146 +0,0 @@
|
||||
|
||||
#ifndef __UsageReporting_h__
|
||||
#define __UsageReporting_h__
|
||||
|
||||
#ifdef SIMULATION
|
||||
#include <vxWorks_compat.h>
|
||||
#define EXPORT_FUNC __declspec(dllexport) __cdecl
|
||||
#else
|
||||
#include <stdint.h>
|
||||
#include <stdlib.h>
|
||||
#define EXPORT_FUNC
|
||||
#endif
|
||||
|
||||
#define kUsageReporting_version 1
|
||||
|
||||
namespace nUsageReporting {
|
||||
typedef enum {
|
||||
kResourceType_Controller,
|
||||
kResourceType_Module,
|
||||
kResourceType_Language,
|
||||
kResourceType_CANPlugin,
|
||||
kResourceType_Accelerometer,
|
||||
kResourceType_ADXL345,
|
||||
kResourceType_AnalogChannel,
|
||||
kResourceType_AnalogTrigger,
|
||||
kResourceType_AnalogTriggerOutput,
|
||||
kResourceType_CANJaguar,
|
||||
kResourceType_Compressor,
|
||||
kResourceType_Counter,
|
||||
kResourceType_Dashboard,
|
||||
kResourceType_DigitalInput,
|
||||
kResourceType_DigitalOutput,
|
||||
kResourceType_DriverStationCIO,
|
||||
kResourceType_DriverStationEIO,
|
||||
kResourceType_DriverStationLCD,
|
||||
kResourceType_Encoder,
|
||||
kResourceType_GearTooth,
|
||||
kResourceType_Gyro,
|
||||
kResourceType_I2C,
|
||||
kResourceType_Framework,
|
||||
kResourceType_Jaguar,
|
||||
kResourceType_Joystick,
|
||||
kResourceType_Kinect,
|
||||
kResourceType_KinectStick,
|
||||
kResourceType_PIDController,
|
||||
kResourceType_Preferences,
|
||||
kResourceType_PWM,
|
||||
kResourceType_Relay,
|
||||
kResourceType_RobotDrive,
|
||||
kResourceType_SerialPort,
|
||||
kResourceType_Servo,
|
||||
kResourceType_Solenoid,
|
||||
kResourceType_SPI,
|
||||
kResourceType_Task,
|
||||
kResourceType_Ultrasonic,
|
||||
kResourceType_Victor,
|
||||
kResourceType_Button,
|
||||
kResourceType_Command,
|
||||
kResourceType_AxisCamera,
|
||||
kResourceType_PCVideoServer,
|
||||
kResourceType_SmartDashboard,
|
||||
kResourceType_Talon,
|
||||
kResourceType_HiTechnicColorSensor,
|
||||
kResourceType_HiTechnicAccel,
|
||||
kResourceType_HiTechnicCompass,
|
||||
kResourceType_SRF08,
|
||||
kResourceType_AnalogOutput,
|
||||
kResourceType_VictorSP,
|
||||
kResourceType_TalonSRX,
|
||||
kResourceType_CANTalonSRX,
|
||||
kResourceType_DigitalGlitchFilter,
|
||||
} tResourceType;
|
||||
|
||||
typedef enum {
|
||||
kLanguage_LabVIEW = 1,
|
||||
kLanguage_CPlusPlus = 2,
|
||||
kLanguage_Java = 3,
|
||||
kLanguage_Python = 4,
|
||||
|
||||
kCANPlugin_BlackJagBridge = 1,
|
||||
kCANPlugin_2CAN = 2,
|
||||
|
||||
kFramework_Iterative = 1,
|
||||
kFramework_Simple = 2,
|
||||
|
||||
kRobotDrive_ArcadeStandard = 1,
|
||||
kRobotDrive_ArcadeButtonSpin = 2,
|
||||
kRobotDrive_ArcadeRatioCurve = 3,
|
||||
kRobotDrive_Tank = 4,
|
||||
kRobotDrive_MecanumPolar = 5,
|
||||
kRobotDrive_MecanumCartesian = 6,
|
||||
|
||||
kDriverStationCIO_Analog = 1,
|
||||
kDriverStationCIO_DigitalIn = 2,
|
||||
kDriverStationCIO_DigitalOut = 3,
|
||||
|
||||
kDriverStationEIO_Acceleration = 1,
|
||||
kDriverStationEIO_AnalogIn = 2,
|
||||
kDriverStationEIO_AnalogOut = 3,
|
||||
kDriverStationEIO_Button = 4,
|
||||
kDriverStationEIO_LED = 5,
|
||||
kDriverStationEIO_DigitalIn = 6,
|
||||
kDriverStationEIO_DigitalOut = 7,
|
||||
kDriverStationEIO_FixedDigitalOut = 8,
|
||||
kDriverStationEIO_PWM = 9,
|
||||
kDriverStationEIO_Encoder = 10,
|
||||
kDriverStationEIO_TouchSlider = 11,
|
||||
|
||||
kADXL345_SPI = 1,
|
||||
kADXL345_I2C = 2,
|
||||
|
||||
kCommand_Scheduler = 1,
|
||||
|
||||
kSmartDashboard_Instance = 1,
|
||||
} tInstances;
|
||||
|
||||
/**
|
||||
* Report the usage of a resource of interest.
|
||||
*
|
||||
* @param resource one of the values in the tResourceType above (max value 51).
|
||||
* @param instanceNumber an index that identifies the resource instance.
|
||||
* @param context an optional additional context number for some cases (such as
|
||||
* module number). Set to 0 to omit.
|
||||
* @param feature a string to be included describing features in use on a
|
||||
* specific resource. Setting the same resource more than once allows you to
|
||||
* change the feature string.
|
||||
*/
|
||||
uint32_t EXPORT_FUNC report(tResourceType resource, uint8_t instanceNumber,
|
||||
uint8_t context = 0, const char *feature = nullptr);
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
uint32_t EXPORT_FUNC
|
||||
FRC_NetworkCommunication_nUsageReporting_report(uint8_t resource,
|
||||
uint8_t instanceNumber,
|
||||
uint8_t context,
|
||||
const char *feature);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // __UsageReporting_h__
|
||||
@@ -6,7 +6,6 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
#include "AnalogAccelerometer.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "AnalogGyro.h"
|
||||
#include "AnalogInput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Timer.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
#include "AnalogInput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "Timer.h"
|
||||
#include "WPIErrors.h"
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
#include "AnalogTrigger.h"
|
||||
|
||||
#include "AnalogInput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "HAL/Port.h"
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "AnalogTriggerOutput.h"
|
||||
#include "AnalogTrigger.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
|
||||
/**
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
#include "Timer.h"
|
||||
#define tNIRIO_i32 int
|
||||
#include "NetworkCommunication/CANSessionMux.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
#include <cstdio>
|
||||
#include <cassert>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
#include "Counter.h"
|
||||
#include "AnalogTrigger.h"
|
||||
#include "DigitalInput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "WPIErrors.h"
|
||||
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
#include "DigitalInput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
#include "DigitalOutput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "WPIErrors.h"
|
||||
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
#include "DoubleSolenoid.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
#include "AnalogInput.h"
|
||||
#include "Timer.h"
|
||||
#include "NetworkCommunication/FRCComm.h"
|
||||
#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "MotorSafetyHelper.h"
|
||||
#include "Utility.h"
|
||||
#include "WPIErrors.h"
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "Encoder.h"
|
||||
#include "DigitalInput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
#include "IterativeRobot.h"
|
||||
|
||||
#include "DriverStation.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "HAL/HAL.hpp"
|
||||
#include "SmartDashboard/SmartDashboard.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
#include "Jaguar.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
/**
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "Joystick.h"
|
||||
#include "DriverStation.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
#include <math.h>
|
||||
#include <string.h>
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "PWM.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "Utility.h"
|
||||
#include "WPIErrors.h"
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
|
||||
#include "Preferences.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "HAL/HAL.hpp"
|
||||
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
#include "Relay.h"
|
||||
|
||||
#include "MotorSafetyHelper.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Resource.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
@@ -8,9 +8,6 @@
|
||||
#include "RobotBase.h"
|
||||
|
||||
#include "DriverStation.h"
|
||||
//#include "NetworkCommunication/FRCComm.h"
|
||||
//#include "NetworkCommunication/symModuleLink.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "RobotState.h"
|
||||
#include "HLUsageReporting.h"
|
||||
#include "Internal/HardwareHLReporting.h"
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
#include "GenericHID.h"
|
||||
#include "Joystick.h"
|
||||
#include "Talon.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Utility.h"
|
||||
#include "WPIErrors.h"
|
||||
#include <math.h>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
#include "SampleRobot.h"
|
||||
|
||||
#include "DriverStation.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Timer.h"
|
||||
#include "SmartDashboard/SmartDashboard.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "SerialPort.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "HAL/HAL.hpp"
|
||||
#include <stdarg.h>
|
||||
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "Servo.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
constexpr float Servo::kMaxServoAngle;
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
#include "Solenoid.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "Talon.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
/**
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "TalonSRX.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
/**
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "Task.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "WPIErrors.h"
|
||||
#include <errno.h>
|
||||
#include <string.h>
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
#include "Counter.h"
|
||||
#include "DigitalInput.h"
|
||||
#include "DigitalOutput.h"
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "Timer.h"
|
||||
#include "Utility.h"
|
||||
#include "WPIErrors.h"
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "Victor.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
/**
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#include "VictorSP.h"
|
||||
|
||||
//#include "NetworkCommunication/UsageReporting.h"
|
||||
#include "LiveWindow/LiveWindow.h"
|
||||
|
||||
/**
|
||||
|
||||
@@ -398,7 +398,12 @@ public class FRCNetworkCommunicationsLibrary extends JNIWrapper {
|
||||
* <i>native declaration :
|
||||
* src\main\include\NetworkCommunication\UsageReporting.h:66</i>
|
||||
*/
|
||||
public static final int kResourceType_DigitalGlitchFilter = 56;
|
||||
public static final int kResourceType_MindsensorsSD540 = 56;
|
||||
/**
|
||||
* <i>native declaration :
|
||||
* src\main\include\NetworkCommunication\UsageReporting.h:67</i>
|
||||
*/
|
||||
public static final int kResourceType_DigitalGlitchFilter = 57;
|
||||
};
|
||||
/**
|
||||
* <i>native declaration :
|
||||
|
||||
Reference in New Issue
Block a user