public class ADXL362 extends SensorBase implements Accelerometer, LiveWindowSendable
This class allows access to an Analog Devices ADXL362 3-axis accelerometer.
| Modifier and Type | Class and Description | 
|---|---|
| static class  | ADXL362.AllAxes | 
| static class  | ADXL362.Axes | 
Accelerometer.RangekAnalogInputChannels, kAnalogOutputChannels, kDigitalChannels, kPCMModules, kPDPChannels, kPDPModules, kPwmChannels, kRelayChannels, kSolenoidChannels, kSystemClockTicksPerMicrosecond| Constructor and Description | 
|---|
| ADXL362(Accelerometer.Range range)Constructor. | 
| ADXL362(SPI.Port port,
       Accelerometer.Range range)Constructor. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | free()Free the resources used by this object. | 
| double | getAcceleration(ADXL362.Axes axis)Get the acceleration of one axis in Gs. | 
| ADXL362.AllAxes | getAccelerations()Get the acceleration of all axes in Gs. | 
| java.lang.String | getSmartDashboardType()The string representation of the named data type that will be used by the smart dashboard for
 this  Sendable. | 
| ITable | getTable()The table that is associated with this  Sendable. | 
| double | getX()Common interface for getting the x axis acceleration. | 
| double | getY()Common interface for getting the y axis acceleration. | 
| double | getZ()Common interface for getting the z axis acceleration. | 
| void | initTable(ITable subtable)Initializes a table for this  Sendableobject. | 
| void | setRange(Accelerometer.Range range)Common interface for setting the measuring range of an accelerometer. | 
| void | startLiveWindowMode()Start having this sendable object automatically respond to value changes reflect the value on
 the table. | 
| void | stopLiveWindowMode()Stop having this sendable object automatically respond to value changes. | 
| void | updateTable()Update the table for this sendable object with the latest values. | 
checkAnalogInputChannel, checkAnalogOutputChannel, checkDigitalChannel, checkPDPChannel, checkPDPModule, checkPWMChannel, checkRelayChannel, checkSolenoidChannel, checkSolenoidModule, getDefaultSolenoidModule, setDefaultSolenoidModulepublic ADXL362(Accelerometer.Range range)
range - The range (+ or -) that the accelerometer will measure.public ADXL362(SPI.Port port, Accelerometer.Range range)
port - The SPI port that the accelerometer is connected torange - The range (+ or -) that the accelerometer will measure.public void free()
SensorBasefree in class SensorBasepublic void setRange(Accelerometer.Range range)
AccelerometersetRange in interface Accelerometerrange - The maximum acceleration, positive or negative, that the accelerometer will
              measure. Not all accelerometers support all ranges.public double getX()
AccelerometergetX in interface Accelerometerpublic double getY()
AccelerometergetY in interface Accelerometerpublic double getZ()
AccelerometergetZ in interface Accelerometerpublic double getAcceleration(ADXL362.Axes axis)
axis - The axis to read from.public ADXL362.AllAxes getAccelerations()
public java.lang.String getSmartDashboardType()
SendableSendable.getSmartDashboardType in interface SendableSendable.public void initTable(ITable subtable)
SendableSendable object.public void updateTable()
LiveWindowSendableupdateTable in interface LiveWindowSendablepublic ITable getTable()
SendableSendable.public void startLiveWindowMode()
LiveWindowSendablestartLiveWindowMode in interface LiveWindowSendablepublic void stopLiveWindowMode()
LiveWindowSendablestopLiveWindowMode in interface LiveWindowSendable