Package com.diozero.devices
Class PiconZeroMotor
java.lang.Object
com.diozero.devices.motor.MotorBase
com.diozero.devices.PiconZeroMotor
- All Implemented Interfaces:
FloatConsumer
,MotorInterface
,Closeable
,AutoCloseable
public class PiconZeroMotor extends MotorBase
-
Constructor Summary
Constructors Constructor Description PiconZeroMotor(PiconZero piconZero, int motor)
-
Method Summary
Methods inherited from class com.diozero.devices.motor.MotorBase
accept, addListener, removeListener, reverse, setValue, whenBackward, whenForward, whenStop
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.diozero.api.function.FloatConsumer
andThen
-
Constructor Details
-
PiconZeroMotor
-
-
Method Details
-
forward
- Throws:
RuntimeIOException
-
backward
- Throws:
RuntimeIOException
-
stop
- Throws:
RuntimeIOException
-
getValue
Get the relative output value for the motor- Returns:
- -1 for full reverse, 1 for full forward, 0 for stop
- Throws:
RuntimeIOException
-
isActive
- Throws:
RuntimeIOException
-
close
- Throws:
IOException
-