mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-22 01:11:42 +00:00
[sim] Allow creating a PWMSim object from a PWMMotorController (#4039)
This commit is contained in:
@@ -10,12 +10,16 @@
|
||||
#include <hal/simulation/PWMData.h>
|
||||
|
||||
#include "frc/PWM.h"
|
||||
#include "frc/motorcontrol/PWMMotorController.h"
|
||||
|
||||
using namespace frc;
|
||||
using namespace frc::sim;
|
||||
|
||||
PWMSim::PWMSim(const PWM& pwm) : m_index{pwm.GetChannel()} {}
|
||||
|
||||
PWMSim::PWMSim(const PWMMotorController& motorctrl)
|
||||
: m_index{motorctrl.GetChannel()} {}
|
||||
|
||||
PWMSim::PWMSim(int channel) : m_index{channel} {}
|
||||
|
||||
std::unique_ptr<CallbackStore> PWMSim::RegisterInitializedCallback(
|
||||
|
||||
Reference in New Issue
Block a user