RoboJDETM v2.0

com.ridgesoft.robotics
Interface Motor2

All Superinterfaces:
Motor

public interface Motor2
extends Motor

Exteneded generic interface to a variable power motor which provides finer grained power control than the Motor interface.


Field Summary
static int MAX_FORWARD2
          Maximum power setting in the forward direction when using the setPower2 method.
static int MAX_REVERSE2
          Maximum power setting in the reverse direction when using the setPower2 method.
 
Fields inherited from interface com.ridgesoft.robotics.Motor
MAX_FORWARD, MAX_REVERSE, STOP
 
Method Summary
 void setPower2(int power2)
          Sets the motor's power.
 
Methods inherited from interface com.ridgesoft.robotics.Motor
brake, setPower, stop
 

Field Detail

MAX_FORWARD2

static final int MAX_FORWARD2
Maximum power setting in the forward direction when using the setPower2 method.

See Also:
Constant Field Values

MAX_REVERSE2

static final int MAX_REVERSE2
Maximum power setting in the reverse direction when using the setPower2 method.

See Also:
Constant Field Values
Method Detail

setPower2

void setPower2(int power2)
Sets the motor's power.

This method provides finer grained power control than the setPower method of the Motor interface.

Note: Do not use MAX_FORWARD or MAX_REVERSE with this method. Instead, use MAX_FORWARD2 or MAX_REVERSE2.

Parameters:
power2 - the power level to set
  • 64 = maximum forward power
  • 0 = no power, motor will coast and/or stop
  • -64 = maximum reverse power

RoboJDETM v2.0

Copyright (c) 2003-2009 RidgeSoft, LLC. All rights reserved.
www.ridgesoft.com