- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi all,
I am new in verilog and quartus.. I have a module that is successful compile but the logic elements is indicated to be zero used. The register and net inside my module is found to be undefined in vector waveform when i run simulation.... Any idea what's wrong with my code?? mixcolumn_en.v will be my top-level Regards VinzLink Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm not a Verilog specialist, but I think that you should have at least have your last always block in your top level file to be triggered by a clock edge. I don't know how your code would be synthesized, but it probably won't do what you expect... If Quartus finds out that your outputs never change, it will just optimize the design by removing everything.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have tried clock edge in my top level. The problem still exist. I not familiar with hardware language as I use to do software programming. Hence I not sure whether i do it in the right way. But anyway thanks for your advice...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
--- Quote Start --- I not familiar with hardware language --- Quote End --- Yes, it's pretty obvious when seeing your code. I guess you'll need a tutorial or textbook. The below construct makes all datax variables undefined and can already explain, why you don't get any output from the design. N is simply ignored, so the code means to put the four signals in a logic chain. The meaningless construct will be discarded by a design compiler.
always @(N)
begin
data1<=data2;
data2<=data3;
data3<=data4;
data4<=data1;
end
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If I understand correctly what you are trying to do, those statements should be in your last always block, triggered by a clock edge.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I have met the same problem, trying to implement a CAN IP core, I built a project which contains only the core, the compilation is good but with 0 logic element used... I'm pretty sure about the verilog code (stable version downloaded from OpenCores and modelsim verified). So what kind of problem can lead to this problem, Can anyone help me ? Thanks a lot.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Quartus optimises your component away, most probably because it determined that an empty FPGA would do exactly the same thing that what you described. That is usually the case if the core you inserted doesn't drive any output pins, doesn't depend on any input pin and/or is kept in a constant state (kept in reset, for example, or with no clock input).
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page