Package xbot.common.controls.actuators
Class XPWM
java.lang.Object
xbot.common.controls.actuators.XPWM
- All Implemented Interfaces:
XBaseIO
- Direct Known Subclasses:
MockPWM
,PWMWPIAdapter
-
Nested Class Summary
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
abstract int
getRaw()
abstract double
abstract double
abstract void
setRaw
(int value) Sets the PWM duty cycleabstract void
setSigned
(double value) Sets the PWM duty cycleabstract void
setUnsigned
(double value) Sets the PWM duty cycle
-
Field Details
-
channel
protected int channel
-
-
Constructor Details
-
XPWM
-
-
Method Details
-
getChannel
public int getChannel()- Specified by:
getChannel
in interfaceXBaseIO
-
setRaw
public abstract void setRaw(int value) Sets the PWM duty cycle- Parameters:
value
- the value to set, in the range [0, 255]
-
getRaw
public abstract int getRaw() -
setSigned
public abstract void setSigned(double value) Sets the PWM duty cycle- Parameters:
value
- the value to set, in the range [-1, 1]
-
getSigned
public abstract double getSigned() -
setUnsigned
public abstract void setUnsigned(double value) Sets the PWM duty cycle- Parameters:
value
- the value to set, in the range [0, 1]
-
getUnsigned
public abstract double getUnsigned()
-