/** * @return range values * @throws DeviceException */ public String getRangeValue() throws DeviceException { try { short test = controller.cagetEnum(chRangeRBV); return positions.get(test); } catch (Throwable th) { throw new DeviceException("failed to get position from " + chRangeRBV.getName(), th); } }
@Override public void rawAsynchronousMoveTo(Object position) throws DeviceException { // find in the positionNames array the index of the string if (positions.contains(position.toString())) { int target = positions.indexOf(position.toString()); try { controller.caput(chRange, target, channelManager); Thread.sleep(1000); } catch (Throwable th) { throw new DeviceException( chRange.getName() + " failed to moveTo " + position.toString(), th); } return; } // if get here then wrong position name supplied throw new DeviceException("Position called: " + position.toString() + " not found."); }