Drive the motor forwards.

        :param float speed:
            The speed at which the motor should turn. Can be any value between
            0 (stopped) and the default 1 (maximum speed).
516041
def forward(self, speed=1):
        
        if isinstance(self.enable_device, DigitalOutputDevice):
            if speed not in (0, 1):
                raise ValueError(
                    'forward speed must be 0 or 1 with non-PWM Motors')
        self.enable_device.off()
        self.phase_device.off()
        self.enable_device.value = speed
1220295
def fps(self,value):
		
		if not value is None:
			if not type(value) == float:
				raise ValueError("fps needs to be specified as a float")
			if value<1.0:
				raise ValueError("fps needs to be greater than 1.0")
		self.__fps = value
759485
def fade_speed(self, value):
        

        if value is not None:
            assert type(value) is float, "'{0}' attribute: '{1}' type is not 'float'!".format("fade_speed", value)
            assert value >= 0, "'{0}' attribute: '{1}' need to be exactly positive!".format("fade_speed", value)
        self.__fade_speed = value
1146169
def turn_right(self, speed, degrees, brake=True, block=True):
        
        self._turn(speed, abs(degrees), brake, block)
1061987
protected void setSpeed(boolean reverse, IntsRef edgeFlags, double speed) {
        if (speed < 0 || Double.isNaN(speed))
            throw new IllegalArgumentException("Speed cannot be negative or NaN: " + speed + ", flags:" + BitUtil.LITTLE.toBitString(edgeFlags));

        if (speed < speedFactor / 2) {
            speedEncoder.setDecimal(reverse, edgeFlags, 0);
            accessEnc.setBool(reverse, edgeFlags, false);
            return;
        }

        if (speed > getMaxSpeed())
            speed = getMaxSpeed();

        speedEncoder.setDecimal(reverse, edgeFlags, speed);
    }
1333146
def forward(self, step):
        
        x = self.pos_x + math.cos(math.radians(self.rotation)) * step
        y = self.pos_y + math.sin(math.radians(self.rotation)) * step
        prev_brush_state = self.brush_on
        self.brush_on = True
        self.move(x, y)
        self.brush_on = prev_brush_state
699070
def compute(self, motor_pct: float, tm_diff: float) -> float:
        

        appliedVoltage = self._nominalVoltage * motor_pct
        appliedVoltage = math.copysign(
            max(abs(appliedVoltage) - self._vintercept, 0), appliedVoltage
        )

        # Heun's method (taken from Ether's drivetrain calculator)
        # -> yn+1 = yn + (h/2) (f(xn, yn) + f(xn + h, yn +  h f(xn, yn)))
        a0 = self.acceleration
        v0 = self.velocity

        # initial estimate for next velocity/acceleration
        v1 = v0 + a0 * tm_diff
        a1 = (appliedVoltage - self._kv * v1) / self._ka

        # corrected trapezoidal estimate
        v1 = v0 + (a0 + a1) * 0.5 * tm_diff
        a1 = (appliedVoltage - self._kv * v1) / self._ka
        self.position += (v0 + v1) * 0.5 * tm_diff

        self.velocity = v1
        self.acceleration = a1

        return self.velocity
203939
def move_backward(self):
        """"""
        self.at(ardrone.at.pcmd, True, 0, self.speed, 0, 0)
365490
def _forward_mode(self, *args):
        """"""
        # Evaluate inner function self.f
        X: np.ndarray
        dX: np.ndarray
        X, dX = self.f._forward_mode(*args)
        # Alias the power to p for legibility
        p: float = self.p
        # The function value
        val = X ** p
        # The derivative
        diff = p * X ** (p-1) * dX
        return (val, diff)
52466
def fast_forward(dt)
      adjusted_dt = dt * @relative_rate
      @now += adjusted_dt
      @children.each { |sub_clock| sub_clock.fast_forward(adjusted_dt) }
    end
1034948
def cmd_gimbal_rate(self, args):
        ''''''
        if len(args) != 3:
            print("usage: gimbal rate ROLL PITCH YAW")
            return
        (roll, pitch, yaw) = (float(args[0]), float(args[1]), float(args[2]))
        self.master.mav.gimbal_control_send(self.target_system,
                                            mavutil.mavlink.MAV_COMP_ID_GIMBAL,
                                            radians(roll),
                                            radians(pitch),
                                            radians(yaw))
328398
def speed_i(self):
        
        self._speed_i, value = self.get_attr_int(self._speed_i, 'speed_pid/Ki')
        return value
1084797
def move_forward(self, seconds=None):
        """"""
        self._move(speed=SPEED_MAX, steering=0, seconds=seconds)
129721
def left(self, speed=1):
        
        self.right_motor.forward(speed)
        self.left_motor.backward(speed)
1217568
def _set_speed(self, motor, speed):
        
        self._validate_motor(motor)
        en, in1, in2 = self._motors[motor-1]

        if speed == 0:
            en.pwm_stop()
            in1.set(False)
            in2.set(False)
        elif speed > 0:
            en.pwm_start(abs(speed))
            in1.set(True)
            in2.set(False)
        else:
            en.pwm_start(abs(speed))
            in1.set(False)
            in2.set(True)
1292597
def p_delays_floatnumber(self, p):
        ''
        p[0] = DelayStatement(FloatConst(
            p[2], lineno=p.lineno(1)), lineno=p.lineno(1))
        p.set_lineno(0, p.lineno(1))
72133
def speed(self, factor, use_semitones=False):
        
        self.command.append("speed")
        self.command.append(factor if not use_semitones else str(factor) + "c")
        return self