Skip to content

Commit 2ad1e53

Browse files
committed
Update usage reporting
1 parent 6cd9be6 commit 2ad1e53

File tree

3 files changed

+14
-7
lines changed

3 files changed

+14
-7
lines changed

subprojects/robotpy-hal/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ scan_headers_ignore = [
4646
"hal/IMU.h",
4747
"hal/IMUTypes.h",
4848
"hal/SystemServer.h",
49-
"hal/UsageReporting.h",
5049
"hal/Types.h",
5150
"hal/Value.h",
5251

@@ -120,6 +119,7 @@ PowerDistribution = "hal/PowerDistribution.h"
120119
REVPH = "hal/REVPH.h"
121120
SerialPort = "hal/SerialPort.h"
122121
SimDevice = "hal/SimDevice.h"
122+
UsageReporting = "hal/UsageReporting.h"
123123
Threads = "hal/Threads.h"
124124
# Types = "hal/Types.h"
125125
# Value = "hal/Value.h"
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
3+
strip_prefixes:
4+
- HAL_
5+
6+
functions:
7+
HAL_ReportUsage:
8+
overloads:
9+
const struct WPI_String*, const struct WPI_String*:
10+
ignore: true
11+
std::string_view, std::string_view:
12+
std::string_view, int, std::string_view:

subprojects/robotpy-wpilib/wpilib/_impl/start.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -167,12 +167,7 @@ def start(self, robot_cls: wpilib.RobotBase) -> bool:
167167
return False
168168

169169
def _start(self, robot_cls: wpilib.RobotBase) -> bool:
170-
hal.report(
171-
hal.tResourceType.kResourceType_Language,
172-
hal.tInstances.kLanguage_Python,
173-
0,
174-
wpilib.__version__,
175-
)
170+
hal.reportUsage("Language", "Python")
176171

177172
if not wpilib.Notifier.setHALThreadPriority(True, 40):
178173
reportErrorInternal(

0 commit comments

Comments
 (0)