The Pinorder Panel

The pinorder panel allows you to define the interface for your memory module.

There are two ways in which the pinorder can be defined. First, you can define the order using the colored bar provided. Second, you can read it from a verilog file.

Method 1: Defining your own pinorder

You can choose to define your own pinorder. You will use the colored bar in the top half of the panel. All the pins that you defined in the main panel and the port configuration panel will be provided, each in it's own segment of the bar.

When you click on any segment, you will get a menu which lists the names of all the ports. You can then select any name from the menu, and the bar will exchange the old name with the new port.

There is also an menu item to reverse the bitorder. By default, all the ports in a group are ordered in a high to low bit order. When you select this menu item - Reverse Bit Order - the order will be reversed.

There is a limited choice in how the ports and bits within the port can be ordered. For more complex schemes, you should choose method 2.

Method 2: Reading pinorder from file

You may want to read the pinorder if you already have a verilog file describing the model. The verilog file may have the behavioural model, but the interface remains the same. In other cases, the pinorder that you need may not be possible to define using the limited choices in method 1, e.g. alphabetic instead of straight low to high or high to low bit order, or ports which are split.

The verilog file need not contain the full definition of the model. All MemGen needs is that the interface be defined in the file in verilog style. The model name in the verilog file should be the same as the one you gave in the main panel of MemGen.

In order to choose the verilog file, click on the "Select File ..." button and a file selection box will open. Select the file you want to read from and click "Open". MemGen will read the file and extract the interface for the model. The interface will then be displayed in the text window in the method 2 subpanel.