SCRIPT namespace replacements

This commit is contained in:
PJ Reiniger
2025-11-07 20:00:05 -05:00
committed by Peter Johnson
parent ae6c043632
commit 9aca8e0fd6
2622 changed files with 22275 additions and 22275 deletions

View File

@@ -11,7 +11,7 @@
#include "wpi/event/BooleanEvent.hpp"
using namespace frc;
using namespace wpi;
PS4Controller::PS4Controller(int port) : GenericHID(port) {
HAL_ReportUsage("HID", port, "PS4Controller");
@@ -277,7 +277,7 @@ bool PS4Controller::GetTouchpadReleased() {
return GetRawButtonReleased(Button::kTouchpad);
}
void PS4Controller::InitSendable(wpi::SendableBuilder& builder) {
void PS4Controller::InitSendable(wpi::util::SendableBuilder& builder) {
builder.SetSmartDashboardType("HID");
builder.PublishConstString("ControllerType", "PS4");
builder.AddDoubleProperty("L2 Axis", [this] { return GetL2Axis(); }, nullptr);

View File

@@ -11,7 +11,7 @@
#include "wpi/event/BooleanEvent.hpp"
using namespace frc;
using namespace wpi;
PS5Controller::PS5Controller(int port) : GenericHID(port) {
HAL_ReportUsage("HID", port, "PS5Controller");
@@ -277,7 +277,7 @@ bool PS5Controller::GetTouchpadReleased() {
return GetRawButtonReleased(Button::kTouchpad);
}
void PS5Controller::InitSendable(wpi::SendableBuilder& builder) {
void PS5Controller::InitSendable(wpi::util::SendableBuilder& builder) {
builder.SetSmartDashboardType("HID");
builder.PublishConstString("ControllerType", "PS5");
builder.AddDoubleProperty("L2 Axis", [this] { return GetL2Axis(); }, nullptr);

View File

@@ -11,7 +11,7 @@
#include "wpi/event/BooleanEvent.hpp"
using namespace frc;
using namespace wpi;
StadiaController::StadiaController(int port) : GenericHID(port) {
HAL_ReportUsage("HID", port, "StadiaController");
@@ -297,7 +297,7 @@ bool StadiaController::GetRightBumperReleased() {
return GetRawButtonReleased(Button::kRightBumper);
}
void StadiaController::InitSendable(wpi::SendableBuilder& builder) {
void StadiaController::InitSendable(wpi::util::SendableBuilder& builder) {
builder.SetSmartDashboardType("HID");
builder.PublishConstString("ControllerType", "Stadia");
builder.AddDoubleProperty("LeftX", [this] { return GetLeftX(); }, nullptr);

View File

@@ -11,7 +11,7 @@
#include "wpi/event/BooleanEvent.hpp"
using namespace frc;
using namespace wpi;
XboxController::XboxController(int port) : GenericHID(port) {
HAL_ReportUsage("HID", port, "XboxController");
@@ -241,7 +241,7 @@ bool XboxController::GetRightBumperReleased() {
return GetRawButtonReleased(Button::kRightBumper);
}
void XboxController::InitSendable(wpi::SendableBuilder& builder) {
void XboxController::InitSendable(wpi::util::SendableBuilder& builder) {
builder.SetSmartDashboardType("HID");
builder.PublishConstString("ControllerType", "Xbox");
builder.AddDoubleProperty("LeftTrigger Axis", [this] { return GetLeftTriggerAxis(); }, nullptr);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
Koors40::Koors40(int channel) : PWMMotorController("Koors40", channel) {
SetBounds(2.004_ms, 1.52_ms, 1.5_ms, 1.48_ms, 0.997_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
PWMSparkFlex::PWMSparkFlex(int channel) : PWMMotorController("PWMSparkFlex", channel) {
SetBounds(2.003_ms, 1.55_ms, 1.5_ms, 1.46_ms, 0.999_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
PWMSparkMax::PWMSparkMax(int channel) : PWMMotorController("PWMSparkMax", channel) {
SetBounds(2.003_ms, 1.55_ms, 1.5_ms, 1.46_ms, 0.999_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
PWMTalonFX::PWMTalonFX(int channel) : PWMMotorController("PWMTalonFX", channel) {
SetBounds(2.004_ms, 1.52_ms, 1.5_ms, 1.48_ms, 0.997_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
PWMTalonSRX::PWMTalonSRX(int channel) : PWMMotorController("PWMTalonSRX", channel) {
SetBounds(2.004_ms, 1.52_ms, 1.5_ms, 1.48_ms, 0.997_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
PWMVenom::PWMVenom(int channel) : PWMMotorController("PWMVenom", channel) {
SetBounds(2.004_ms, 1.52_ms, 1.5_ms, 1.48_ms, 0.997_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
PWMVictorSPX::PWMVictorSPX(int channel) : PWMMotorController("PWMVictorSPX", channel) {
SetBounds(2.004_ms, 1.52_ms, 1.5_ms, 1.48_ms, 0.997_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
Spark::Spark(int channel) : PWMMotorController("Spark", channel) {
SetBounds(2.003_ms, 1.55_ms, 1.5_ms, 1.46_ms, 0.999_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
SparkMini::SparkMini(int channel) : PWMMotorController("SparkMini", channel) {
SetBounds(2.5_ms, 1.51_ms, 1.5_ms, 1.49_ms, 0.5_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
Talon::Talon(int channel) : PWMMotorController("Talon", channel) {
SetBounds(2.037_ms, 1.539_ms, 1.513_ms, 1.487_ms, 0.989_ms);

View File

@@ -8,7 +8,7 @@
#include "wpi/hal/UsageReporting.h"
using namespace frc;
using namespace wpi;
VictorSP::VictorSP(int channel) : PWMMotorController("VictorSP", channel) {
SetBounds(2.004_ms, 1.52_ms, 1.5_ms, 1.48_ms, 0.997_ms);

View File

@@ -8,8 +8,8 @@
#include "wpi/driverstation/PS4Controller.hpp"
using namespace frc;
using namespace frc::sim;
using namespace wpi;
using namespace wpi::sim;
PS4ControllerSim::PS4ControllerSim(const PS4Controller& joystick)
: GenericHIDSim{joystick} {

View File

@@ -8,8 +8,8 @@
#include "wpi/driverstation/PS5Controller.hpp"
using namespace frc;
using namespace frc::sim;
using namespace wpi;
using namespace wpi::sim;
PS5ControllerSim::PS5ControllerSim(const PS5Controller& joystick)
: GenericHIDSim{joystick} {

View File

@@ -8,8 +8,8 @@
#include "wpi/driverstation/StadiaController.hpp"
using namespace frc;
using namespace frc::sim;
using namespace wpi;
using namespace wpi::sim;
StadiaControllerSim::StadiaControllerSim(const StadiaController& joystick)
: GenericHIDSim{joystick} {

View File

@@ -8,8 +8,8 @@
#include "wpi/driverstation/XboxController.hpp"
using namespace frc;
using namespace frc::sim;
using namespace wpi;
using namespace wpi::sim;
XboxControllerSim::XboxControllerSim(const XboxController& joystick)
: GenericHIDSim{joystick} {

View File

@@ -11,7 +11,7 @@
#include "wpi/driverstation/GenericHID.hpp"
namespace frc {
namespace wpi {
/**
* Handle input from PS4 controllers connected to the Driver Station.
@@ -26,8 +26,8 @@ namespace frc {
* to have the same mapping, as well as any 3rd party controllers.
*/
class PS4Controller : public GenericHID,
public wpi::Sendable,
public wpi::SendableHelper<PS4Controller> {
public wpi::util::Sendable,
public wpi::util::SendableHelper<PS4Controller> {
public:
/**
* Construct an instance of a controller.
@@ -602,7 +602,7 @@ class PS4Controller : public GenericHID,
static constexpr int kR2 = 4;
};
void InitSendable(wpi::SendableBuilder& builder) override;
void InitSendable(wpi::util::SendableBuilder& builder) override;
};
} // namespace frc
} // namespace wpi

View File

@@ -11,7 +11,7 @@
#include "wpi/driverstation/GenericHID.hpp"
namespace frc {
namespace wpi {
/**
* Handle input from PS5 controllers connected to the Driver Station.
@@ -26,8 +26,8 @@ namespace frc {
* to have the same mapping, as well as any 3rd party controllers.
*/
class PS5Controller : public GenericHID,
public wpi::Sendable,
public wpi::SendableHelper<PS5Controller> {
public wpi::util::Sendable,
public wpi::util::SendableHelper<PS5Controller> {
public:
/**
* Construct an instance of a controller.
@@ -602,7 +602,7 @@ class PS5Controller : public GenericHID,
static constexpr int kR2 = 4;
};
void InitSendable(wpi::SendableBuilder& builder) override;
void InitSendable(wpi::util::SendableBuilder& builder) override;
};
} // namespace frc
} // namespace wpi

View File

@@ -11,7 +11,7 @@
#include "wpi/driverstation/GenericHID.hpp"
namespace frc {
namespace wpi {
/**
* Handle input from Stadia controllers connected to the Driver Station.
@@ -26,8 +26,8 @@ namespace frc {
* to have the same mapping, as well as any 3rd party controllers.
*/
class StadiaController : public GenericHID,
public wpi::Sendable,
public wpi::SendableHelper<StadiaController> {
public wpi::util::Sendable,
public wpi::util::SendableHelper<StadiaController> {
public:
/**
* Construct an instance of a controller.
@@ -649,7 +649,7 @@ class StadiaController : public GenericHID,
static constexpr int kRightY = 4;
};
void InitSendable(wpi::SendableBuilder& builder) override;
void InitSendable(wpi::util::SendableBuilder& builder) override;
};
} // namespace frc
} // namespace wpi

View File

@@ -11,7 +11,7 @@
#include "wpi/driverstation/GenericHID.hpp"
namespace frc {
namespace wpi {
/**
* Handle input from Xbox controllers connected to the Driver Station.
@@ -26,8 +26,8 @@ namespace frc {
* to have the same mapping, as well as any 3rd party controllers.
*/
class XboxController : public GenericHID,
public wpi::Sendable,
public wpi::SendableHelper<XboxController> {
public wpi::util::Sendable,
public wpi::util::SendableHelper<XboxController> {
public:
/**
* Construct an instance of a controller.
@@ -548,7 +548,7 @@ class XboxController : public GenericHID,
static constexpr int kRightTrigger = 3;
};
void InitSendable(wpi::SendableBuilder& builder) override;
void InitSendable(wpi::util::SendableBuilder& builder) override;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* AndyMark Koors40 Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class Koors40 : public PWMMotorController {
Koors40& operator=(Koors40&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* REV Robotics SPARK Flex Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class PWMSparkFlex : public PWMMotorController {
PWMSparkFlex& operator=(PWMSparkFlex&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* REV Robotics SPARK MAX Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class PWMSparkMax : public PWMMotorController {
PWMSparkMax& operator=(PWMSparkMax&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* Cross the Road Electronics (CTRE) Talon FX Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class PWMTalonFX : public PWMMotorController {
PWMTalonFX& operator=(PWMTalonFX&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* Cross the Road Electronics (CTRE) Talon SRX Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class PWMTalonSRX : public PWMMotorController {
PWMTalonSRX& operator=(PWMTalonSRX&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* Playing with Fusion Venom Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class PWMVenom : public PWMMotorController {
PWMVenom& operator=(PWMVenom&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* Cross the Road Electronics (CTRE) Victor SPX Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class PWMVictorSPX : public PWMMotorController {
PWMVictorSPX& operator=(PWMVictorSPX&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* REV Robotics SPARK Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class Spark : public PWMMotorController {
Spark& operator=(Spark&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* REV Robotics SPARKMini Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class SparkMini : public PWMMotorController {
SparkMini& operator=(SparkMini&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* Cross the Road Electronics (CTRE) Talon Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class Talon : public PWMMotorController {
Talon& operator=(Talon&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/hardware/motor/PWMMotorController.hpp"
namespace frc {
namespace wpi {
/**
* Vex Robotics Victor SP Motor Controller with PWM control.
@@ -40,4 +40,4 @@ class VictorSP : public PWMMotorController {
VictorSP& operator=(VictorSP&&) = default;
};
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/simulation/GenericHIDSim.hpp"
namespace frc {
namespace wpi {
class PS4Controller;
@@ -187,4 +187,4 @@ class PS4ControllerSim : public GenericHIDSim {
};
} // namespace sim
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/simulation/GenericHIDSim.hpp"
namespace frc {
namespace wpi {
class PS5Controller;
@@ -187,4 +187,4 @@ class PS5ControllerSim : public GenericHIDSim {
};
} // namespace sim
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/simulation/GenericHIDSim.hpp"
namespace frc {
namespace wpi {
class StadiaController;
@@ -169,4 +169,4 @@ class StadiaControllerSim : public GenericHIDSim {
};
} // namespace sim
} // namespace frc
} // namespace wpi

View File

@@ -8,7 +8,7 @@
#include "wpi/simulation/GenericHIDSim.hpp"
namespace frc {
namespace wpi {
class XboxController;
@@ -170,4 +170,4 @@ class XboxControllerSim : public GenericHIDSim {
};
} // namespace sim
} // namespace frc
} // namespace wpi