hwtLib.amba package¶
This package is dedicated to component and utilities related to ARM AMBA interfaces.
This icludes:
AMBA AXI3
AMBA AXI3-lite
AMBA AXI4
AMBA AXI4-lite
AMBA AXI4-stream
AMBA ACE
and others
Available specifications:
https://static.docs.arm.com/ihi0022/d/IHI0022D_amba_axi_protocol_spec.pdf
https://static.docs.arm.com/ihi0051/a/IHI0051A_amba4_axi4_stream_v1_0_protocol_spec.pdf
Subpackages¶
- hwtLib.amba.axiLite_comp package
- Subpackages
- Submodules
- hwtLib.amba.axiLite_comp.axi4Lite_withId module
- hwtLib.amba.axiLite_comp.endpoint module
- hwtLib.amba.axiLite_comp.to_axi module
- hwtLib.amba.axi_comp package
- Subpackages
- hwtLib.amba.axi_comp.cache package
- Submodules
- hwtLib.amba.axi_comp.cache.addrTypeConfig module
- hwtLib.amba.axi_comp.cache.cacheWriteAllocWawOnlyWritePropagating module
AxiCacheWriteAllocWawOnlyWritePropagatingAxiCacheWriteAllocWawOnlyWritePropagating.__annotations__AxiCacheWriteAllocWawOnlyWritePropagating.axiAddrDefaults()AxiCacheWriteAllocWawOnlyWritePropagating.connect_tag_lookup()AxiCacheWriteAllocWawOnlyWritePropagating.flush_handler()AxiCacheWriteAllocWawOnlyWritePropagating.hwImpl()AxiCacheWriteAllocWawOnlyWritePropagating.incr_lru_on_hit()AxiCacheWriteAllocWawOnlyWritePropagating.read_handler()AxiCacheWriteAllocWawOnlyWritePropagating.resolve_victim()AxiCacheWriteAllocWawOnlyWritePropagating.write_handler()
_example_AxiCacheWriteAllocWawOnlyWritePropagating()
- hwtLib.amba.axi_comp.cache.lru_array module
- hwtLib.amba.axi_comp.cache.pseudo_lru module
- hwtLib.amba.axi_comp.cache.tag_array module
- hwtLib.amba.axi_comp.cache.utils module
- hwtLib.amba.axi_comp.interconnect package
- Submodules
- hwtLib.amba.axi_comp.interconnect.base module
- hwtLib.amba.axi_comp.interconnect.common module
- hwtLib.amba.axi_comp.interconnect.matrix module
- hwtLib.amba.axi_comp.interconnect.matrixAddrCrossbar module
AxiInterconnectMatrixAddrCrossbarAxiInterconnectMatrixAddrCrossbar.__annotations__AxiInterconnectMatrixAddrCrossbar.__init__()AxiInterconnectMatrixAddrCrossbar.addr_handler_N_to_M()AxiInterconnectMatrixAddrCrossbar.addr_handler_build_addr_mux()AxiInterconnectMatrixAddrCrossbar.priorityAck()AxiInterconnectMatrixAddrCrossbar.propagate_addr()
example_AxiInterconnectMatrixAddrCrossbar()
- hwtLib.amba.axi_comp.interconnect.matrixCrossbar module
AxiInterconnectMatrixCrossbarAxiInterconnectMatrixCrossbar.__annotations__AxiInterconnectMatrixCrossbar.__init__()AxiInterconnectMatrixCrossbar._masters_for_slave()AxiInterconnectMatrixCrossbar.connection_handler_N_to_M()AxiInterconnectMatrixCrossbar.get_last()AxiInterconnectMatrixCrossbar.handler_data_mux()AxiInterconnectMatrixCrossbar.handler_din_rd()AxiInterconnectMatrixCrossbar.handler_dout_vld()
example_AxiInterconnectMatrixCrossbar()
- hwtLib.amba.axi_comp.interconnect.matrixR module
- hwtLib.amba.axi_comp.interconnect.matrixW module
- hwtLib.amba.axi_comp.lsu package
- Submodules
- hwtLib.amba.axi_comp.lsu.fifo_oooread module
- hwtLib.amba.axi_comp.lsu.hIOs module
- hwtLib.amba.axi_comp.lsu.read_aggregator module
- hwtLib.amba.axi_comp.lsu.store_queue_write_propagating module
- hwtLib.amba.axi_comp.lsu.write_aggregator module
- hwtLib.amba.axi_comp.lsu.write_aggregator_write_dispatcher module
AxiWriteAggregatorWriteDispatcherAxiWriteAggregatorWriteDispatcher.__annotations__AxiWriteAggregatorWriteDispatcher.data_ram_read_to_bus_w()AxiWriteAggregatorWriteDispatcher.dispatch_addr()AxiWriteAggregatorWriteDispatcher.dispatch_data()AxiWriteAggregatorWriteDispatcher.precompute_constants()AxiWriteAggregatorWriteDispatcher.receive_write_confirm()
- hwtLib.amba.axi_comp.oooOp package
- Submodules
- hwtLib.amba.axi_comp.oooOp.outOfOrderCummulativeOp module
OutOfOrderCummulativeOpOutOfOrderCummulativeOp.__annotations__OutOfOrderCummulativeOp._axi_addr_defaults()OutOfOrderCummulativeOp._declr_io()OutOfOrderCummulativeOp._init_constants()OutOfOrderCummulativeOp.apply_data_write_forwarding()OutOfOrderCummulativeOp.ar_dispatch()OutOfOrderCummulativeOp.can_write_forward()OutOfOrderCummulativeOp.collision_detector()OutOfOrderCummulativeOp.data_load()OutOfOrderCummulativeOp.data_store()OutOfOrderCummulativeOp.main_op()OutOfOrderCummulativeOp.main_pipeline()OutOfOrderCummulativeOp.propagate_trans_st()OutOfOrderCummulativeOp.write_cancel()OutOfOrderCummulativeOp.write_forwarding_en()
- hwtLib.amba.axi_comp.oooOp.reorder_buffer module
- hwtLib.amba.axi_comp.oooOp.utils module
HwIOOutOfOrderCummulativeOpHwIOOutOfOrderCummulativeOpAgentOOOOpPipelineStageOutOfOrderCummulativeOpPipelineConfigOutOfOrderCummulativeOpPipelineConfig.READ_DATA_RECEIVEOutOfOrderCummulativeOpPipelineConfig.STATE_LOADOutOfOrderCummulativeOpPipelineConfig.WAIT_FOR_WRITE_ACKOutOfOrderCummulativeOpPipelineConfig.WRITE_BACKOutOfOrderCummulativeOpPipelineConfig.WRITE_HISTORY_SIZEOutOfOrderCummulativeOpPipelineConfig.__annotations__OutOfOrderCummulativeOpPipelineConfig.__getnewargs__()OutOfOrderCummulativeOpPipelineConfig.__match_args__OutOfOrderCummulativeOpPipelineConfig.__new__()OutOfOrderCummulativeOpPipelineConfig.__orig_bases__OutOfOrderCummulativeOpPipelineConfig.__repr__()OutOfOrderCummulativeOpPipelineConfig.__slots__OutOfOrderCummulativeOpPipelineConfig._asdict()OutOfOrderCummulativeOpPipelineConfig._field_defaultsOutOfOrderCummulativeOpPipelineConfig._fieldsOutOfOrderCummulativeOpPipelineConfig._make()OutOfOrderCummulativeOpPipelineConfig._replace()OutOfOrderCummulativeOpPipelineConfig.new_config()
- hwtLib.amba.axi_comp.sim package
- hwtLib.amba.axi_comp.cache package
- Submodules
- hwtLib.amba.axi_comp.buff module
- hwtLib.amba.axi_comp.buff_cdc module
- hwtLib.amba.axi_comp.builder module
- hwtLib.amba.axi_comp.resize module
- hwtLib.amba.axi_comp.slave_timeout module
- hwtLib.amba.axi_comp.static_remap module
- hwtLib.amba.axi_comp.stream_to_mem module
- hwtLib.amba.axi_comp.tester module
- hwtLib.amba.axi_comp.to_axiLite module
- hwtLib.amba.axi_comp.virtualDma module
- Subpackages
- hwtLib.amba.axis_comp package
- Subpackages
- hwtLib.amba.axis_comp.frame_deparser package
- hwtLib.amba.axis_comp.frame_join package
- hwtLib.amba.axis_comp.frame_parser package
- Submodules
- hwtLib.amba.axis_comp.frame_parser.field_connector module
Axi4S_frameParserFieldConnectorAxi4S_frameParserFieldConnector.__init__()Axi4S_frameParserFieldConnector.choiceIsSelected()Axi4S_frameParserFieldConnector.connectChoicesOfFrameParts()Axi4S_frameParserFieldConnector.connectPart()Axi4S_frameParserFieldConnector.connectParts()Axi4S_frameParserFieldConnector.connectStreamOfFrameParts()Axi4S_frameParserFieldConnector.getInDataSignal()
get_byte_order_modifier()
- hwtLib.amba.axis_comp.frame_parser.footer_split module
- hwtLib.amba.axis_comp.frame_parser.out_containers module
- hwtLib.amba.axis_comp.frame_parser.test_types module
- hwtLib.amba.axis_comp.frame_parser.word_factory module
- Submodules
- hwtLib.amba.axis_comp.base module
- hwtLib.amba.axis_comp.builder module
Axi4SBuilderAxi4SBuilder.FifoAsyncClsAxi4SBuilder.FifoClsAxi4SBuilder.FifoDropClsAxi4SBuilder.JoinPrioritizedClsAxi4SBuilder.RegCdcClsAxi4SBuilder.RegClsAxi4SBuilder.ResizerClsAxi4SBuilder.SplitCopyClsAxi4SBuilder.SplitSelectClsAxi4SBuilder.__annotations__Axi4SBuilder.buff_drop()Axi4SBuilder.constant_frame()Axi4SBuilder.deparse()Axi4SBuilder.parse()Axi4SBuilder.resize()Axi4SBuilder.startOfFrame()Axi4SBuilder.to_avalonSt()
- hwtLib.amba.axis_comp.cdc module
- hwtLib.amba.axis_comp.en module
- hwtLib.amba.axis_comp.fifo module
- hwtLib.amba.axis_comp.fifoCopy module
- hwtLib.amba.axis_comp.fifoDrop module
- hwtLib.amba.axis_comp.fifoFrameReversing module
- hwtLib.amba.axis_comp.fifoMeasuring module
- hwtLib.amba.axis_comp.fifo_async module
- hwtLib.amba.axis_comp.frameGen module
- hwtLib.amba.axis_comp.joinPrioritized module
- hwtLib.amba.axis_comp.reg module
- hwtLib.amba.axis_comp.resizer module
- hwtLib.amba.axis_comp.splitCopy module
- hwtLib.amba.axis_comp.splitSelect module
- hwtLib.amba.axis_comp.storedBurst module
- hwtLib.amba.axis_comp.strformat module
- hwtLib.amba.axis_comp.strformat_fn module
- Subpackages
- hwtLib.amba.datapump package
- Subpackages
- Submodules
- hwtLib.amba.datapump.base module
AxiDatapumpBaseAxiDatapumpBase.__annotations__AxiDatapumpBase.__init__()AxiDatapumpBase.addrAlign()AxiDatapumpBase.addrHandler()AxiDatapumpBase.addrIsAligned()AxiDatapumpBase.axiAddrDefaults()AxiDatapumpBase.encodeShiftValue()AxiDatapumpBase.getAxiLenMax()AxiDatapumpBase.getBurstAddrOffset()AxiDatapumpBase.getLen_t()AxiDatapumpBase.getShiftOptions()AxiDatapumpBase.getSizeAlignBits()AxiDatapumpBase.hasAlignmentError()AxiDatapumpBase.isAlwaysAligned()AxiDatapumpBase.isCrossingWordBoundary()AxiDatapumpBase.useTransSplitting()
- hwtLib.amba.datapump.intf module
- hwtLib.amba.datapump.r module
- hwtLib.amba.datapump.sim_ram module
- hwtLib.amba.datapump.utils module
- hwtLib.amba.datapump.w module
- hwtLib.amba.sim package
Submodules¶
hwtLib.amba.ace module¶
- class hwtLib.amba.ace.AR_MODE[source]¶
Bases:
object- class BARRIER[source]¶
Bases:
object- INNER = (1, 1, 0)¶
- NON = (1, 0, 0)¶
- OUTER = (1, 2, 0)¶
- SYSTEM = (1, 3, 0)¶
- class hwtLib.amba.ace.Ace(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi4https://static.docs.arm.com/ihi0022/d/IHI0022D_amba_axi_protocol_spec.pdf
- HDL params:
ADDR_WIDTH - default value 32 of type int
DATA_WIDTH - default value 64 of type int
ID_WIDTH - default value 6 of type int
ADDR_USER_WIDTH - default value 0 of type int
SNOOP_ADDR_WIDTH - default value 32 of type int
SNOOP_DATA_WIDTH - default value 32 of type int
- HDL IO:
ar - of type hwtLib.amba.ace.Ace_addr - UNKNOWN
r - of type hwtLib.amba.axi4.Axi4_r - UNKNOWN (Master=IN)
aw - of type hwtLib.amba.ace.Ace_addr - UNKNOWN
w - of type hwtLib.amba.axi4.Axi4_w - UNKNOWN
b - of type hwtLib.amba.axi4.Axi4_b - UNKNOWN (Master=IN)
ac - of type hwtLib.amba.ace.AceSnoop_addr - UNKNOWN (Master=IN) Coherent address channel. snoop address input to the master
cr - of type hwtLib.amba.ace.AceSnoop_resp - UNKNOWN Coherent response channel. used by the master to signal the response to snoops to the interconnect
cd - of type hwtLib.amba.ace.AceSnoop_data - UNKNOWN Coherent data channel. output from the master to transfer snoop data
- __annotations__ = {}¶
- class hwtLib.amba.ace.AceSnoop_addr(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs- HDL params:
SNOOP_ADDR_WIDTH - default value 32 of type int
- HDL IO:
addr - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
snoop - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
prot - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.ace.AceSnoop_data(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs- HDL params:
SNOOP_DATA_WIDTH - default value 32 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
last - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.ace.AceSnoop_resp(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs- HDL IO:
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.ace.Ace_addr(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi4_addr- HDL params:
ADDR_WIDTH - default value 32 of type int
ID_WIDTH - default value 6 of type int
USER_WIDTH - default value 0 of type int
- HDL IO:
addr - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
id - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 6bits> - UNKNOWN
burst - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
cache - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
len - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 8bits> - UNKNOWN
lock - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit, force_vector> - UNKNOWN
prot - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
size - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
qos - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
domain - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
region - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
snoop - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
bar - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.ace.BAR[source]¶
Bases:
object- BARRIER = 1¶
- IGNORE = 2¶
- NORMAL = 0¶
- SYNCHRONIZATION = 3¶
- class hwtLib.amba.ace.CACHE[source]¶
Bases:
object- DEVICE = 0¶
- NON_CACHEABLE = 3¶
- WRITE_BACK = 11¶
- WRITE_THROUGH = 7¶
hwtLib.amba.aceLite module¶
- class hwtLib.amba.aceLite.AceLite(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi4LiteAMBA ACE-lite interface
https://static.docs.arm.com/ihi0022/d/IHI0022D_amba_axi_protocol_spec.pdf
- HDL params:
ADDR_WIDTH - default value 32 of type int
DATA_WIDTH - default value 64 of type int
- HDL IO:
ar - of type hwtLib.amba.aceLite.AceLite_addr - UNKNOWN
r - of type hwtLib.amba.axi4Lite.Axi4Lite_r - UNKNOWN (Master=IN)
aw - of type hwtLib.amba.aceLite.AceLite_addr - UNKNOWN
w - of type hwtLib.amba.axi4Lite.Axi4Lite_w - UNKNOWN
b - of type hwtLib.amba.axi4Lite.Axi4Lite_b - UNKNOWN (Master=IN)
- AR_CLS¶
alias of
AceLite_addr
- AW_CLS¶
alias of
AceLite_addr
- __annotations__ = {}¶
- class hwtLib.amba.aceLite.AceLite_addr(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi4Lite_addr- HDL params:
ADDR_WIDTH - default value 32 of type int
- HDL IO:
addr - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
prot - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
domain - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
snoop - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
bar - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
- __annotations__ = {}¶
hwtLib.amba.axi3 module¶
- class hwtLib.amba.axi3.Axi3(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3LiteAMBA Axi3 bus interface
https://static.docs.arm.com/ihi0022/d/IHI0022D_amba_axi_protocol_spec.pdf
- HDL params:
ADDR_WIDTH - default value 32 of type int
DATA_WIDTH - default value 64 of type int
ID_WIDTH - default value 6 of type int
ADDR_USER_WIDTH - default value 0 of type int
- HDL IO:
ar - of type hwtLib.amba.axi3.Axi3_addr - UNKNOWN
r - of type hwtLib.amba.axi3.Axi3_r - UNKNOWN (Master=IN)
aw - of type hwtLib.amba.axi3.Axi3_addr - UNKNOWN
w - of type hwtLib.amba.axi3.Axi3_w - UNKNOWN
b - of type hwtLib.amba.axi3.Axi3_b - UNKNOWN (Master=IN)
- LEN_WIDTH = 4¶
- LOCK_WIDTH = 2¶
- __annotations__ = {}¶
- class hwtLib.amba.axi3.Axi3_addr(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3Lite_addr,Axi_idAxi3 address channel interface
- HDL params:
ADDR_WIDTH - default value 32 of type int
ID_WIDTH - default value 6 of type int
USER_WIDTH - default value 0 of type int
- HDL IO:
addr - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
id - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 6bits> - UNKNOWN
burst - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
cache - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
len - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
lock - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
prot - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
size - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
- LEN_WIDTH = 4¶
- LOCK_WIDTH = 2¶
- __annotations__ = {}¶
- class hwtLib.amba.axi3.Axi3_addrAgent(sim: HdlSimulator, hwIO: Axi3_addr, allowNoReset=False)[source]¶
Bases:
Axi4StreamAgentSimulation agent for
Axi3_addrinterfaceinput/output data stored in list under “data” property data contains tuples (id, addr, burst, cache, len, lock, prot, size, qos, optionally user)
- class hwtLib.amba.axi3.Axi3_b(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3Lite_b,Axi_idAxi3 write response channel interface
- HDL params:
ID_WIDTH - default value 0 of type int
- HDL IO:
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi3.Axi3_bAgent(sim: HdlSimulator, hwIO: HwIODataRdVld, allowNoReset=False)[source]¶
Bases:
BaseAxiAgentSimulation agent for
Axi3_binterfaceinput/output data stored in list under “data” property data contains tuples (id, resp)
- __annotations__ = {}¶
- class hwtLib.amba.axi3.Axi3_r(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3Lite_r,Axi_idAxi 3 read channel interface
- HDL params:
ID_WIDTH - default value 6 of type int
DATA_WIDTH - default value 64 of type int
- HDL IO:
id - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 6bits> - UNKNOWN
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
last - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi3.Axi3_rAgent(sim: HdlSimulator, hwIO: HwIODataRdVld, allowNoReset=False)[source]¶
Bases:
BaseAxiAgentSimulation agent for
Axi4_rinterfaceinput/output data stored in list under “data” property data contains tuples (id, data, resp, last)
- __annotations__ = {}¶
- class hwtLib.amba.axi3.Axi3_w(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
-
Axi3 write channel interface (simplified Axi4Stream)
- HDL params:
ID_WIDTH - default value 0 of type int
DATA_WIDTH - default value 64 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
strb - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 8bits> - UNKNOWN
last - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
hwtLib.amba.axi3Lite module¶
- class hwtLib.amba.axi3Lite.Axi3Lite(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
HwIOAMBA AXI3-lite interface
https://static.docs.arm.com/ihi0022/d/IHI0022D_amba_axi_protocol_spec.pdf
- HDL params:
ADDR_WIDTH - default value 32 of type int
DATA_WIDTH - default value 64 of type int
- HDL IO:
ar - of type hwtLib.amba.axi3Lite.Axi3Lite_addr - UNKNOWN
r - of type hwtLib.amba.axi3Lite.Axi3Lite_r - UNKNOWN (Master=IN)
aw - of type hwtLib.amba.axi3Lite.Axi3Lite_addr - UNKNOWN
w - of type hwtLib.amba.axi3Lite.Axi3Lite_w - UNKNOWN
b - of type hwtLib.amba.axi3Lite.Axi3Lite_b - UNKNOWN (Master=IN)
- AR_CLS¶
alias of
Axi3Lite_addr
- AW_CLS¶
alias of
Axi3Lite_addr
- B_CLS¶
alias of
Axi3Lite_b
- LEN_WIDTH = 0¶
- R_CLS¶
alias of
Axi3Lite_r
- W_CLS¶
alias of
Axi3Lite_w
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3LiteAgent(sim: HdlSimulator, hwIO)[source]¶
Bases:
AgentBaseComposite simulation agent with agent for every axi channel change of enable is propagated to each child
data for each agent is stored in agent for given channel (ar, aw, r, … property)
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3Lite_addr(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs- HDL params:
ADDR_WIDTH - default value 32 of type int
- HDL IO:
addr - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3Lite_addrAgent(sim: HdlSimulator, hwIO: HwIODataRdVld, allowNoReset=False)[source]¶
Bases:
BaseAxiAgent- Variables:
~.data – iterable of addr
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3Lite_b(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs- HDL IO:
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3Lite_bAgent(sim: HdlSimulator, hwIO: HwIODataRdVld, allowNoReset=False)[source]¶
Bases:
BaseAxiAgent- Variables:
~.data – iterable of resp
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3Lite_r(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs- HDL params:
DATA_WIDTH - default value 64 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3Lite_w(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs- HDL params:
DATA_WIDTH - default value 64 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
strb - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 8bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.Axi3Lite_wAgent(sim: HdlSimulator, hwIO: HwIODataRdVld, allowNoReset=False)[source]¶
Bases:
BaseAxiAgent- Variables:
~.data – iterable of tuples (data, strb)
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.AxiLite_rAgent(sim: HdlSimulator, hwIO: HwIODataRdVld, allowNoReset=False)[source]¶
Bases:
BaseAxiAgent- Variables:
~.data – iterable of tuples (data, resp)
- __annotations__ = {}¶
- class hwtLib.amba.axi3Lite.IP_Axi3Lite[source]¶
Bases:
IntfIpMeta- __annotations__ = {}¶
- asQuartusTcl(buff: List[str], version: str, component: Component, packager: IpPackager, thisIf: HwIO)[source]¶
Add interface to Quartus tcl
- Parameters:
buff – line buffer for output
version – Quartus version
intfName – name of top interface
component – component object from ipcore generator
packager – instance of IpPackager which is packaging current design
allInterfaces – list of all interfaces of top unit
thisIf – interface to add into Quartus TCL
- library¶
- name¶
- vendor¶
- version¶
hwtLib.amba.axi4 module¶
- class hwtLib.amba.axi4.Axi4(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3AMBA AXI4 bus interface https://static.docs.arm.com/ihi0022/d/IHI0022D_amba_axi_protocol_spec.pdf
- Variables:
~.ar – read address channel
~.r – read data channel
~.aw – write address channel
~.w – write data channel
~.b – write acknowledge channel
- HDL params:
ADDR_WIDTH - default value 32 of type int
DATA_WIDTH - default value 64 of type int
ID_WIDTH - default value 6 of type int
ADDR_USER_WIDTH - default value 0 of type int
- HDL IO:
ar - of type hwtLib.amba.axi4.Axi4_addr - UNKNOWN
r - of type hwtLib.amba.axi4.Axi4_r - UNKNOWN (Master=IN)
aw - of type hwtLib.amba.axi4.Axi4_addr - UNKNOWN
w - of type hwtLib.amba.axi4.Axi4_w - UNKNOWN
b - of type hwtLib.amba.axi4.Axi4_b - UNKNOWN (Master=IN)
- LEN_WIDTH = 8¶
- LOCK_WIDTH = 1¶
- __annotations__ = {}¶
- class hwtLib.amba.axi4.Axi4_addr(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3_addrAxi4 address channel interface (axi3 address channel with different size of len and lock signals and additional qos signal)
- HDL params:
ADDR_WIDTH - default value 32 of type int
ID_WIDTH - default value 6 of type int
USER_WIDTH - default value 0 of type int
- HDL IO:
addr - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
id - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 6bits> - UNKNOWN
burst - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
cache - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
len - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 8bits> - UNKNOWN
lock - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit, force_vector> - UNKNOWN
prot - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
size - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
qos - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 4bits> - UNKNOWN
- LEN_WIDTH = 8¶
- LOCK_WIDTH = 1¶
- __annotations__ = {}¶
- class hwtLib.amba.axi4.Axi4_addrAgent(sim: HdlSimulator, hwIO: Axi3_addr, allowNoReset=False)[source]¶
Bases:
Axi4StreamAgent- __annotations__ = {}¶
- class hwtLib.amba.axi4.Axi4_b(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3_bAxi4 write response channel interface (same as
Axi3_b)- HDL params:
ID_WIDTH - default value 0 of type int
- HDL IO:
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi4.Axi4_r(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3_rAxi4 read channel interface (same as r
Axi3_r)- HDL params:
ID_WIDTH - default value 6 of type int
DATA_WIDTH - default value 64 of type int
- HDL IO:
id - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 6bits> - UNKNOWN
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
last - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi4.Axi4_w(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
-
Axi4 write channel interface (
Axi3_wwithout id signal)- HDL params:
DATA_WIDTH - default value 64 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
strb - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 8bits> - UNKNOWN
last - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
hwtLib.amba.axi4Lite module¶
- class hwtLib.amba.axi4Lite.Axi4Lite(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3LiteAxi4-lite bus interface (Same as
Axi3Litejust address channels do have “prot” signal)- HDL params:
ADDR_WIDTH - default value 32 of type int
DATA_WIDTH - default value 64 of type int
- HDL IO:
ar - of type hwtLib.amba.axi4Lite.Axi4Lite_addr - UNKNOWN
r - of type hwtLib.amba.axi4Lite.Axi4Lite_r - UNKNOWN (Master=IN)
aw - of type hwtLib.amba.axi4Lite.Axi4Lite_addr - UNKNOWN
w - of type hwtLib.amba.axi4Lite.Axi4Lite_w - UNKNOWN
b - of type hwtLib.amba.axi4Lite.Axi4Lite_b - UNKNOWN (Master=IN)
- AR_CLS¶
alias of
Axi4Lite_addr
- AW_CLS¶
alias of
Axi4Lite_addr
- B_CLS¶
alias of
Axi4Lite_b
- R_CLS¶
alias of
Axi4Lite_r
- W_CLS¶
alias of
Axi4Lite_w
- __annotations__ = {}¶
- class hwtLib.amba.axi4Lite.Axi4Lite_addr(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3Lite_addrAxi3Lite_addrwith “prot” signal added.- HDL params:
ADDR_WIDTH - default value 32 of type int
- HDL IO:
addr - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 32bits> - UNKNOWN
prot - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 3bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi4Lite.Axi4Lite_addrAgent(sim: HdlSimulator, hwIO: HwIODataRdVld, allowNoReset=False)[source]¶
Bases:
Axi3Lite_addrAgent- Variables:
~.data – iterable of addr
- __annotations__ = {}¶
- class hwtLib.amba.axi4Lite.Axi4Lite_b(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3Lite_b(Same as
Axi3Lite_b)- HDL IO:
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi4Lite.Axi4Lite_r(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3Lite_r(Same as
Axi3Lite_r)- HDL params:
DATA_WIDTH - default value 64 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
resp - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 2bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi4Lite.Axi4Lite_w(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi3Lite_w(Same as
Axi3Lite_w)- HDL params:
DATA_WIDTH - default value 64 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
strb - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 8bits> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
hwtLib.amba.axi4SSegmented module¶
- class hwtLib.amba.axi4SSegmented.Axi4StreamSegmented(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
-
Xilinx/AMD Segmented Axi4Stream interface used for 100G+ Ethernet https://docs.amd.com/r/1.3-English/pg314-versal-mrmac/Segmented-Mode?tocId=bPOyhICzaCLnbaKgrT0K4g
- Variables:
~.SEGMENT_CNT – number of segments of the bus
~.SEGMENT_DATA_WIDTH – width of 1 segment of data signal
~.ERROR_WIDTH – width of 1 segment of “err” signal (can be 0)
~.SUPPORT_ZLP – if True “empty” signal 1b is wider and Zero Length Packets are supported
~.USE_SOF – if True sof is present in user struct, sof + enable potentially allows for sparse streams (frame continuing in not directly consequent segment)
Typical configuration for Ethernet:
Ethernet DATA_WIDTH SEGMENT_CNT Frequency[MHz] ======== ========== =========== ============== 40G 128 1 312.5 [0] 50G 256 2 195.3125 [0] 100G 384 3 260.5 [0] 100G 512 1 390.625 [2] 400G 1024 8 390.625 [3] 600G 1536 12 390.625 [3]
[0] https://www.xilinx.com/content/dam/xilinx/publications/presentations/xilinx_network_security_offerings.pdf [1] https://www.intel.com/content/www/us/en/docs/programmable/773413.html [2] https://cdrdv2.intel.com/v1/dl/getContent/827074?fileName=ug20085-683100-827074.pdf [3] https://docs.amd.com/r/en-US/pg369-dcmac
- HDL params:
SEGMENT_CNT - default value 4 of type int
SEGMENT_DATA_WIDTH - default value 64 of type int
BYTE_WIDTH - default value 8 of type int
SUPPORT_ZLP - default value False of type bool
USE_SOF - default value False of type bool
ERROR_WIDTH - default value 0 of type int
PACK_SEGMENT_BITS - default value False of type bool
- HDL IO:
data - of type hwt.hwIOs.hwIOArray.HwIOArray - UNKNOWN
user - of type hwt.hwIOs.hwIOArray.HwIOArray - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- classmethod getEffectiveThroughput(CLK_FREQ: float | int, SEGMENT_CNT: int, DATA_WIDTH: int, PACKET_WIDTH: int)[source]¶
- classmethod getMinNumberOfSegments(BITRATE: float | int, DATA_WIDTH: int, CLK_FREQ: float, MIN_PACKET_WIDTH: int)[source]¶
- Parameters:
MIN_PACKET_WIDTH – the width of most waistful packet, e.g. (64 + 1) * 8b for ethernet
- unpackSegment(segmentIndex: int, v=None) tuple[HBitsRtlSignal | HBitsConst, Axi4StreamSegmentedMockSegmentUserTy][source]¶
- class hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedAgent(sim: HdlSimulator, hwIO: Axi4StreamSegmented, allowNoReset=False)[source]¶
Bases:
BaseAxiAgent,UniversalRdVldSyncAgentSimulation agent for
Axi4StreamSegmentedinterfaceinput/output data stored in list under “data” property data contains tuples
- __annotations__ = {}¶
- __init__(sim: HdlSimulator, hwIO: Axi4StreamSegmented, allowNoReset=False)[source]¶
- Parameters:
rst – tuple (rst signal, rst_negated flag)
- set_data(dataWord: tuple[tuple[HBitsConst, HConst], ...])[source]¶
- Parameters:
dataWord – tuple of segments
- class hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedMockSegmentTy(data: HBitsRtlSignal | HBitsConst, user: Axi4StreamSegmentedMockSegmentUserTy)[source]¶
Bases:
objectMock type to keep python typed for dynamically generated HdlType for Axi4StreamSegmented segment
- __annotations__ = {'data': typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst')], 'user': <class 'hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedMockSegmentUserTy'>}¶
- __dataclass_fields__ = {'data': Field(name='data',type=typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst')],default=<dataclasses._MISSING_TYPE object>,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD), 'user': Field(name='user',type=<class 'hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedMockSegmentUserTy'>,default=<dataclasses._MISSING_TYPE object>,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD)}¶
- __dataclass_params__ = _DataclassParams(init=True,repr=True,eq=True,order=False,unsafe_hash=False,frozen=False,match_args=True,kw_only=False,slots=False,weakref_slot=False)¶
- __eq__(other)¶
Return self==value.
- __hash__ = None¶
- __init__(data: HBitsRtlSignal | HBitsConst, user: Axi4StreamSegmentedMockSegmentUserTy) None¶
- __match_args__ = ('data', 'user')¶
- __repr__()¶
Return repr(self).
- data: HBitsRtlSignal | HBitsConst¶
- class hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedMockSegmentUserTy(enable: HBitsRtlSignal | HBitsConst | None = None, sof: HBitsRtlSignal | HBitsConst | None = None, eof: HBitsRtlSignal | HBitsConst | None = None, err: HBitsRtlSignal | HBitsConst | None = None, empty: HBitsRtlSignal | HBitsConst | None = None)[source]¶
Bases:
objectMock type to keep python typed for dynamically generated HdlType for Axi4StreamSegmented segment user :attention: in real HStructConst the property is never None, but instead it is not presetnt
- __annotations__ = {'empty': typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType], 'enable': typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType], 'eof': typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType], 'err': typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType], 'sof': typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType]}¶
- __dataclass_fields__ = {'empty': Field(name='empty',type=typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType],default=None,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD), 'enable': Field(name='enable',type=typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType],default=None,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD), 'eof': Field(name='eof',type=typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType],default=None,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD), 'err': Field(name='err',type=typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType],default=None,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD), 'sof': Field(name='sof',type=typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst'), NoneType],default=None,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD)}¶
- __dataclass_params__ = _DataclassParams(init=True,repr=True,eq=True,order=False,unsafe_hash=False,frozen=False,match_args=True,kw_only=False,slots=False,weakref_slot=False)¶
- __eq__(other)¶
Return self==value.
- __hash__ = None¶
- __init__(enable: HBitsRtlSignal | HBitsConst | None = None, sof: HBitsRtlSignal | HBitsConst | None = None, eof: HBitsRtlSignal | HBitsConst | None = None, err: HBitsRtlSignal | HBitsConst | None = None, empty: HBitsRtlSignal | HBitsConst | None = None) None¶
- __match_args__ = ('enable', 'sof', 'eof', 'err', 'empty')¶
- __repr__()¶
Return repr(self).
- empty: HBitsRtlSignal | HBitsConst | None = None¶
- enable: HBitsRtlSignal | HBitsConst | None = None¶
- eof: HBitsRtlSignal | HBitsConst | None = None¶
- err: HBitsRtlSignal | HBitsConst | None = None¶
- sof: HBitsRtlSignal | HBitsConst | None = None¶
- class hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedMockWordNoPackTy(data: list[HBitsRtlSignal | HBitsConst], user: list[Axi4StreamSegmentedMockSegmentUserTy])[source]¶
Bases:
objectMock type to keep python typed for dynamically generated HdlType for Axi4StreamSegmented segment
- __annotations__ = {'data': list[typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst')]], 'user': list[hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedMockSegmentUserTy]}¶
- __dataclass_fields__ = {'data': Field(name='data',type=list[typing.Union[ForwardRef('HBitsRtlSignal'), ForwardRef('HBitsConst')]],default=<dataclasses._MISSING_TYPE object>,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD), 'user': Field(name='user',type=list[hwtLib.amba.axi4SSegmented.Axi4StreamSegmentedMockSegmentUserTy],default=<dataclasses._MISSING_TYPE object>,default_factory=<dataclasses._MISSING_TYPE object>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=False,_field_type=_FIELD)}¶
- __dataclass_params__ = _DataclassParams(init=True,repr=True,eq=True,order=False,unsafe_hash=False,frozen=False,match_args=True,kw_only=False,slots=False,weakref_slot=False)¶
- __eq__(other)¶
Return self==value.
- __hash__ = None¶
- __init__(data: list[HBitsRtlSignal | HBitsConst], user: list[Axi4StreamSegmentedMockSegmentUserTy]) None¶
- __match_args__ = ('data', 'user')¶
- __repr__()¶
Return repr(self).
- data: list[HBitsRtlSignal | HBitsConst]¶
- user: list[Axi4StreamSegmentedMockSegmentUserTy]¶
- class hwtLib.amba.axi4SSegmented._Axi4StreamSegmentedWord(segmentWords: tuple[Deque[HBitsConst], Deque[HConst]], SEGMENT_CNT: int)[source]¶
Bases:
object- Variables:
segmentWords – word of data and control signals encoded in user signal for a single segment
- __init__(segmentWords: tuple[Deque[HBitsConst], Deque[HConst]], SEGMENT_CNT: int)[source]¶
- classmethod popSegmentWordFromAgentData(ag_data: Deque[tuple[HBitsConst, HConst]], SEGMENT_CNT: int) Self[source]¶
hwtLib.amba.axi4SSegmentedSimFrameUtils module¶
- class hwtLib.amba.axi4SSegmentedSimFrameUtils.Axi4StreamSegmentedFrameUtils(SEGMENT_DATA_WIDTH: int, SEGMENT_CNT: int, USER_SEGMENT_T: HStruct, BYTE_WIDTH: int = 8, SUPPORT_ZLP: bool = False, USE_SOF: bool = False, ERROR_WIDTH: int = 0, PACK_SEGMENT_BITS: bool = False)[source]¶
Bases:
SimFrameUtils[tuple[tuple[HBitsConst,HConst], …]]- __annotations__ = {}¶
- __init__(SEGMENT_DATA_WIDTH: int, SEGMENT_CNT: int, USER_SEGMENT_T: HStruct, BYTE_WIDTH: int = 8, SUPPORT_ZLP: bool = False, USE_SOF: bool = False, ERROR_WIDTH: int = 0, PACK_SEGMENT_BITS: bool = False)[source]¶
- __orig_bases__ = (hwtLib.abstract.simFrameUtils.SimFrameUtils[tuple[tuple[hwt.hdl.types.bitsConst.HBitsConst, hwt.hdl.const.HConst], ...]],)¶
- __parameters__ = ()¶
- concatWordBits(frameBeats: Sequence[tuple[tuple[HBitsConst, HConst], ...]])[source]¶
Convert word tuple (produced by
send_bytes()andpack_frame()) to flatHBitsConst(members of input tuple are typically ints so they need to be cast to correct type first)
- classmethod from_HwIO(axiss: Axi4StreamSegmented) Self[source]¶
Create a an instance of self configured for specified hwio instance
- pack_frame(frameVal: HConst | Sequence[int]) Generator[tuple[tuple[HBitsConst, HConst], ...], None, None][source]¶
pack data of structure into words on Axi4StreamSegmented interface
- Parameters:
frameVal – value to be send, HConst instance or list of int for each byte
- Returns:
generator of tuples tuples (data, USER_SEGMENT_T)
- receive_bytes(ag_data: Deque[tuple[tuple[HBitsConst, HConst], ...]]) tuple[int, list[int | HBitsConst], bool][source]¶
- Parameters:
ag_data – list of axi stream segmented words, number of item in tuple depends on use_keep and use_id
- Returns:
tuple (startSegmentIndex, data bytes, had error flag)
- send_bytes(data_B: bytes | list[int], ag_data: Deque[tuple[tuple[HBitsConst, HConst], ...]], offset: int = 0) list[tuple[tuple[HBitsConst, HConst], ...]][source]¶
Build frame out of data_B bytes and insert it into ag_data deque which is expected to be a queue of driver sim agent
hwtLib.amba.axi4s module¶
- class hwtLib.amba.axi4s.Axi4Stream(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
Axi_hs,Axi_id,Axi_user,Axi_strbAMBA AXI-stream interface https://static.docs.arm.com/ihi0051/a/IHI0051A_amba4_axi4_stream_v1_0_protocol_spec.pdf
- Variables:
~.IS_BIGENDIAN – HwParam which specifies if interface uses bigendian byte order or little-endian byte order
~.DATA_WIDTH – HwParam which specifies width of data signal
~.HAS_STRB – if set strb signal is present
~.HAS_KEEP – if set keep signal is present
~.ID_WIDTH – if > 0 id signal is present and this is it’s width
~.DEST_WIDTH – if > 0 dest signal is present and this is it’s width
~.id – optional signal wich specifies id of transaction
~.dest – optional signal which specifies destination of transaction
~.data – main data signal
~.keep – optional signal which signalize which bytes should be keept and which should be discarded
~.strb – optional signal which signalize which bytes are valid
~.last – signal which if high this data is last in this frame
~.user – optional signal which can be used for arbitrary purposes
- HDL params:
IS_BIGENDIAN - default value False of type bool
USE_STRB - default value False of type bool
USE_KEEP - default value False of type bool
ID_WIDTH - default value 0 of type int
DEST_WIDTH - default value 0 of type int
DATA_WIDTH - default value 64 of type int
USER_WIDTH - default value 0 of type int
- HDL IO:
data - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 64bits> - UNKNOWN
last - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi4s.Axi4StreamAgent(sim: HdlSimulator, hwIO: Axi4Stream, allowNoReset=False)[source]¶
Bases:
BaseAxiAgent,UniversalRdVldSyncAgentSimulation agent for
Axi4Streaminterfaceinput/output data stored in list under “data” property data contains tuples
Format of data tuples is derived from signals on Axi4Stream interface Order of values corresponds to definition of interface signals. If all signals are present format of tuple will be (id, dest, data, strb, keep, user, last)
- __annotations__ = {}¶
- __init__(sim: HdlSimulator, hwIO: Axi4Stream, allowNoReset=False)[source]¶
- Parameters:
rst – tuple (rst signal, rst_negated flag)
hwtLib.amba.axi4sSimFrameUtils module¶
- class hwtLib.amba.axi4sSimFrameUtils.Axi4StreamSimFrameUtils(DATA_WIDTH: int, USE_STRB=False, USE_KEEP=False, USE_ID=False, BYTE_WIDTH=8)[source]¶
Bases:
SimFrameUtils[tuple[HBitsConst,HBitsConst,HBitsConst,HBitsConst] |tuple[HBitsConst,HBitsConst,HBitsConst] |tuple[HBitsConst,HBitsConst]]- __annotations__ = {}¶
- __orig_bases__ = (hwtLib.abstract.simFrameUtils.SimFrameUtils[typing.Union[tuple[hwt.hdl.types.bitsConst.HBitsConst, hwt.hdl.types.bitsConst.HBitsConst, hwt.hdl.types.bitsConst.HBitsConst, hwt.hdl.types.bitsConst.HBitsConst], tuple[hwt.hdl.types.bitsConst.HBitsConst, hwt.hdl.types.bitsConst.HBitsConst, hwt.hdl.types.bitsConst.HBitsConst], tuple[hwt.hdl.types.bitsConst.HBitsConst, hwt.hdl.types.bitsConst.HBitsConst]]],)¶
- __parameters__ = ()¶
- concatWordBits(frameBeats: Sequence[tuple[HBitsConst, HBitsConst, HBitsConst, HBitsConst] | tuple[HBitsConst, HBitsConst, HBitsConst] | tuple[HBitsConst, HBitsConst]])[source]¶
Convert word tuple (produced by
send_bytes()andpack_frame()) to flatHBitsConst(members of input tuple are typically ints so they need to be cast to correct type first)
- classmethod from_HwIO(axis: Axi4Stream)[source]¶
Create a an instance of self configured for specified hwio instance
- pack_frame(frameVal: HConst | Sequence[int]) Generator[tuple[HBitsConst, HBitsConst, HBitsConst, HBitsConst] | tuple[HBitsConst, HBitsConst, HBitsConst] | tuple[HBitsConst, HBitsConst], None, None][source]¶
pack data of structure into words on axis interface Words are tuples (data, last) or (data, mask, last) depending on args.
- Parameters:
frameVal – value to be send, HConst instance or list of int for each byte
- Returns:
generator of tuples (data, strb, isLast), strb is omitted if withStrb=False
- receive_bytes(ag_data: Deque[tuple[HBitsConst, HBitsConst, HBitsConst, HBitsConst] | tuple[HBitsConst, HBitsConst, HBitsConst] | tuple[HBitsConst, HBitsConst]]) tuple[int, list[int]][source]¶
- Parameters:
ag_data – list of axi stream words, number of item in tuple depends on use_keep and use_id
- updackWordBits(v: HBitsConst)[source]¶
opposite of concatWordBits
- hwtLib.amba.axi4sSimFrameUtils.axi4s_mask_propagate_best_effort(src: Axi4Stream, dst: Axi4Stream)[source]¶
- hwtLib.amba.axi4sSimFrameUtils.axi4s_receive_bytes(axis: Axi4Stream) tuple[int, list[int]][source]¶
Read data from AXI Stream agent in simulation and use keep signal to mask out unused bytes
- hwtLib.amba.axi4sSimFrameUtils.axi4s_send_bytes(axis: Axi4Stream, data_B: list[int] | bytes, offset=0) None[source]¶
- Parameters:
axis – Axi4Stream master which is driver from the simulation
data_B – bytes to send
offset – number of empty bytes which should be added before data in frame (and use keep signal to mark such a bytes)
hwtLib.amba.axi4s_fullduplex module¶
- class hwtLib.amba.axi4s_fullduplex.Axi4StreamFullDuplex(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
HwIO- HDL params:
IS_BIGENDIAN - default value False of type bool
USE_STRB - default value False of type bool
USE_KEEP - default value False of type bool
ID_WIDTH - default value 0 of type int
DEST_WIDTH - default value 0 of type int
DATA_WIDTH - default value 64 of type int
USER_WIDTH - default value 0 of type int
HAS_RX - default value True of type bool
HAS_TX - default value True of type bool
- HDL IO:
tx - of type hwtLib.amba.axi4s.Axi4Stream - UNKNOWN
rx - of type hwtLib.amba.axi4s.Axi4Stream - UNKNOWN (Master=IN)
- __annotations__ = {}¶
- class hwtLib.amba.axi4s_fullduplex.Axi4StreamFullDuplexAgent(sim: HdlSimulator, hwIO: Axi4StreamFullDuplex)[source]¶
Bases:
AgentBase- __annotations__ = {}¶
- __init__(sim: HdlSimulator, hwIO: Axi4StreamFullDuplex)[source]¶
hwtLib.amba.axi_common module¶
- class hwtLib.amba.axi_common.Axi_hs(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
HwIORdVldSyncAXI handshake interface with ready and valid signal (same as HwIORdVldSync just vld is valid and rd is ready) transaction happens when both ready and valid are high
- Variables:
~.ready – when high slave is ready to receive data
~.valid – when high master is sending data to slave
- HDL IO:
ready - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN (Master=IN)
valid - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 1bit> - UNKNOWN
- __annotations__ = {}¶
- class hwtLib.amba.axi_common.Axi_id(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
HwIO- HDL params:
ID_WIDTH - default value 0 of type int
- __annotations__ = {}¶
- class hwtLib.amba.axi_common.Axi_strb(masterDir=DIRECTION.OUT, hdlName: str | dict[str, str] | None = None, loadConfig=True)[source]¶
Bases:
HwIO- HDL params:
DATA_WIDTH - default value 64 of type int
- HDL IO:
strb - of type hwt.hwIOs.std.HwIOSignal with dtype=<HBits, 8bits> - UNKNOWN
- __annotations__ = {}¶
hwtLib.amba.constants module¶
Constant used for a signals in AXI, AXI-lite interfaces.
https://static.docs.arm.com/ihi0022/d/IHI0022D_amba_axi_protocol_spec.pdf
- hwtLib.amba.constants.CACHE_DEFAULT = 3¶
ARCACHE[3:0]
AWCACHE[3:0]
Memory type
0000
0000
Device Non-bufferable
0001
0001
Device Bufferable
0010
0010
Normal Non-cacheable Non-bufferable
0011
0011
Normal Non-cacheable Bufferable
1010
0110
Write-through No-allocate
1110 (0110)
0110
Write-through Read-allocate
1010
1110 (1010)
Write-through Write-allocate
1110
1110
Write-through Read and Write-allocate
1011
0111
Write-back No-allocate
1111 (0111)
0111
Write-back Read-allocate
1011
1111 (1011)
Write-back Write-allocate
1111
1111
Write-back Read and Write-allocate
- hwtLib.amba.constants.LOCK_DEFAULT = 0¶
RESP
Response
Description
0b00
OKAY
Normal access success
0b01
EXOKAY
Exclusive access success
0b10
SLVERR
Slave error
0b11
DECERR
Decode error
- hwtLib.amba.constants.PROT_DEFAULT = 0¶
- Note:
“prot” is an access permissions signals that can be used to protect against illegal transactions.
PROT
Value
Function
[0]
0
Unprivileged access
1
Privileged access
[1]
0
Secure access
1
Non-secure access
[2]
0
Data access
1
Instruction access