Class VPump
java.lang.Object
com.tccc.kos.ext.dispense.Pump<T>
com.tccc.kos.ext.freestyle.FreestylePump<T>
com.tccc.kos.ext.freestyle.hardware.can.subnode.pump.AbstractCANPump<CANPumpConfig>
com.tccc.kos.ext.freestyle.hardware.can.subnode.pump.VPump
- All Implemented Interfaces:
com.tccc.kos.commons.core.service.config.ConfigAware<CANPumpConfig>,com.tccc.kos.commons.core.service.handle.HandleAware,com.tccc.kos.commons.util.Abortable,com.tccc.kos.commons.util.Cancelable,com.tccc.kos.commons.util.Terminable,com.tccc.kos.ext.dispense.PourAvailability
Represents a virtual DEKA pump node. This is used as a bridge between
the DEKA control algorithm and a real pump or valve.
- Version:
- Mar-12-18
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.tccc.kos.ext.dispense.PourAvailability
com.tccc.kos.ext.dispense.PourAvailability.Type -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbind(VPumpBinding binding) Bind a physical device to this virtual pump.doubleReturn the ratio of the overall pour assigned to this pump.doubleReturn the captured requested rate.getType()booleanstatic PumpInfopumpInfo(int pos, int maxPos) Return default pump info for this pump.voidsetCurrentRate(double rate) Tell the vpump the current rate of pour.voidsetFixedRate(boolean fixedRate) Set whether this vpump reports itself as a fixed rate or variable rate pump.Methods inherited from class com.tccc.kos.ext.freestyle.hardware.can.subnode.pump.AbstractCANPump
isAborted, toString, tpour, vpourMethods inherited from class com.tccc.kos.ext.freestyle.FreestylePump
setFixedRatePumpMethods inherited from class com.tccc.kos.ext.dispense.Pump
abort, cancel, getAltType, getBeverageAvailabilityLock, getBeverageLocks, getBoard, getCategory, getConfig, getEffectiveIngredientId, getHandle, getHolder, getIngredientAvailabilityLock, getIngredientId, getIngredientLocks, getIntent, getLastChangedTime, getLastStartTime, getNominalRate, getNozzle, getPour, getPrevIngredientId, getUnavailableReasons, isBeveragePour, isIngredientPour, isInserted, postStop, pour, preStart, record, recordRate, setAltType, setConfig, setLastStartTime, setPour, setPrevIngredientId, setUnavailableReasons, sinceLastStartedMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.tccc.kos.commons.core.service.config.ConfigAware
onConfigChanged, onConfigSetMethods inherited from interface com.tccc.kos.commons.core.service.handle.HandleAware
addHandleChild, getName, getPathMethods inherited from interface com.tccc.kos.ext.dispense.PourAvailability
getAvailbilityLock
-
Field Details
-
TYPE
- See Also:
-
-
Constructor Details
-
VPump
Create a pump with the specified CANOpen subNodeId.- Parameters:
board- the board the sub-node is associated withinfo- info about the pumpsubNodeId- the CAN bus sub-node for this pump
-
-
Method Details
-
pumpInfo
Return default pump info for this pump. -
getType
- Specified by:
getTypein classcom.tccc.kos.ext.dispense.Pump<CANPumpConfig>
-
bind
Bind a physical device to this virtual pump.- Parameters:
binding- the binding to the physical device
-
setCurrentRate
Tell the vpump the current rate of pour.- Parameters:
rate- the rate in ml/sec- Throws:
IOException
-
setFixedRate
public void setFixedRate(boolean fixedRate) Set whether this vpump reports itself as a fixed rate or variable rate pump. If this is a valve, this should report as fixed rate for example.- Parameters:
fixedRate- true if fixed rate, false if variable
-
getPourRatio
Return the ratio of the overall pour assigned to this pump. This is returned as a value in the range of 0 to 1.0. For a recipe pour this will be the ratio defined in the recipe. For a non-recipe pour, this will always return 1.0.- Returns:
- assigned ratio of the pour
- Throws:
IOException
-
isFixedRatePump
public boolean isFixedRatePump()- Overrides:
isFixedRatePumpin classFreestylePump<CANPumpConfig>
-
getRequestedRate
public double getRequestedRate()Return the captured requested rate.
-