|
|
@@ -18,7 +18,7 @@ real signal;
|
|
|
reg [31:0] tbCnt;
|
|
|
|
|
|
wire [31:0] startValue = 32'd10;
|
|
|
-wire [31:0] pNum = 8;
|
|
|
+wire [31:0] pNum = 10;
|
|
|
wire [31:0] stopValue = startValue+pNum-1;
|
|
|
|
|
|
// wire oscWind = (tbCnt>=10&tbCnt<=509)? 1'b1:1'b0;
|
|
|
@@ -35,7 +35,7 @@ wire resultVal;
|
|
|
wire impRespVal;
|
|
|
|
|
|
|
|
|
-// wire signed [27:0] adcDataMixed = oscWind?(ncoSin1*ncoSin2):28'd0;
|
|
|
+// wire signed [27:0] adcDataMixed = oscWfind?(ncoSin1*ncoSin2):28'd0;
|
|
|
wire signed [27:0] adcDataMixed = (ncoSin1*ncoSin2);
|
|
|
wire signed [13:0] adcDataMixedCut = adcDataMixed[26-:14];
|
|
|
|
|
|
@@ -45,13 +45,13 @@ wire signed [13:0] sinAdd = (ncoSin1>>>1)+(ncoSin2>>>1);
|
|
|
|
|
|
|
|
|
wire signed [13:0] singlePulse = (tbCnt==10)? 14'h1fff:14'h0;
|
|
|
-// wire signed [13:0] singlePulse = (tbCnt>=4500&tbCnt<=4501)? 14'h1fff:14'h0;
|
|
|
+// wire signed [13:0] singlePulse = (tbCnt>=10&tbCnt<=12)? 14'h1fff:14'h0;
|
|
|
//==========================================================================================
|
|
|
//clocks gen
|
|
|
always #10 Clk50 = ~Clk50;
|
|
|
|
|
|
//==========================================================================================
|
|
|
-parameter N = 3;
|
|
|
+parameter N = 2;
|
|
|
parameter M = 1;
|
|
|
|
|
|
always @(posedge Clk50) begin
|
|
|
@@ -227,7 +227,7 @@ reg [31:0] testCnt;
|
|
|
wire [10:0] test = N*2+N*2+decimFactor;
|
|
|
wire [10:0] test1 = N*2+N*2+decimFactor-1;
|
|
|
// wire writeEn = (oscWindDelay[N*2+N*2+decimFactor-2]);
|
|
|
-wire writeEn = (tbCnt>= (startValue+(N*2*2)+decimFactor) & tbCnt <= (stopValue+(N*2*2)+decimFactor));
|
|
|
+wire writeEn = (tbCnt>= (startValue+(N*2*2)+decimFactor-6) & tbCnt <= (stopValue+(N*2*2)+decimFactor-6));
|
|
|
|
|
|
always @(posedge Clk50)begin
|
|
|
if (!Rst) begin
|