[wpilib] Add usage reporting for dashboards as instances (#7294)

Detects dashboards based on network tables client identity.
This commit is contained in:
sciencewhiz
2024-11-18 09:16:29 -08:00
committed by GitHub
parent 8ec22b7d5c
commit 57e10755fd
7 changed files with 175 additions and 0 deletions

View File

@@ -10,6 +10,7 @@
#include <hal/DriverStation.h>
#include <hal/HALBase.h>
#include <hal/Main.h>
#include <networktables/NetworkTable.h>
#include <wpi/RuntimeCheck.h>
#include <wpi/condition_variable.h>
#include <wpi/mutex.h>
@@ -274,6 +275,8 @@ class RobotBase {
RobotBase& operator=(RobotBase&&) = default;
static std::thread::id m_threadId;
NT_Listener connListenerHandle;
bool m_dashboardDetected = false;
};
} // namespace frc