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.

Verilog Filter design reset and enable Problem

Status
Not open for further replies.

Milruwan

Member level 1
Joined
Jan 20, 2013
Messages
35
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,546
I design a filter using Matlab hdl coder. But the problem is filter doesn't give filtered output. When I do the simulation in matlab filter works perfectly, but when I test with modelsim filter is not giving the filtered output. Problem is with the way of resetting and enabling the filter.

filter inputs and outputs

Code:
module filter
               (
                clk,
                clk_enable,
                reset,
                filter_in,
                filter_out
                );

input_reg_process
Code:
always @ (posedge clk or posedge reset)
    begin: input_reg_process
      if (reset == 1'b1) begin
        input_register <= 0;
      end
      else begin
        if (clk_enable == 1'b1) begin
          input_register <= filter_in;
        end
      end
    end // input_reg_process

Here is the output I got (reset and enable signal are also shown in the figure)
filtered _dat.jpg

reset_my : is the reset
ce_my: is the enable
 

can you post the whole code with testbench ? Because its hard to tell from that scratch anythink. I dont see in wave input_register, and what is zc_out ?
 
Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top