icommand.platform.nxt
Class SyncMotors

java.lang.Object
  extended by icommand.platform.nxt.SyncMotors

public class SyncMotors
extends java.lang.Object


Field Summary
 Motor left
           
 Motor right
           
 
Constructor Summary
SyncMotors(Motor left, Motor right)
          The Lego firmware only accepts 3 valid combinations for Motors: A,B A,C B,C PRELIMINARY: Expect poor performance for some commands until things are improved.
 
Method Summary
 void backward()
           
 void backward(long rotations)
          PRELIMINARY: Somewhat overshoots at the moment.
 void flt()
           
 void forward()
           
 void forward(long rotations)
          PRELIMINARY: Somewhat overshoots at the moment.
 void invertMotors()
           
 void left()
           
 void left(long rotations)
          PRELIMINARY: Somewhat inaccurate at the moment.
 void left(long rotations, boolean returnNow)
          PRELIMINARY: Very inaccurate at the moment.
 void right()
           
 void right(long rotations)
          PRELIMINARY: Somewhat inaccurate at the moment.
 void right(long rotations, boolean returnNow)
          PRELIMINARY: Very inaccurate at the moment.
 void setSpeed(int speed)
          Note: This does not alter the speed realtime.
 void stop()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

left

public Motor left

right

public Motor right
Constructor Detail

SyncMotors

public SyncMotors(Motor left,
                  Motor right)
The Lego firmware only accepts 3 valid combinations for Motors: A,B A,C B,C PRELIMINARY: Expect poor performance for some commands until things are improved.

Parameters:
left -
right -
Method Detail

setSpeed

public void setSpeed(int speed)
Note: This does not alter the speed realtime. The speed is changed the next time you call one of the movement methods.

Parameters:
speed -

invertMotors

public void invertMotors()

forward

public void forward()

backward

public void backward()

left

public void left()

right

public void right()

left

public void left(long rotations)
PRELIMINARY: Somewhat inaccurate at the moment.

Parameters:
rotations -

left

public void left(long rotations,
                 boolean returnNow)
PRELIMINARY: Very inaccurate at the moment.

Parameters:
rotations -
returnNow - Returns immediately if true.

right

public void right(long rotations)
PRELIMINARY: Somewhat inaccurate at the moment.

Parameters:
rotations -

right

public void right(long rotations,
                  boolean returnNow)
PRELIMINARY: Very inaccurate at the moment.

Parameters:
rotations -
returnNow - Returns immediately if true.

forward

public void forward(long rotations)
PRELIMINARY: Somewhat overshoots at the moment.

Parameters:
rotations -

backward

public void backward(long rotations)
PRELIMINARY: Somewhat overshoots at the moment.

Parameters:
rotations -

stop

public void stop()

flt

public void flt()