Package edu.wpi.first.wpilibj
Class AnalogOutput
- java.lang.Object
-
- edu.wpi.first.wpilibj.SendableBase
-
- edu.wpi.first.wpilibj.AnalogOutput
-
- All Implemented Interfaces:
Sendable
,AutoCloseable
public class AnalogOutput extends SendableBase
Analog output class.
-
-
Constructor Summary
Constructors Constructor Description AnalogOutput(int channel)
Construct an analog output on a specified MXP channel.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
int
getChannel()
Get the channel of this AnalogOutput.AnalogOutSim
getSimObject()
double
getVoltage()
void
initSendable(SendableBuilder builder)
Initializes thisSendable
object.void
setVoltage(double voltage)
-
Methods inherited from class edu.wpi.first.wpilibj.SendableBase
addChild, free, getName, getSubsystem, setName, setName, setName, setSubsystem
-
-
-
-
Method Detail
-
close
public void close()
- Specified by:
close
in interfaceAutoCloseable
- Overrides:
close
in classSendableBase
-
getChannel
public int getChannel()
Get the channel of this AnalogOutput.
-
setVoltage
public void setVoltage(double voltage)
-
getVoltage
public double getVoltage()
-
initSendable
public void initSendable(SendableBuilder builder)
Description copied from interface:Sendable
Initializes thisSendable
object.- Parameters:
builder
- sendable builder
-
getSimObject
public AnalogOutSim getSimObject()
-
-