Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Recent content by adamira

  1. A

    How to extract input/reg size in Verilog?

    Thank you, that sums it up. I meant something much simpler. just to select the "short" reg range. I know how to code it using local parameter: localparam SHORT_LEN = 6; reg [10:0] long; reg [SHORT_LEN-1:0] short; //imagine always block: short <= long[SHORT_LEN-1:0] //WORKING! But I don't want...
  2. A

    How to extract input/reg size in Verilog?

    The input variable width part of the example indeed has nothing to do with VHDL attribute, but this feature together with the VHDL attribute used later when declaring the counter signal, creates generic module without passing any additional information. (the compiler will auto-generate all the...
  3. A

    How to extract input/reg size in Verilog?

    Thank you, So like I thought, there is not a exact equivalent.. Eventually you'll have to create another code instance (define/param/local param) to support generic code. What if simply want to do something like: reg [10:0] long; reg [5:0] short; //imagine always block: short <= long[short:0]...
  4. A

    How to extract input/reg size in Verilog?

    Hi, VHDL has a powerful feature called attributes. Using attribute I can generalize modules quite easily, for example: entity alaram is port( clk : in std_logic; reset : in std_logic; CountTo : in std_logic_vector; CountEn : in std_logic; Done : out std_logic); end alaram ; architecture...

Part and Inventory Search

Back
Top