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.
*******************************************************************************/
/*******************************************************************************
The module generates noise,using downlink m-sequences.
The x sequence is constructed using the primitive polynomial
1 + x( 7 ) + x( 18 ).
The y sequence is constructed using the ploynomial
1 + x( 5 ) + x( 7 ) + x( 10 ) + x( 18 ).
x is iniatialized with x( 0 ) = x( 1 ) = x( 2 ) ... = x( 17 ) = 0,
recursive definition
x( i+ 18 ) = x( i + 7 ) + x( i ) modulo 2.
y is iniatialized with y( 0 ) = y( 1 ) = y( 2 ) ... = y( 17 ) = 1.
recursive definition
y( i + 18 ) = y( i + 10 ) + y( i+ 7 ) + y( i+ 5 ) + y( i ) modulo 2.
Noise output is z( i ) = x( i ) + y( i ) modulo 2.
//******************************************************************************
////////////////////////////////////////////////////////////////////////////////
// Generate x and y sequence.
assign Xshift = Xseq[ 7 ] + Xseq[ 0 ];
always @( posedge Clk16 or posedge Reset )
begin
if( Reset == 1'b1 )
Xseq <= 18'b0;
else
if( Noise_start == 1'b1 )
begin
Xseq[ 16:0 ] <= Xseq[ 17:1 ];
Xseq[ 17 ] <= Xshift[ 0 ];
end
else;
end
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.