41 if (!
m_Drive)
m_Drive =
new RobotDrive (kFrontLeftCh, kBackLeftCh, kFrontRightCh, kBackRightCh);
42 m_Drive->SetExpiration(kSafetyTimeout);
43 m_Drive->SetSafetyEnabled(
true);
virtual void SetSmoothAccel(bool enable)
Joystick * m_DriveStick
joystick controller
bool isGyroEnabled() const
void setGyroEnabled(bool gyroEnabled)
SmoothAxis * m_ValueX
left/right speed [-1.0..1.0]
void setEnabled(bool enabled)
SmoothAxis * m_ValueRotate
Rate of rotation [-1.0..1.0].
bool m_SmoothAccel
State of smooth acceleration capability.
float m_gyroAngle
Gyroscope angle measurement.
Header file for MecanumDrive component.
Gyro * m_Gyro
Gyroscope instance to measure robot's heading.
SmoothAxis * m_ValueY
fwd/bkwd speed, inverted [-1.0..1.0]
virtual void ComponentInit()
JoystickButton * m_GyroButton
Button to dis/enable gyro.
bool m_gyroEnabled
Gyroscope enablement.
void SetTarget(float newTarget)
bool m_GyroButtonIsPressed
Button state.
RobotDrive * m_Drive
drive instance