Guest
Hello,
I understand the below mentioned code partially, that we are defining
the connections between different ports by names. I am not posting the
code for sample_test and angle_test to save people's space and time,
but I do have some logic running for these functionalities. So, lets
just assume some logic is defined for sample_test and angle_test. Now,
I had a few questions:
1) As one can see from the code, the output of sample_test_i and
sample_test_q is going as input to .xi and .yi in angle_test_0. So, i
am thinking that first s_in and sq_in would be processed to give the
output ssinter_i and ssinter_q respectively. Now, these would be
provided as input to .xi and .yi in angle_test. Am I right till now ?
2) Now subsequently, the angle_test_0 functionalities would run only
if all 3 inputs are active ? i.e. it will wait till ssinter_i and
ssinter_q are generated and phase is available to it? The angle_test_0
functionalities will not start until all 3 inputs are available or
would never start if all 3 inputs are not available.
I am not certain of the steps that I just described. Please correct me
if I am wrong. I saw a couple of similar posts, but got lost in the
code.
Jetli.
module ss_angle
(input clock,
input reset,
input wire [10:0] si_in,
input wire [10:0] sq_in,
output wire [10:0] si_out,
output wire [10:0] sq_out
);
wire [10:0] ssinter_i, ssinter_q;
wire [31:0] phase;
sample_test sample_test_i
( .clock(clock),.reset(reset),.signal_in(si_in),.signal_out(ssinter_i) );
sample_test sample_test_q
( .clock(clock),.reset(reset),.signal_in(sq_in),.signal_out(ssinter_q) );
angle_test angle_test_0
( .clock(clock),.reset(reset),
.xi(ssinter_i),.yi(ssinter_q),.zi(phase[27:13]),
.xo(si_out),.yo(sq_out),.zo() );
endmodule
P.S. One can assume that this is my top level code.
I understand the below mentioned code partially, that we are defining
the connections between different ports by names. I am not posting the
code for sample_test and angle_test to save people's space and time,
but I do have some logic running for these functionalities. So, lets
just assume some logic is defined for sample_test and angle_test. Now,
I had a few questions:
1) As one can see from the code, the output of sample_test_i and
sample_test_q is going as input to .xi and .yi in angle_test_0. So, i
am thinking that first s_in and sq_in would be processed to give the
output ssinter_i and ssinter_q respectively. Now, these would be
provided as input to .xi and .yi in angle_test. Am I right till now ?
2) Now subsequently, the angle_test_0 functionalities would run only
if all 3 inputs are active ? i.e. it will wait till ssinter_i and
ssinter_q are generated and phase is available to it? The angle_test_0
functionalities will not start until all 3 inputs are available or
would never start if all 3 inputs are not available.
I am not certain of the steps that I just described. Please correct me
if I am wrong. I saw a couple of similar posts, but got lost in the
code.
Jetli.
module ss_angle
(input clock,
input reset,
input wire [10:0] si_in,
input wire [10:0] sq_in,
output wire [10:0] si_out,
output wire [10:0] sq_out
);
wire [10:0] ssinter_i, ssinter_q;
wire [31:0] phase;
sample_test sample_test_i
( .clock(clock),.reset(reset),.signal_in(si_in),.signal_out(ssinter_i) );
sample_test sample_test_q
( .clock(clock),.reset(reset),.signal_in(sq_in),.signal_out(ssinter_q) );
angle_test angle_test_0
( .clock(clock),.reset(reset),
.xi(ssinter_i),.yi(ssinter_q),.zi(phase[27:13]),
.xo(si_out),.yo(sq_out),.zo() );
endmodule
P.S. One can assume that this is my top level code.