instantiate method
- required Logic clk,
- required Logic reset,
- required Logic flush,
- required ReadyValidInterface<
LogicType> upstream, - required ReadyValidInterface<
LogicType> downstream, - required String name,
Instantiates this binding on compatible ready/valid interfaces.
Implementation
void instantiate(
{required Logic clk,
required Logic reset,
required Logic flush,
required ReadyValidInterface<LogicType> upstream,
required ReadyValidInterface<LogicType> downstream,
required String name}) {
if (upstream.data.width != request.dataWidth ||
downstream.data.width != request.dataWidth) {
throw ArgumentError('Bound queue interfaces do not match the resolved '
'storage request.');
}
if (!rohdPayloadsCompatible([upstream.data, downstream.data],
ignoreConstantNames: true)) {
throw ArgumentError('Bound queue payload schemas must be compatible.');
}
final build =
implementation._build as ReadyValidStorageQueueBuilder<LogicType>;
build(
clk: clk,
reset: reset,
flush: flush,
upstream: upstream,
downstream: downstream,
depth: request.depth,
requestedOutputLatency: request.requestedOutputLatency,
name: name);
}