mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[hal] Remove HAL.h single header include (#8667)
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
// Open Source Software; you can modify and/or share it under the terms of
|
||||
// the WPILib BSD license file in the root directory of this project.
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/util/print.hpp"
|
||||
|
||||
int main() {
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
// Open Source Software; you can modify and/or share it under the terms of
|
||||
// the WPILib BSD license file in the root directory of this project.
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
|
||||
#include <jni.h>
|
||||
|
||||
#include "wpi/hal/HALBase.h"
|
||||
|
||||
#ifdef __FRC_SYSTEMCORE__
|
||||
#include <signal.h>
|
||||
#endif
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
#include "wpi/hal/CAN.h"
|
||||
#include "wpi/hal/DriverStation.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/Value.h"
|
||||
#include "wpi/util/jni_util.hpp"
|
||||
|
||||
using namespace wpi::util::java;
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
#include "OpModeOptionsCallbackStore.hpp"
|
||||
#include "SimDeviceDataJNI.hpp"
|
||||
#include "org_wpilib_hardware_hal_simulation_SimulatorJNI.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/handles/HandlesInternal.hpp"
|
||||
#include "wpi/hal/simulation/MockHooks.h"
|
||||
#include "wpi/util/jni_util.hpp"
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
// Copyright (c) FIRST and other WPILib contributors.
|
||||
// Open Source Software; you can modify and/or share it under the terms of
|
||||
// the WPILib BSD license file in the root directory of this project.
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "wpi/hal/AnalogInput.h"
|
||||
#include "wpi/hal/CAN.h"
|
||||
#include "wpi/hal/CANAPI.h"
|
||||
#include "wpi/hal/CTREPCM.h"
|
||||
#include "wpi/hal/Constants.h"
|
||||
#include "wpi/hal/Counter.h"
|
||||
#include "wpi/hal/DIO.h"
|
||||
#include "wpi/hal/DriverStation.h"
|
||||
#include "wpi/hal/Encoder.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/I2C.h"
|
||||
#include "wpi/hal/Main.h"
|
||||
#include "wpi/hal/Notifier.h"
|
||||
#include "wpi/hal/PWM.h"
|
||||
#include "wpi/hal/Ports.h"
|
||||
#include "wpi/hal/Power.h"
|
||||
#include "wpi/hal/SerialPort.h"
|
||||
#include "wpi/hal/SimDevice.h"
|
||||
#include "wpi/hal/Threads.h"
|
||||
#include "wpi/hal/Types.h"
|
||||
#include "wpi/hal/UsageReporting.h"
|
||||
#include "wpi/hal/Value.h"
|
||||
@@ -2,13 +2,13 @@
|
||||
// Open Source Software; you can modify and/or share it under the terms of
|
||||
// the WPILib BSD license file in the root directory of this project.
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
#include "wpi/hal/HALBase.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#pragma comment(lib, "Winmm.lib")
|
||||
@@ -24,6 +24,7 @@ NtQueryTimerResolution(PULONG MinimumResolution, PULONG MaximumResolution,
|
||||
#include "HALInitializer.hpp"
|
||||
#include "MockHooksInternal.hpp"
|
||||
#include "mockdata/RoboRioDataInternal.hpp"
|
||||
#include "wpi/hal/CAN.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/Extensions.h"
|
||||
#include "wpi/hal/simulation/DriverStationData.h"
|
||||
|
||||
@@ -2,8 +2,6 @@
|
||||
// Open Source Software; you can modify and/or share it under the terms of
|
||||
// the WPILib BSD license file in the root directory of this project.
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
|
||||
#include <dlfcn.h>
|
||||
#include <signal.h> // linux for kill
|
||||
#include <sys/prctl.h>
|
||||
@@ -17,7 +15,9 @@
|
||||
#include "HALInitializer.hpp"
|
||||
#include "HALInternal.hpp"
|
||||
#include "SystemServerInternal.hpp"
|
||||
#include "wpi/hal/CAN.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/util/StringExtras.hpp"
|
||||
#include "wpi/util/mutex.hpp"
|
||||
#include "wpi/util/timestamp.hpp"
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
// Open Source Software; you can modify and/or share it under the terms of
|
||||
// the WPILib BSD license file in the root directory of this project.
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "wpi/hal/HALBase.h"
|
||||
|
||||
namespace wpi::hal {
|
||||
TEST(HALTest, RuntimeType) {
|
||||
EXPECT_EQ(HAL_RuntimeType::HAL_Runtime_Simulation, HAL_GetRuntimeType());
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
|
||||
int main(int argc, char** argv) {
|
||||
HAL_Initialize(500, 0);
|
||||
|
||||
@@ -9,7 +9,8 @@
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "wpi/hal/AnalogInput.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/handles/HandlesInternal.hpp"
|
||||
|
||||
namespace wpi::hal {
|
||||
|
||||
@@ -9,7 +9,8 @@
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "wpi/hal/DIO.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/handles/HandlesInternal.hpp"
|
||||
|
||||
namespace wpi::hal {
|
||||
|
||||
@@ -5,11 +5,10 @@
|
||||
#include "wpi/hal/simulation/DriverStationData.h"
|
||||
|
||||
#include <cstring>
|
||||
#include <string>
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/DriverStation.h"
|
||||
#include "wpi/util/StringExtras.hpp"
|
||||
|
||||
namespace wpi::hal {
|
||||
|
||||
@@ -7,7 +7,8 @@
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "wpi/hal/CTREPCM.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/handles/HandlesInternal.hpp"
|
||||
#include "wpi/hal/simulation/CTREPCMData.h"
|
||||
|
||||
|
||||
@@ -8,7 +8,8 @@
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/Errors.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/PWM.h"
|
||||
#include "wpi/hal/handles/HandlesInternal.hpp"
|
||||
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
#include <string_view>
|
||||
|
||||
#include "wpi/hal/Extensions.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/Ports.h"
|
||||
#include "wpi/hal/simulation/MockHooks.h"
|
||||
#include "wpi/util/raw_ostream.hpp"
|
||||
|
||||
@@ -3,5 +3,5 @@
|
||||
// the WPILib BSD license file in the root directory of this project.
|
||||
|
||||
#include "wpi/cs/cscore_c.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/nt/ntcore.h"
|
||||
|
||||
@@ -15,8 +15,11 @@ that want even more control over what code runs on their robot.
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include "wpi/hal/DIO.h"
|
||||
#include "wpi/hal/DriverStation.h"
|
||||
#include "wpi/hal/DriverStationTypes.h"
|
||||
#include "wpi/hal/HAL.h"
|
||||
#include "wpi/hal/HALBase.h"
|
||||
#include "wpi/hal/PWM.h"
|
||||
|
||||
HAL_RobotMode getDSMode(void) {
|
||||
// Get Robot State
|
||||
|
||||
Reference in New Issue
Block a user