public interface DistanceSensor extends HardwareDevice
DistanceSensor may be found on hardware sensors which measure distance
by one means or another.HardwareDevice.Manufacturer| Modifier and Type | Field and Description |
|---|---|
static double |
distanceOutOfRange
The value returned when a distance reading is not in fact available.
|
| Modifier and Type | Method and Description |
|---|---|
double |
getDistance(DistanceUnit unit)
Returns the current distance in the indicated distance units
|
close, getConnectionInfo, getDeviceName, getManufacturer, getVersion, resetDeviceConfigurationForOpModestatic final double distanceOutOfRange
double getDistance(DistanceUnit unit)
unit - the unit of distance in which the result should be returneddistanceOutOfRange is
returned;