diff --git a/hal/src/main/native/athena/AddressableLED.cpp b/hal/src/main/native/athena/AddressableLED.cpp index 64b64570b0..7334c995ab 100644 --- a/hal/src/main/native/athena/AddressableLED.cpp +++ b/hal/src/main/native/athena/AddressableLED.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2019-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -15,6 +15,7 @@ #include "DigitalInternal.h" #include "HALInitializer.h" #include "PortsInternal.h" +#include "hal/AddressableLEDTypes.h" #include "hal/ChipObject.h" #include "hal/handles/HandlesInternal.h" #include "hal/handles/LimitedHandleResource.h" diff --git a/hal/src/main/native/athena/CANAPI.cpp b/hal/src/main/native/athena/CANAPI.cpp index 44cdb58aa9..d460885e91 100644 --- a/hal/src/main/native/athena/CANAPI.cpp +++ b/hal/src/main/native/athena/CANAPI.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2018-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2018-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,7 +7,6 @@ #include "hal/CANAPI.h" -#include #include #include @@ -15,7 +14,6 @@ #include "HALInitializer.h" #include "hal/CAN.h" #include "hal/Errors.h" -#include "hal/HAL.h" #include "hal/handles/UnlimitedHandleResource.h" using namespace hal; diff --git a/hal/src/main/native/athena/HALInitializer.cpp b/hal/src/main/native/athena/HALInitializer.cpp index a0456d4b7c..5c2242bced 100644 --- a/hal/src/main/native/athena/HALInitializer.cpp +++ b/hal/src/main/native/athena/HALInitializer.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2018-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,7 +7,7 @@ #include "HALInitializer.h" -#include "hal/HAL.h" +#include "hal/HALBase.h" namespace hal { namespace init { diff --git a/hal/src/main/native/athena/PCMInternal.cpp b/hal/src/main/native/athena/PCMInternal.cpp index dee64cf986..c81dc1ab70 100644 --- a/hal/src/main/native/athena/PCMInternal.cpp +++ b/hal/src/main/native/athena/PCMInternal.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -8,7 +8,6 @@ #include "PCMInternal.h" #include "HALInitializer.h" -#include "PortsInternal.h" #include "hal/Errors.h" #include "hal/Solenoid.h" diff --git a/hal/src/main/native/athena/PCMInternal.h b/hal/src/main/native/athena/PCMInternal.h index 52f0f75784..a9d076c7d6 100644 --- a/hal/src/main/native/athena/PCMInternal.h +++ b/hal/src/main/native/athena/PCMInternal.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -14,7 +14,6 @@ #include "PortsInternal.h" #include "ctre/PCM.h" #include "hal/Errors.h" -#include "hal/Ports.h" #include "hal/Solenoid.h" namespace hal { diff --git a/hal/src/main/native/athena/PDP.cpp b/hal/src/main/native/athena/PDP.cpp index bf0cedf2b1..f60e881551 100644 --- a/hal/src/main/native/athena/PDP.cpp +++ b/hal/src/main/native/athena/PDP.cpp @@ -7,16 +7,12 @@ #include "hal/PDP.h" -#include - #include #include "HALInitializer.h" #include "PortsInternal.h" #include "hal/CANAPI.h" #include "hal/Errors.h" -#include "hal/Ports.h" -#include "hal/handles/IndexedHandleResource.h" using namespace hal; diff --git a/hal/src/main/native/athena/Solenoid.cpp b/hal/src/main/native/athena/Solenoid.cpp index c53db11ca7..ab563b3e90 100644 --- a/hal/src/main/native/athena/Solenoid.cpp +++ b/hal/src/main/native/athena/Solenoid.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,15 +7,11 @@ #include "hal/Solenoid.h" -#include - #include "HALInitializer.h" #include "PCMInternal.h" #include "PortsInternal.h" #include "ctre/PCM.h" -#include "hal/ChipObject.h" #include "hal/Errors.h" -#include "hal/Ports.h" #include "hal/handles/HandlesInternal.h" #include "hal/handles/IndexedHandleResource.h" diff --git a/hal/src/main/native/athena/ctre/CtreCanNode.h b/hal/src/main/native/athena/ctre/CtreCanNode.h index f00060d4f3..ce2d6ac3c8 100644 --- a/hal/src/main/native/athena/ctre/CtreCanNode.h +++ b/hal/src/main/native/athena/ctre/CtreCanNode.h @@ -2,8 +2,6 @@ #define CtreCanNode_H_ #include "ctre.h" //BIT Defines + Typedefs #include -#include // memcpy -#include #include class CtreCanNode { diff --git a/hal/src/main/native/athena/ctre/PCM.cpp b/hal/src/main/native/athena/ctre/PCM.cpp index e05d4d4de2..4fd633f6b1 100644 --- a/hal/src/main/native/athena/ctre/PCM.cpp +++ b/hal/src/main/native/athena/ctre/PCM.cpp @@ -2,7 +2,6 @@ #include "PCM.h" #include "FRC_NetworkCommunication/CANSessionMux.h" -#include // memset /* This can be a constant, as long as nobody needs to update solenoids within 1/50 of a second. */ static const INT32 kCANPeriod = 20; diff --git a/hal/src/main/native/cpp/cpp/fpga_clock.cpp b/hal/src/main/native/cpp/cpp/fpga_clock.cpp index bcec155b3d..ae65ee77d1 100644 --- a/hal/src/main/native/cpp/cpp/fpga_clock.cpp +++ b/hal/src/main/native/cpp/cpp/fpga_clock.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,9 +7,11 @@ #include "hal/cpp/fpga_clock.h" +#include + #include -#include "hal/HAL.h" +#include "hal/HALBase.h" namespace hal { const fpga_clock::time_point fpga_clock::min_time = diff --git a/hal/src/main/native/include/hal/CAN.h b/hal/src/main/native/include/hal/CAN.h index 8cc9c177b8..4f91bc12ee 100644 --- a/hal/src/main/native/include/hal/CAN.h +++ b/hal/src/main/native/include/hal/CAN.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -9,8 +9,6 @@ #include -#include "hal/Types.h" - /** * @defgroup hal_canstream CAN Stream Functions * @ingroup hal_capi diff --git a/hal/src/main/native/include/hal/I2C.h b/hal/src/main/native/include/hal/I2C.h index fc8b5c8f63..4147cbb563 100644 --- a/hal/src/main/native/include/hal/I2C.h +++ b/hal/src/main/native/include/hal/I2C.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -10,7 +10,6 @@ #include #include "hal/I2CTypes.h" -#include "hal/Types.h" /** * @defgroup hal_i2c I2C Functions diff --git a/hal/src/main/native/include/hal/Main.h b/hal/src/main/native/include/hal/Main.h index 866e274d42..097f819d65 100644 --- a/hal/src/main/native/include/hal/Main.h +++ b/hal/src/main/native/include/hal/Main.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2019-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,8 +7,6 @@ #pragma once -#include - #include "hal/Types.h" /** diff --git a/hal/src/main/native/include/hal/cpp/fpga_clock.h b/hal/src/main/native/include/hal/cpp/fpga_clock.h index 94031b15e2..f6d5c6c1b0 100644 --- a/hal/src/main/native/include/hal/cpp/fpga_clock.h +++ b/hal/src/main/native/include/hal/cpp/fpga_clock.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -8,7 +8,6 @@ #pragma once #include -#include /** WPILib Hardware Abstraction Layer (HAL) namespace */ namespace hal { diff --git a/hal/src/main/native/include/hal/simulation/SimDeviceData.h b/hal/src/main/native/include/hal/simulation/SimDeviceData.h index bbdd33270a..e702c5c81b 100644 --- a/hal/src/main/native/include/hal/simulation/SimDeviceData.h +++ b/hal/src/main/native/include/hal/simulation/SimDeviceData.h @@ -9,7 +9,6 @@ #include "hal/Types.h" #include "hal/Value.h" -#include "hal/simulation/NotifyListener.h" typedef void (*HALSIM_SimDeviceCallback)(const char* name, void* param, HAL_SimDeviceHandle handle); diff --git a/hal/src/main/native/sim/AnalogGyro.cpp b/hal/src/main/native/sim/AnalogGyro.cpp index b7d84d9b5f..9666f4a9e3 100644 --- a/hal/src/main/native/sim/AnalogGyro.cpp +++ b/hal/src/main/native/sim/AnalogGyro.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,13 +7,10 @@ #include "hal/AnalogGyro.h" -#include -#include - -#include "AnalogInternal.h" #include "HALInitializer.h" +#include "PortsInternal.h" #include "hal/AnalogAccumulator.h" -#include "hal/AnalogInput.h" +#include "hal/Errors.h" #include "hal/handles/IndexedHandleResource.h" #include "mockdata/AnalogGyroDataInternal.h" diff --git a/hal/src/main/native/sim/AnalogInternal.cpp b/hal/src/main/native/sim/AnalogInternal.cpp index 1e6a755f3e..820dc977cc 100644 --- a/hal/src/main/native/sim/AnalogInternal.cpp +++ b/hal/src/main/native/sim/AnalogInternal.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -8,7 +8,7 @@ #include "AnalogInternal.h" #include "PortsInternal.h" -#include "hal/AnalogInput.h" +#include "hal/handles/IndexedHandleResource.h" namespace hal { IndexedHandleResource -#include - #include "PortsInternal.h" -#include "hal/Ports.h" +#include "hal/handles/HandlesInternal.h" #include "hal/handles/IndexedHandleResource.h" namespace hal { diff --git a/hal/src/main/native/sim/CANAPI.cpp b/hal/src/main/native/sim/CANAPI.cpp index 08b0989668..c410deab3d 100644 --- a/hal/src/main/native/sim/CANAPI.cpp +++ b/hal/src/main/native/sim/CANAPI.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2018-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2018-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,16 +7,13 @@ #include "hal/CANAPI.h" -#include -#include - #include #include "CANAPIInternal.h" #include "HALInitializer.h" #include "hal/CAN.h" #include "hal/Errors.h" -#include "hal/HAL.h" +#include "hal/HALBase.h" #include "hal/handles/UnlimitedHandleResource.h" using namespace hal; diff --git a/hal/src/main/native/sim/Counter.cpp b/hal/src/main/native/sim/Counter.cpp index 37454d0e9a..f0ea1c46ea 100644 --- a/hal/src/main/native/sim/Counter.cpp +++ b/hal/src/main/native/sim/Counter.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -10,7 +10,6 @@ #include "CounterInternal.h" #include "HALInitializer.h" #include "PortsInternal.h" -#include "hal/Errors.h" #include "hal/handles/HandlesInternal.h" #include "hal/handles/LimitedHandleResource.h" diff --git a/hal/src/main/native/sim/DIO.cpp b/hal/src/main/native/sim/DIO.cpp index 21581361a0..f6347d9062 100644 --- a/hal/src/main/native/sim/DIO.cpp +++ b/hal/src/main/native/sim/DIO.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,8 +7,6 @@ #include "hal/DIO.h" -#include - #include "DigitalInternal.h" #include "HALInitializer.h" #include "PortsInternal.h" diff --git a/hal/src/main/native/sim/DigitalInternal.cpp b/hal/src/main/native/sim/DigitalInternal.cpp index 070754a2c8..db6455ad47 100644 --- a/hal/src/main/native/sim/DigitalInternal.cpp +++ b/hal/src/main/native/sim/DigitalInternal.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,11 +7,11 @@ #include "DigitalInternal.h" -#include "ConstantsInternal.h" #include "PortsInternal.h" #include "hal/AnalogTrigger.h" -#include "hal/HAL.h" -#include "hal/Ports.h" +#include "hal/Errors.h" +#include "hal/handles/DigitalHandleResource.h" +#include "hal/handles/HandlesInternal.h" namespace hal { diff --git a/hal/src/main/native/sim/DigitalInternal.h b/hal/src/main/native/sim/DigitalInternal.h index 9df4c515af..d169c8ac63 100644 --- a/hal/src/main/native/sim/DigitalInternal.h +++ b/hal/src/main/native/sim/DigitalInternal.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -9,14 +9,9 @@ #include -#include - #include "PortsInternal.h" #include "hal/AnalogTrigger.h" -#include "hal/Ports.h" -#include "hal/Types.h" #include "hal/handles/DigitalHandleResource.h" -#include "hal/handles/HandlesInternal.h" namespace hal { /** diff --git a/hal/src/main/native/sim/Encoder.cpp b/hal/src/main/native/sim/Encoder.cpp index 36122bf614..32416f0d7a 100644 --- a/hal/src/main/native/sim/Encoder.cpp +++ b/hal/src/main/native/sim/Encoder.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -10,7 +10,6 @@ #include "CounterInternal.h" #include "HALInitializer.h" #include "PortsInternal.h" -#include "hal/Counter.h" #include "hal/Errors.h" #include "hal/handles/HandlesInternal.h" #include "hal/handles/LimitedHandleResource.h" diff --git a/hal/src/main/native/sim/Extensions.cpp b/hal/src/main/native/sim/Extensions.cpp index 6675a51756..e638d6a676 100644 --- a/hal/src/main/native/sim/Extensions.cpp +++ b/hal/src/main/native/sim/Extensions.cpp @@ -12,12 +12,9 @@ #include #include #include -#include #include #include -#include "hal/HAL.h" - #if defined(WIN32) || defined(_WIN32) #include #else diff --git a/hal/src/main/native/sim/HALInitializer.cpp b/hal/src/main/native/sim/HALInitializer.cpp index a0456d4b7c..5c2242bced 100644 --- a/hal/src/main/native/sim/HALInitializer.cpp +++ b/hal/src/main/native/sim/HALInitializer.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2018-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,7 +7,7 @@ #include "HALInitializer.h" -#include "hal/HAL.h" +#include "hal/HALBase.h" namespace hal { namespace init { diff --git a/hal/src/main/native/sim/Notifier.cpp b/hal/src/main/native/sim/Notifier.cpp index e14af0c837..8138468b7c 100644 --- a/hal/src/main/native/sim/Notifier.cpp +++ b/hal/src/main/native/sim/Notifier.cpp @@ -16,11 +16,11 @@ #include #include #include -#include #include "HALInitializer.h" #include "NotifierInternal.h" -#include "hal/HAL.h" +#include "hal/Errors.h" +#include "hal/HALBase.h" #include "hal/cpp/fpga_clock.h" #include "hal/handles/UnlimitedHandleResource.h" #include "hal/simulation/NotifierData.h" diff --git a/hal/src/main/native/sim/PDP.cpp b/hal/src/main/native/sim/PDP.cpp index dbe09d4b2d..cc095d02e2 100644 --- a/hal/src/main/native/sim/PDP.cpp +++ b/hal/src/main/native/sim/PDP.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -11,7 +11,7 @@ #include "HALInitializer.h" #include "PortsInternal.h" #include "hal/CANAPI.h" -#include "hal/handles/IndexedHandleResource.h" +#include "hal/Errors.h" #include "mockdata/PDPDataInternal.h" using namespace hal; diff --git a/hal/src/main/native/sim/Solenoid.cpp b/hal/src/main/native/sim/Solenoid.cpp index 46bd28547d..1881a3235a 100644 --- a/hal/src/main/native/sim/Solenoid.cpp +++ b/hal/src/main/native/sim/Solenoid.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -12,7 +12,7 @@ #include "hal/Errors.h" #include "hal/handles/HandlesInternal.h" #include "hal/handles/IndexedHandleResource.h" -#include "mockdata/PCMDataInternal.h" +#include "hal/simulation/PCMData.h" namespace { struct Solenoid { diff --git a/hal/src/main/native/sim/mockdata/DriverStationData.cpp b/hal/src/main/native/sim/mockdata/DriverStationData.cpp index 6250e02887..dae1dd4776 100644 --- a/hal/src/main/native/sim/mockdata/DriverStationData.cpp +++ b/hal/src/main/native/sim/mockdata/DriverStationData.cpp @@ -5,9 +5,7 @@ /* the project. */ /*----------------------------------------------------------------------------*/ -#include #include -#include #include "DriverStationDataInternal.h" #include "hal/DriverStation.h" diff --git a/hal/src/main/native/sim/mockdata/I2CData.cpp b/hal/src/main/native/sim/mockdata/I2CData.cpp index b228c3b3ef..713064e540 100644 --- a/hal/src/main/native/sim/mockdata/I2CData.cpp +++ b/hal/src/main/native/sim/mockdata/I2CData.cpp @@ -1,12 +1,10 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ /*----------------------------------------------------------------------------*/ -#include - #include "../PortsInternal.h" #include "I2CDataInternal.h" diff --git a/hal/src/main/native/sim/mockdata/SPIData.cpp b/hal/src/main/native/sim/mockdata/SPIData.cpp index 3afc606d41..106ab7f092 100644 --- a/hal/src/main/native/sim/mockdata/SPIData.cpp +++ b/hal/src/main/native/sim/mockdata/SPIData.cpp @@ -1,12 +1,10 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ /*----------------------------------------------------------------------------*/ -#include - #include "../PortsInternal.h" #include "SPIDataInternal.h" diff --git a/wpilibc/src/main/native/cpp/AnalogAccelerometer.cpp b/wpilibc/src/main/native/cpp/AnalogAccelerometer.cpp index eed6a60bba..09bc2f5108 100644 --- a/wpilibc/src/main/native/cpp/AnalogAccelerometer.cpp +++ b/wpilibc/src/main/native/cpp/AnalogAccelerometer.cpp @@ -9,6 +9,7 @@ #include +#include "frc/Base.h" #include "frc/WPIErrors.h" #include "frc/smartdashboard/SendableBuilder.h" #include "frc/smartdashboard/SendableRegistry.h" diff --git a/wpilibc/src/main/native/cpp/AnalogEncoder.cpp b/wpilibc/src/main/native/cpp/AnalogEncoder.cpp index 4e70cc21eb..c1f4e8d6cb 100644 --- a/wpilibc/src/main/native/cpp/AnalogEncoder.cpp +++ b/wpilibc/src/main/native/cpp/AnalogEncoder.cpp @@ -8,6 +8,7 @@ #include "frc/AnalogEncoder.h" #include "frc/AnalogInput.h" +#include "frc/Base.h" #include "frc/Counter.h" #include "frc/DriverStation.h" #include "frc/smartdashboard/SendableBuilder.h" diff --git a/wpilibc/src/main/native/cpp/AnalogGyro.cpp b/wpilibc/src/main/native/cpp/AnalogGyro.cpp index 877cb62be1..2ec443972c 100644 --- a/wpilibc/src/main/native/cpp/AnalogGyro.cpp +++ b/wpilibc/src/main/native/cpp/AnalogGyro.cpp @@ -15,6 +15,7 @@ #include #include "frc/AnalogInput.h" +#include "frc/Base.h" #include "frc/Timer.h" #include "frc/WPIErrors.h" #include "frc/smartdashboard/SendableRegistry.h" diff --git a/wpilibc/src/main/native/cpp/AnalogInput.cpp b/wpilibc/src/main/native/cpp/AnalogInput.cpp index 758865b47a..11c30ee4ab 100644 --- a/wpilibc/src/main/native/cpp/AnalogInput.cpp +++ b/wpilibc/src/main/native/cpp/AnalogInput.cpp @@ -7,8 +7,6 @@ #include "frc/AnalogInput.h" -#include - #include #include #include diff --git a/wpilibc/src/main/native/cpp/AnalogPotentiometer.cpp b/wpilibc/src/main/native/cpp/AnalogPotentiometer.cpp index 8503f040f2..4fc33ade89 100644 --- a/wpilibc/src/main/native/cpp/AnalogPotentiometer.cpp +++ b/wpilibc/src/main/native/cpp/AnalogPotentiometer.cpp @@ -7,6 +7,7 @@ #include "frc/AnalogPotentiometer.h" +#include "frc/Base.h" #include "frc/RobotController.h" #include "frc/smartdashboard/SendableBuilder.h" #include "frc/smartdashboard/SendableRegistry.h" diff --git a/wpilibc/src/main/native/cpp/AnalogTrigger.cpp b/wpilibc/src/main/native/cpp/AnalogTrigger.cpp index ddbb7c8920..45821bae7a 100644 --- a/wpilibc/src/main/native/cpp/AnalogTrigger.cpp +++ b/wpilibc/src/main/native/cpp/AnalogTrigger.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -12,6 +12,7 @@ #include #include "frc/AnalogInput.h" +#include "frc/Base.h" #include "frc/DutyCycle.h" #include "frc/WPIErrors.h" #include "frc/smartdashboard/SendableRegistry.h" diff --git a/wpilibc/src/main/native/cpp/Counter.cpp b/wpilibc/src/main/native/cpp/Counter.cpp index 6f61c1e689..ca74ab8089 100644 --- a/wpilibc/src/main/native/cpp/Counter.cpp +++ b/wpilibc/src/main/native/cpp/Counter.cpp @@ -13,6 +13,7 @@ #include #include "frc/AnalogTrigger.h" +#include "frc/Base.h" #include "frc/DigitalInput.h" #include "frc/WPIErrors.h" #include "frc/smartdashboard/SendableBuilder.h" diff --git a/wpilibc/src/main/native/cpp/DigitalInput.cpp b/wpilibc/src/main/native/cpp/DigitalInput.cpp index 23a00fff27..d82f5705ab 100644 --- a/wpilibc/src/main/native/cpp/DigitalInput.cpp +++ b/wpilibc/src/main/native/cpp/DigitalInput.cpp @@ -8,7 +8,6 @@ #include "frc/DigitalInput.h" #include -#include #include #include diff --git a/wpilibc/src/main/native/cpp/DigitalOutput.cpp b/wpilibc/src/main/native/cpp/DigitalOutput.cpp index f1dacfce53..0bdc57c40a 100644 --- a/wpilibc/src/main/native/cpp/DigitalOutput.cpp +++ b/wpilibc/src/main/native/cpp/DigitalOutput.cpp @@ -8,7 +8,6 @@ #include "frc/DigitalOutput.h" #include -#include #include #include diff --git a/wpilibc/src/main/native/cpp/DriverStation.cpp b/wpilibc/src/main/native/cpp/DriverStation.cpp index 4543ad33b0..758eef7688 100644 --- a/wpilibc/src/main/native/cpp/DriverStation.cpp +++ b/wpilibc/src/main/native/cpp/DriverStation.cpp @@ -10,7 +10,6 @@ #include #include -#include #include #include #include @@ -19,10 +18,8 @@ #include #include -#include "frc/AnalogInput.h" #include "frc/MotorSafety.h" #include "frc/Timer.h" -#include "frc/Utility.h" #include "frc/WPIErrors.h" namespace frc { diff --git a/wpilibc/src/main/native/cpp/DutyCycle.cpp b/wpilibc/src/main/native/cpp/DutyCycle.cpp index 3812c2a637..7e4e98d339 100644 --- a/wpilibc/src/main/native/cpp/DutyCycle.cpp +++ b/wpilibc/src/main/native/cpp/DutyCycle.cpp @@ -10,6 +10,7 @@ #include #include +#include "frc/Base.h" #include "frc/DigitalSource.h" #include "frc/WPIErrors.h" #include "frc/smartdashboard/SendableBuilder.h" diff --git a/wpilibc/src/main/native/cpp/DutyCycleEncoder.cpp b/wpilibc/src/main/native/cpp/DutyCycleEncoder.cpp index 8b431b47c6..03224ab282 100644 --- a/wpilibc/src/main/native/cpp/DutyCycleEncoder.cpp +++ b/wpilibc/src/main/native/cpp/DutyCycleEncoder.cpp @@ -7,6 +7,7 @@ #include "frc/DutyCycleEncoder.h" +#include "frc/Base.h" #include "frc/Counter.h" #include "frc/DigitalInput.h" #include "frc/DigitalSource.h" diff --git a/wpilibc/src/main/native/cpp/Encoder.cpp b/wpilibc/src/main/native/cpp/Encoder.cpp index 440cf8b45d..87bb45ff0e 100644 --- a/wpilibc/src/main/native/cpp/Encoder.cpp +++ b/wpilibc/src/main/native/cpp/Encoder.cpp @@ -12,6 +12,7 @@ #include #include +#include "frc/Base.h" #include "frc/DigitalInput.h" #include "frc/WPIErrors.h" #include "frc/smartdashboard/SendableBuilder.h" diff --git a/wpilibc/src/main/native/cpp/Error.cpp b/wpilibc/src/main/native/cpp/Error.cpp index ee7dcbd110..5e072c9a44 100644 --- a/wpilibc/src/main/native/cpp/Error.cpp +++ b/wpilibc/src/main/native/cpp/Error.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -10,9 +10,9 @@ #include #include +#include "frc/Base.h" #include "frc/DriverStation.h" #include "frc/Timer.h" -#include "frc/Utility.h" using namespace frc; diff --git a/wpilibc/src/main/native/cpp/ErrorBase.cpp b/wpilibc/src/main/native/cpp/ErrorBase.cpp index d098c07a6c..8c7c5a2554 100644 --- a/wpilibc/src/main/native/cpp/ErrorBase.cpp +++ b/wpilibc/src/main/native/cpp/ErrorBase.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -8,17 +8,17 @@ #include "frc/ErrorBase.h" #include -#include #include #include +#include -#include #include #include #include +#include #include -#include "frc/WPIErrors.h" +#include "frc/Base.h" using namespace frc; diff --git a/wpilibc/src/main/native/cpp/GenericHID.cpp b/wpilibc/src/main/native/cpp/GenericHID.cpp index a7dcfc0588..8b28849a20 100644 --- a/wpilibc/src/main/native/cpp/GenericHID.cpp +++ b/wpilibc/src/main/native/cpp/GenericHID.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2016-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2016-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -8,7 +8,6 @@ #include "frc/GenericHID.h" #include -#include #include "frc/DriverStation.h" #include "frc/WPIErrors.h" diff --git a/wpilibc/src/main/native/cpp/InterruptableSensorBase.cpp b/wpilibc/src/main/native/cpp/InterruptableSensorBase.cpp index 202c61d215..744e349144 100644 --- a/wpilibc/src/main/native/cpp/InterruptableSensorBase.cpp +++ b/wpilibc/src/main/native/cpp/InterruptableSensorBase.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,8 +7,6 @@ #include "frc/InterruptableSensorBase.h" -#include - #include "frc/Utility.h" #include "frc/WPIErrors.h" diff --git a/wpilibc/src/main/native/cpp/IterativeRobotBase.cpp b/wpilibc/src/main/native/cpp/IterativeRobotBase.cpp index c51bb2cec2..98c4b3e541 100644 --- a/wpilibc/src/main/native/cpp/IterativeRobotBase.cpp +++ b/wpilibc/src/main/native/cpp/IterativeRobotBase.cpp @@ -7,16 +7,12 @@ #include "frc/IterativeRobotBase.h" -#include - #include -#include #include #include #include #include "frc/DriverStation.h" -#include "frc/Timer.h" #include "frc/livewindow/LiveWindow.h" #include "frc/shuffleboard/Shuffleboard.h" #include "frc/smartdashboard/SmartDashboard.h" diff --git a/wpilibc/src/main/native/cpp/Joystick.cpp b/wpilibc/src/main/native/cpp/Joystick.cpp index 8d464cf9d2..c2cdaea8e2 100644 --- a/wpilibc/src/main/native/cpp/Joystick.cpp +++ b/wpilibc/src/main/native/cpp/Joystick.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -12,9 +12,6 @@ #include #include -#include "frc/DriverStation.h" -#include "frc/WPIErrors.h" - using namespace frc; Joystick::Joystick(int port) : GenericHID(port) { diff --git a/wpilibc/src/main/native/cpp/RobotController.cpp b/wpilibc/src/main/native/cpp/RobotController.cpp index b1d7608a62..b33479fa18 100644 --- a/wpilibc/src/main/native/cpp/RobotController.cpp +++ b/wpilibc/src/main/native/cpp/RobotController.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2017-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2017-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -8,7 +8,6 @@ #include "frc/RobotController.h" #include -#include #include #include diff --git a/wpilibc/src/main/native/cpp/SensorUtil.cpp b/wpilibc/src/main/native/cpp/SensorUtil.cpp index 3e0b86e129..f86c72c5a6 100644 --- a/wpilibc/src/main/native/cpp/SensorUtil.cpp +++ b/wpilibc/src/main/native/cpp/SensorUtil.cpp @@ -10,7 +10,6 @@ #include #include #include -#include #include #include #include diff --git a/wpilibc/src/main/native/cpp/Timer.cpp b/wpilibc/src/main/native/cpp/Timer.cpp index fb6f6144e2..b428e03c5a 100644 --- a/wpilibc/src/main/native/cpp/Timer.cpp +++ b/wpilibc/src/main/native/cpp/Timer.cpp @@ -7,13 +7,7 @@ #include "frc/Timer.h" -#include -#include - -#include - -#include "frc/DriverStation.h" -#include "frc/RobotController.h" +#include namespace frc { diff --git a/wpilibc/src/main/native/cpp/Ultrasonic.cpp b/wpilibc/src/main/native/cpp/Ultrasonic.cpp index bbc37f7309..dbd0d1304e 100644 --- a/wpilibc/src/main/native/cpp/Ultrasonic.cpp +++ b/wpilibc/src/main/native/cpp/Ultrasonic.cpp @@ -9,6 +9,7 @@ #include +#include "frc/Base.h" #include "frc/Counter.h" #include "frc/DigitalInput.h" #include "frc/DigitalOutput.h" diff --git a/wpilibc/src/main/native/cpp/Utility.cpp b/wpilibc/src/main/native/cpp/Utility.cpp index 11f6234def..4b69cc8481 100644 --- a/wpilibc/src/main/native/cpp/Utility.cpp +++ b/wpilibc/src/main/native/cpp/Utility.cpp @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -12,19 +12,13 @@ #include #endif -#include -#include -#include - +#include #include -#include #include #include #include #include -#include "frc/ErrorBase.h" - using namespace frc; bool wpi_assert_impl(bool conditionValue, const wpi::Twine& conditionText, diff --git a/wpilibc/src/main/native/cpp/frc2/Timer.cpp b/wpilibc/src/main/native/cpp/frc2/Timer.cpp index 8350115b53..36da4c6a67 100644 --- a/wpilibc/src/main/native/cpp/frc2/Timer.cpp +++ b/wpilibc/src/main/native/cpp/frc2/Timer.cpp @@ -10,8 +10,6 @@ #include #include -#include - #include "frc/DriverStation.h" #include "frc/RobotController.h" diff --git a/wpilibc/src/main/native/include/frc/CAN.h b/wpilibc/src/main/native/include/frc/CAN.h index 9410fb6c8b..612d5334d0 100644 --- a/wpilibc/src/main/native/include/frc/CAN.h +++ b/wpilibc/src/main/native/include/frc/CAN.h @@ -10,7 +10,6 @@ #include #include -#include #include "frc/ErrorBase.h" diff --git a/wpilibc/src/main/native/include/frc/DriverStation.h b/wpilibc/src/main/native/include/frc/DriverStation.h index b0c9208945..85b067cb62 100644 --- a/wpilibc/src/main/native/include/frc/DriverStation.h +++ b/wpilibc/src/main/native/include/frc/DriverStation.h @@ -16,11 +16,9 @@ #include #include #include -#include #include #include "frc/ErrorBase.h" -#include "frc/RobotState.h" namespace frc { diff --git a/wpilibc/src/main/native/include/frc/Error.h b/wpilibc/src/main/native/include/frc/Error.h index 8eafd1092a..d63fb628db 100644 --- a/wpilibc/src/main/native/include/frc/Error.h +++ b/wpilibc/src/main/native/include/frc/Error.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2018 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,8 +7,6 @@ #pragma once -#include - #include #include @@ -19,8 +17,6 @@ #undef GetMessage #endif -#include "frc/Base.h" - namespace frc { class ErrorBase; diff --git a/wpilibc/src/main/native/include/frc/ErrorBase.h b/wpilibc/src/main/native/include/frc/ErrorBase.h index e9168aa53d..0ced9a2716 100644 --- a/wpilibc/src/main/native/include/frc/ErrorBase.h +++ b/wpilibc/src/main/native/include/frc/ErrorBase.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -11,9 +11,7 @@ #include #include -#include -#include "frc/Base.h" #include "frc/Error.h" // Forward declared manually to avoid needing to pull in entire HAL header. diff --git a/wpilibc/src/main/native/include/frc/Joystick.h b/wpilibc/src/main/native/include/frc/Joystick.h index 4ae398c51b..0975e6dd74 100644 --- a/wpilibc/src/main/native/include/frc/Joystick.h +++ b/wpilibc/src/main/native/include/frc/Joystick.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -9,8 +9,6 @@ #include -#include - #include "frc/GenericHID.h" namespace frc { diff --git a/wpilibc/src/main/native/include/frc/RobotState.h b/wpilibc/src/main/native/include/frc/RobotState.h index 60e608ab04..5f1c136077 100644 --- a/wpilibc/src/main/native/include/frc/RobotState.h +++ b/wpilibc/src/main/native/include/frc/RobotState.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -7,8 +7,6 @@ #pragma once -#include - namespace frc { class RobotState { diff --git a/wpilibc/src/main/native/include/frc/Timer.h b/wpilibc/src/main/native/include/frc/Timer.h index c766afaa26..ac166c5241 100644 --- a/wpilibc/src/main/native/include/frc/Timer.h +++ b/wpilibc/src/main/native/include/frc/Timer.h @@ -7,11 +7,6 @@ #pragma once -#include -#include -#include - -#include "frc/Base.h" #include "frc2/Timer.h" namespace frc { diff --git a/wpilibc/src/main/native/include/frc/Utility.h b/wpilibc/src/main/native/include/frc/Utility.h index 3caaf84f87..a02e583150 100644 --- a/wpilibc/src/main/native/include/frc/Utility.h +++ b/wpilibc/src/main/native/include/frc/Utility.h @@ -1,5 +1,5 @@ /*----------------------------------------------------------------------------*/ -/* Copyright (c) 2008-2019 FIRST. All Rights Reserved. */ +/* Copyright (c) 2008-2020 FIRST. All Rights Reserved. */ /* Open Source Software - may be modified and shared by FRC teams. The code */ /* must be accompanied by the FIRST BSD license file in the root directory of */ /* the project. */ @@ -11,13 +11,8 @@ * @file Contains global utility functions */ -#include - -#include - #include #include -#include #define wpi_assert(condition) \ wpi_assert_impl(condition, #condition, "", __FILE__, __LINE__, __FUNCTION__) diff --git a/wpilibc/src/main/native/include/frc2/Timer.h b/wpilibc/src/main/native/include/frc2/Timer.h index 97b41d9537..8f943a6e9f 100644 --- a/wpilibc/src/main/native/include/frc2/Timer.h +++ b/wpilibc/src/main/native/include/frc2/Timer.h @@ -8,11 +8,8 @@ #pragma once #include -#include #include -#include "frc/Base.h" - namespace frc2 { /**