

def operatorControl(self):
    'Called when operation control mode is enabled'
    timer = wpilib.Timer()
    timer.start()
    while (self.isOperatorControl() and self.isEnabled()):
        self.robot_drive.arcadeDrive(self.lstick)
        y = self.rstick.getY()
        if self.limit1.get():
            y = max(0, y)
        if self.limit2.get():
            y = min(0, y)
        y.motor.set(y)
        wpilib.Timer.delay(0.04)

dataset/ETHPy150Open robotpy/pyfrc/samples/physics/src/robot.py MyRobot.operatorControl/VarMisuse@106/141 `self`->`y`