Class CANBoard<T extends CANBoardConfig>
java.lang.Object
com.tccc.kos.core.service.hardware.Board
com.tccc.kos.ext.dispense.PumpBoard
com.tccc.kos.ext.freestyle.hardware.can.board.CANBoard<T>
- All Implemented Interfaces:
com.tccc.kos.commons.core.service.config.ConfigAware<T>,com.tccc.kos.commons.core.service.handle.HandleAware,com.tccc.kos.core.service.assembly.AssemblyAware,com.tccc.kos.core.service.hardware.BoardIdentifier,com.tccc.kos.ext.dispense.pipeline.ingredient.grants.PumpOpLimitAware,com.tccc.kos.ext.dispense.PourAvailability
- Direct Known Subclasses:
AbstractMicroBoard,FlexMacroBoard,KSMBoard,MacKSMBoard,MacroBoard,RCGPBoard
public class CANBoard<T extends CANBoardConfig>
extends com.tccc.kos.ext.dispense.PumpBoard
implements com.tccc.kos.commons.core.service.config.ConfigAware<T>
This represents a single board on the CAN bus. The various CAN related
endpoints use these beans to map hardware addresses to these logical boards
which enables us to talk to them an bind pumps to logical positions on these
boards.
- Version:
- May-18-17
-
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
ConstructorsConstructorDescriptionCANBoard()Dummy constructor for codeGenCANBoard(com.tccc.kos.core.service.assembly.Assembly assembly, String name, String type, int instanceId, PumpInfoResolver resolver) Create a new board with the specified type which is used to match the board bean with the physical board found during CAN bus enumeration and discovery. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddListener(CANBoardActivateListener listener) Add an activation listener to the list.voidFold-back/Rate Error threshold for each zonevoidFold-back/Rate Error Zone SettingvoidEnableFoldbackRateErr(boolean foldBack_enable, boolean rateError_enable, double minConcentration) Enable/Disable Fold-back/Rate Errorcom.tccc.kos.commons.util.ready.ReadyIndicatorintGet the CANOpen nodeId of this board.doublecom.tccc.kos.commons.core.service.trouble.TroubleServicegetType()voidonLink(com.tccc.kos.core.service.hardware.HardwareLink link) voidonUnlink(com.tccc.kos.core.service.hardware.HardwareLink link) Resolve pump info.voidvoidsetSourceWeight(double sourceWeight) toString()Methods inherited from class com.tccc.kos.ext.dispense.PumpBoard
checkPumpOpLimits, getBeverageAvailabilityLock, getIngredientAvailabilityLock, getPumpOpGrantLimit, setPumpOpGrantLimitMethods inherited from class com.tccc.kos.core.service.hardware.Board
addLinkListener, addReadyListener, boardReady, getAssembly, getHandle, getLink, getLinkCount, isLinked, isOptional, isReady, isSticky, onBoardReady, removeListener, setOptional, setSticky, verifyLinkedMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.tccc.kos.core.service.assembly.AssemblyAware
getAssemblyNameMethods 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, getHandle, getName, getPathMethods inherited from interface com.tccc.kos.ext.dispense.PourAvailability
getAvailbilityLock
-
Field Details
-
CRITICAL_DATA_EEPROM_ADDR
public static final int CRITICAL_DATA_EEPROM_ADDR- See Also:
-
-
Constructor Details
-
CANBoard
public CANBoard()Dummy constructor for codeGen -
CANBoard
public CANBoard(com.tccc.kos.core.service.assembly.Assembly assembly, String name, String type, int instanceId, PumpInfoResolver resolver) Create a new board with the specified type which is used to match the board bean with the physical board found during CAN bus enumeration and discovery.- Parameters:
assembly- assembly the board is part ofname- name of the boardtype- the board typeinstanceId- used to identify a given board in multi-board configsresolver- resolve pump info
-
-
Method Details
-
resolve
Resolve pump info. -
getType
- Specified by:
getTypein interfacecom.tccc.kos.core.service.hardware.BoardIdentifier
-
getNodeId
public int getNodeId()Get the CANOpen nodeId of this board.- Returns:
- the nodeId for this board
-
onLink
public void onLink(com.tccc.kos.core.service.hardware.HardwareLink link) - Overrides:
onLinkin classcom.tccc.kos.core.service.hardware.Board
-
onUnlink
public void onUnlink(com.tccc.kos.core.service.hardware.HardwareLink link) - Overrides:
onUnlinkin classcom.tccc.kos.core.service.hardware.Board
-
addListener
Add an activation listener to the list.- Parameters:
listener- the listener to add
-
EnableFoldbackRateErr
public void EnableFoldbackRateErr(boolean foldBack_enable, boolean rateError_enable, double minConcentration) throws IOException Enable/Disable Fold-back/Rate Error- Parameters:
foldBack_enable- True: foldback enabled False: foldback disabledrateError_enable- True: rate err enabled False: rate err disabledminConcentration- Minimum concentration (Ex.0.332)- Throws:
IOException
-
configureZone
Fold-back/Rate Error Zone Setting- Throws:
IOException
-
configureFoldbackRateErr
Fold-back/Rate Error threshold for each zone- Throws:
IOException
-
toString
-
getTroubleService
public com.tccc.kos.commons.core.service.trouble.TroubleService getTroubleService() -
getInstanceId
- Specified by:
getInstanceIdin interfacecom.tccc.kos.core.service.hardware.BoardIdentifier
-
getConfig
- Specified by:
getConfigin interfacecom.tccc.kos.commons.core.service.config.ConfigAware<T extends CANBoardConfig>
-
setConfig
- Specified by:
setConfigin interfacecom.tccc.kos.commons.core.service.config.ConfigAware<T extends CANBoardConfig>
-
getDiagnosticsLock
-
getCriticalDataReady
public com.tccc.kos.commons.util.ready.ReadyIndicator getCriticalDataReady() -
getSourceWeight
public double getSourceWeight() -
setSourceWeight
public void setSourceWeight(double sourceWeight)
-