Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
21587 Discussions

Gates are not appeared in RTL viewer

Altera_Forum
Honored Contributor II
1,865 Views

Hey all, 

 

I wrote the next code: 

 

module increase_duration_1(in, clk, out, reset); 

parameter LEN=10; 

input in,clk, reset; 

output out; 

wire [LEN-1:0] or_out,path; 

wire rstn; 

or U2(or_out[0],path[0],path[1]); 

assign out=path[LEN-1]; 

assign path[0]=in; 

not not1(rstn,reset); 

 

genvar i; 

generate 

for (i=0; i<LEN-1;i=i+1)  

begin: shift_reg 

dff u( .clk(clk), 

.d(path), 

.q(path[i+1]), 

.clrn(rstn), 

.prn(1'b1)); 

end 

 

endgenerate 

generate 

for (i=1; i<len-1;i=i+1) 

begin: or_connections 

or u3 (or_out,or_out[i-1],path[i+1]); 

end 

endgenerate 

 

endmodule 

 

 

attached photo shows what I get in RTL viewer. why I don't see logic gates? 

what am I doing wrong? 

 

Thanks in advance
0 Kudos
5 Replies
Altera_Forum
Honored Contributor II
810 Views

The or gates are ignored, because they don't generate any output signal in your design.

0 Kudos
Altera_Forum
Honored Contributor II
810 Views

Or gates generate or_out[i]. 

and what is about not gate?
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

 

--- Quote Start ---  

Or gates generate or_out[i]. 

--- Quote End ---  

 

or_out isn't an output of your design. out is the only one, wired to the DFF chain output.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

Thank you very much, now I have OR gates. 

What is about the NOT gate. his output is connected to CLRN of DFFs and input to RESET. Why I don't see him? 

 

Thanks
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

 

--- Quote Start ---  

What is about the NOT gate. 

--- Quote End ---  

 

Look sharp, it has been simply absorbed by inverting the signal. But this doesn't mean much, because RTL is just a functional circuit. You have to review the synthesiszed netlist to see how the cicruit is implemented in LEs.
0 Kudos
Reply