>我写了一个vhdl程序来写和读内存。
我成功了。
实际上,您创建了VHDL设计。
您没有创建正在创建硬件设计的“程序”。
>然后我将这个vhdl文件作为组件添加到另一个verilog程序中。
实际上,您在另一个Verilog设计中将VHDL设计添加为组件或子模块。
>我
试图使用地址和数据线访问the vhdl组件。
您正在创建硬件而不是软件,因此您无法访问先前创建的VHDL读/写内存设计。
Verilog设计将通过为地址,数据和时钟提供必要的硬件信号来控制VHDL设计,并使用Verilog设计其他部分的数据输出作为回报。
>但是
在合成期间,它显示数据信号上的多源的错误。
虽然这个数据信号是
>正在进行vhdl程序的输出
仅用作输入。
当合成器报告网络有多个源时,意味着您的HDL中有两个点正在尝试更改网络状态。
您需要重新检查HDL源以确定发生的位置。
我的猜测是,这是因为你正在尝试做一些在实际设计中不实用的东西。
回到这个线程的开头,你说你想要一个可以从设计中的许多地方访问的单个二维存储器阵列。
这个概念适用于在CPU上运行的软件,但您不是在设计正在设计硬件的软件。
您正在创建的硬件同时运行所有电路,而软件按顺序运行每个指令。
如果您有10个模块,每个模块都想要读取或写入内存阵列,那么这意味着您需要一个10端口内存。
在FPGA中创建10端口存储器是不实际的,但如果需要可以完成。
您需要创建一个内存模块,其中包含10个端口,每个端口都带有地址,data_in,data_out和读/写,以便执行此操作。
>这个问题是由于verilog和vhdl的混合造成的。
不,是因为你的设计错了。
------您是否尝试在Google中输入问题?
如果没有,你应该在发布之前。太多结果?
尝试添加网站:www.xilinx.com
以上来自于谷歌翻译
以下为原文
> I wrote a vhdl programme to write and read memory. I did it successfully.
Actually, you created a VHDL design. You are not creating "programs" you are creating a hardware design.
> Then I added this vhdl file as a component to another verilog program.
Actually, you added the VHDL design as a component or sub-module in another Verilog design.
> I tried to acces theis vhdl component using address and data lines.
You are creating hardware and not software, so you are not accessing the VHDL read/write memory design that you created earlier. The Verilog design would be controlling the VHDL design by providing the necessary hardware signals for address, data and clock and in return using the data output in other parts of the Verilog design.
> But during synthesis it displayed error of multisourcing on the data signal. Though this data signal is
> output of the vhdl programme and is being used as an input only.
When the synthesizer reports that a net has multiple sources it means that you have two points in your HDL that are trying to change the state of the net. You will need to re-examine your HDL source to determine where this occuring.
My guess is that this is occuring because you are trying to do something that is not practical in a real design. Way back at the beginning of this thread you stated that you wanted to have a single two dimensional memory array that can be accessed from many places within the design. This concept works with software running on a CPU, but you are not designing software you are designing hardware.
The hardware that you are creating runs everything circuit at the same time time, while software runs each instruction sequentially. If you have 10 modules that each want to read or write the memory array then that means that you need a 10 port memory. Creating a 10 port memory is not practical in an FPGA, but can be done if needed. You will need to create a memory module that has 10 ports each with address, data_in, data_out and read/write in order to do this.
> Is this problem due to the mixing of verilog and vhdl.
No it is because your design is wrong.
------Have you tried typing your question into Google? If not you should before posting.
Too many results? Try adding site:www.xilinx.com