cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
matttay
Observer
Observer
5,149 Views
Registered: ‎01-13-2010

Verilog confusion or synthesis bug?

Jump to solution

Hi, still somewhat new at verilog. I've stripped down a problem I'm having to bare bones. This may or may not be the issue I am seeing on a larger piece of code, but I don't quite understand why there are buffers signals on the schematic (circled in yellow) pointing the wrong way. In the large piece of code I'm working on, when I route "din" wires external to view on a logic analyzer everything starts working. Here, it's not quite the same. But as a first step, can someone explain why the buffers look to be pointing the wrong way? 

 

 

module Main(
    input Clk,
    input Select,
    output [1:0] Data 
    );
	 
wire [1:0] din;
reg [1:0] Counter;
	 
assign din = (Select) ? Counter : 2'h1;
assign Data = din;

always @(posedge Clk)
    Counter <= Counter + 1;

endmodule

 

 

 

 

 

Capture.PNG
0 Kudos
1 Solution

Accepted Solutions
austin
Scholar
Scholar
6,309 Views
Registered: ‎02-27-2008
m,

The little red triangles are not buffers: they are splitting the bus into separate wires, or combining separate wires into a bus...
Austin Lesea
Principal Engineer
Xilinx San Jose

View solution in original post

0 Kudos
4 Replies
austin
Scholar
Scholar
6,310 Views
Registered: ‎02-27-2008
m,

The little red triangles are not buffers: they are splitting the bus into separate wires, or combining separate wires into a bus...
Austin Lesea
Principal Engineer
Xilinx San Jose

View solution in original post

0 Kudos
matttay
Observer
Observer
5,125 Views
Registered: ‎01-13-2010

Understood, thanks!

0 Kudos
emaits
Newbie
Newbie
5,034 Views
Registered: ‎08-20-2012

 

so how can i know it is combining or spliting? is there any specific direction of that red triangle?
thanks~
0 Kudos
eteam00
Professor
Professor
5,032 Views
Registered: ‎07-21-2009

so how can i know it is combining or spliting? is there any specific direction of that red triangle?

 

The schematic pasted in mattay's first post in this thread makes the answers quite clear.  Look at the signal names on either side of the red triangles.

 

-- Bob Elkind

SIGNATURE:
README for newbies is here: http://forums.xilinx.com/t5/New-Users-Forum/README-first-Help-for-new-users/td-p/219369

Summary:
1. Read the manual or user guide. Have you read the manual? Can you find the manual?
2. Search the forums (and search the web) for similar topics.
3. Do not post the same question on multiple forums.
4. Do not post a new topic or question on someone else's thread, start a new thread!
5. Students: Copying code is not the same as learning to design.
6 "It does not work" is not a question which can be answered. Provide useful details (with webpage, datasheet links, please).
7. You are not charged extra fees for comments in your code.
8. I am not paid for forum posts. If I write a good post, then I have been good for nothing.
0 Kudos