Header menu logo issie

CanvasStateAnalyser Module

Types

Type Description

CustomComponentError

MapData

Return all the Ids of all input ports across all components. Return also the ComponentId which may be used in error messages.

Functions and values

Function or value Description

analyseState (arg1, arg2) ldComps

Full Usage: analyseState (arg1, arg2) ldComps

Parameters:
Returns: SimulationError option * ConnectionsWidth option

Analyse a CanvasState and return any error (or None).

arg0 : Component list
arg1 : Connection list
ldComps : LoadedComponent list
Returns: SimulationError option * ConnectionsWidth option

checkAdderUnnecessaryNC (arg1, arg2)

Full Usage: checkAdderUnnecessaryNC (arg1, arg2)

Parameters:
Returns: SimulationError option

Check whether Adders have a NotConnected component connected to their COUT this is unnecessary since it can be disabled via its options

arg0 : Component list
arg1 : Connection list
Returns: SimulationError option

checkComponentNamesAreOk (arg1, arg2)

Full Usage: checkComponentNamesAreOk (arg1, arg2)

Parameters:
Returns: SimulationError option

check component labels are all unique and do not include protected values (CLK)

arg0 : Component list
arg1 : Connection list
Returns: SimulationError option

checkCustomComponentForOkIOs c args sheets

Full Usage: checkCustomComponentForOkIOs c args sheets

Parameters:
Returns: Result<unit, (Component * CustomComponentError)>

Check a single custom component for correct I/Os

c : Component
args : CustomComponentType
sheets : LoadedComponent list
Returns: Result<unit, (Component * CustomComponentError)>

checkCustomComponentsOk (arg1, arg2) sheets

Full Usage: checkCustomComponentsOk (arg1, arg2) sheets

Parameters:
Returns: SimulationError option

Custom components have I/Os which are the same (names) as the I/Os in the corresponding sheet This can change if a sheet made into a custom component is edited We do this check whenever a new sheet is opened

arg0 : Component list
arg1 : Connection list
sheets : LoadedComponent list
Returns: SimulationError option

getOutErrType count port rmInfo

Full Usage: getOutErrType count port rmInfo

Parameters:
Returns: SimulationErrorType
count : int
port : Port
rmInfo : PortRmInfo
Returns: SimulationErrorType

getPortName comp port

Full Usage: getPortName comp port

Parameters:
Returns: string
comp : Component
port : Port
Returns: string

getPortNum pList port

Full Usage: getPortNum pList port

Parameters:
Returns: int option
pList : Port list
port : Port
Returns: int option

getRmInfoData m port

Full Usage: getRmInfoData m port

Parameters:
Returns: Component * string
m : MapData
port : Port
Returns: Component * string

portNames componentType

Full Usage: portNames componentType

Parameters:
Returns: string list * string list

Input and Output names of the ports depending on their ComponentType

componentType : ComponentType
Returns: string list * string list

Type something to start searching.