|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnl.tue.id.creapro.admoveo.Motor
public class Motor
This class models the motors on the AdMoVeo robot, providing the not only the control for analog actuators, but also some motor specific controls, such as forward() and backward();
Constructor Summary | |
---|---|
Motor(Arduino arduino,
int speedPin,
int directionPin)
|
Method Summary | |
---|---|
void |
backward()
Sets the motor to move backward. |
void |
forward()
Set the motor to move forward. |
int |
getPower()
|
boolean |
isForward()
|
boolean |
isOn()
|
void |
off()
Switches the actuator off. |
void |
on()
Switches the actuator on. |
void |
reverse()
|
void |
setPower(int power)
Sets the power level of the actuator. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Motor(Arduino arduino, int speedPin, int directionPin)
Method Detail |
---|
public void backward()
public void forward()
public int getPower()
public boolean isForward()
public boolean isOn()
isOn
in interface ActuatorControl
public void off()
ActuatorControl
off
in interface ActuatorControl
public void on()
ActuatorControl
on
in interface ActuatorControl
public void reverse()
public void setPower(int power)
AnalogActuatorControl
setPower
in interface AnalogActuatorControl
power
- the power level, between 0 and 255.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |