mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-27 02:01:42 +00:00
Add an additional member variable for "stopped" which indicates the CAN motor controller has been explicitly stopped, but not disabled by the user (main use case is MotorSafety tripping). When Set() is called the next time the controller will be re-enabled automatically.
Change-Id: Ib1c0e5d0ddd55343d83039acbc46c0f9c4e451a1
This commit is contained in:
@@ -230,6 +230,7 @@ class CANJaguar : public MotorSafety,
|
||||
mutable std::atomic<bool> m_receivedStatusMessage2{false};
|
||||
|
||||
bool m_controlEnabled = false;
|
||||
bool m_stopped = false;
|
||||
|
||||
void verify();
|
||||
|
||||
|
||||
@@ -437,6 +437,7 @@ class CANTalon : public MotorSafety,
|
||||
// actually test this.
|
||||
|
||||
bool m_controlEnabled = true;
|
||||
bool m_stopped = false;
|
||||
ControlMode m_controlMode = kPercentVbus;
|
||||
TalonControlMode m_sendMode;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user