在QuestaSIM用戶手冊版本10.5A它是336頁指出:如何在AMS中將多個對象類型驅動到網上?
In the most recent SystemVerilog standard (Std IEEE 1800-2012), two important concepts were established:
User-Defined Nettype (UDN) — UDN allows a definition of a net type that can carry arbitrarily complex data using a built-in type (such as real) or a user-defined type (such as struct). Consequently, UDN is a generalization of the wreal net type from Verilog-AMS. In order to allow connectivity of models that rely on UDNs, a more generic connectivity mechanism is needed—the interconnect object.
但他們真的不指定UDN是如何構建的。 'nettype'和'interconnect'的語法似乎與這個描述非常接近,但都不能滿足它 - 我不能分配互連,而且我無法將自己的類型與nettype一起使用。我正在創建一個模型,需要將用戶定義的對象驅動到規範中定義的UDN上。
module SomeModel(output nettype ObjectContainingProperties outputToInterconnect);
class ObjectContainingProperties;
endclass
ObjectContainingProperties ocp;
assign outputToInterconnect=ocp;
initial begin
ocp=new();
end
endmodule
,但我得到的錯誤:
QuestaSim-64 vlog 10.5a Compiler 2016.04 Apr 4 2016
Start time: 18:55:05 on Dec 19,2016
vlog -ams -wireasinterconnect SomeModel.sv
-- Compiling module SomeModel
** Error: (vlog-13069) SomeModel.sv(11): near "nettype": syntax error, unexpected nettype, expecting IDENTIFIER.
如何創建和附加一個對象到UDN - 什麼是語法?或者我如何可靠地將不同類型的物體驅動到網絡上?
您引用的文本不是IEEE 1800-2012標準。你看過_6.6.7用戶定義的nettypes_中的例子嗎? –
我在編輯時不小心剪掉了問題的頂部。我不確定它是否值得爲此付出代價,我糾正了它。 – Joe
做喲有IEEE 1800-2012手冊嗎? –