Importance of using module-instance parameter, Computer Engineering

Assignment Help:

Using Module-Instance Parameter:

Parameter values can be overridden while a module is instantiated. New parameter values are passed at the time of module instantiation. Top-level module can pass parameters.

//define top-level module

module top;

//instantiate two hello-world modules; pass new parameter values

hello-world #(l) wl; //pass value 1 to module wl

hello-world #(2) w2; //pass value 2 to module w2

endmodule

If multiple parameters are defined in module, during module instantiation they can be overridden by specifying new values in the same order as the parameter declarations in the module. If an overriding value isn't specified, default parameter declaration values are taken.

//define module with delays

module bus-master;

parameter delayl = 2;

parameter delay2 = 3;

parameter delay3 = 7;

...

...

Endmodule

 

//top-level module; instantiates two bus-master modules

module top;

//Instantiate the modules with new delay values

bus-master # (4, 5, 6) bl ( ) ; //bl : delayl = 4, delay2 = 5, delay3 = 6

bus-master # (9,4) b2 ( ) ; //b2: delayl = 9, delay2 = 4, delay3 = 7 (default)

endmodule

Module-instance,  parameter  value  assignment  is  a  very  useful  method  used  to  override  parameter values and to customize module instances.

 


Related Discussions:- Importance of using module-instance parameter

Device controllers, All components of computer communicate with processor b...

All components of computer communicate with processor by the system bus. Which means I/O devices required to be attached to system bus. But I/O devices aren't connected directly to

Shift microoperations, Shift Microoperations Shift microoperation can b...

Shift Microoperations Shift microoperation can be used for serial transfer of the data. They are used generally with arithmetic, logic and other data-processing operations. The

Explain b2c -business to consumer, B2C -Business to Consumer  This is w...

B2C -Business to Consumer  This is where the consumer admittance the system of the supplier. It is still a two-way function but is usually complete solely by the Internet.

Name the four steps in pipelining, Name the four steps in pipelining. F...

Name the four steps in pipelining. Fetch  : Read the instruction from the memory. Decode : Decode the instruction and get the source operand. Execute : Perform the operat

Traditional schema model, (a) Why did SAP introduce the extended star schem...

(a) Why did SAP introduce the extended star schema? Explain why it is reported to be better than the traditional schema model? (b) What is the difference between a dimension use

What are overlays, What are overlays? To enable a process to be larger ...

What are overlays? To enable a process to be larger than the amount of memory allocated to it, overlays are used. The idea of overlays is to keep in memory only those instructi

What is the need of modem in data communication, What is the need of MODEM ...

What is the need of MODEM in data communication? Need of Modem: Modems are utilized to interface computer networks, computers and other terminal equipment for radio channels

Difference between top-down and bottom-up programming, What is the differen...

What is the difference between top-down and bottom-up, programming? Ans: Top-down and Bottom-up Approaches In Top-down programming approach, we begin by identifying the main

Java, what is inheritence and all types in java?

what is inheritence and all types in java?

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd