1 -------------------------------------------------------------------------------
4 -- /___/ \ / Vendor: Xilinx
5 -- \ \ \/ Version : 2.
3
6 -- \ \ Application : 7 Series FPGAs Transceivers Wizard
7 -- / / Filename : sfp3_v2_3_descrambler_64b66b.vhd
13 -- Module DESCRAMBLER_64B66B
14 -- Generated by Xilinx 7 Series FPGAs Transceivers Wizard
17 -- (c) Copyright 2010-2012 Xilinx, Inc. All rights reserved.
19 -- This file contains confidential and proprietary information
20 -- of Xilinx, Inc. and is protected under U.S. and
21 -- international copyright and other intellectual property
25 -- This disclaimer is not a license and does not grant any
26 -- rights to the materials distributed herewith. Except as
27 -- otherwise provided in a valid license issued to you by
28 -- Xilinx, and to the maximum extent permitted by applicable
29 -- law: (1) THESE MATERIALS ARE MADE AVAILABLE "AS IS"
AND
30 -- WITH ALL FAULTS, AND XILINX HEREBY DISCLAIMS ALL WARRANTIES
31 -- AND CONDITIONS, EXPRESS, IMPLIED, OR STATUTORY, INCLUDING
32 -- BUT NOT LIMITED TO WARRANTIES OF MERCHANTABILITY, NON-
33 -- INFRINGEMENT, OR FITNESS FOR ANY PARTICULAR PURPOSE; and
34 -- (2) Xilinx shall
not be liable (whether
in contract
or tort,
35 -- including negligence, or under any other theory of
36 -- liability) for any loss or damage of any kind or nature
37 -- related to, arising under or in connection with these
38 -- materials, including for any direct, or any indirect,
39 -- special, incidental, or consequential loss or damage
40 -- (including loss of data, profits, goodwill, or any type of
41 -- loss or damage suffered as a result of any action brought
42 -- by a third party) even if such damage or loss was
43 -- reasonably foreseeable or Xilinx had been advised of the
44 -- possibility of the same.
46 -- CRITICAL APPLICATIONS
47 -- Xilinx products are not designed or intended to be fail-
48 -- safe, or for use in any application requiring fail-safe
49 -- performance, such as life-support or safety devices or
50 -- systems, Class III medical devices, nuclear facilities,
51 -- applications related to the deployment of airbags, or any
52 -- other applications that could lead to death, personal
53 -- injury, or severe property or environmental damage
54 -- (individually and collectively, "Critical
55 -- Applications"). Customer assumes the sole risk and
56 -- liability of any use of Xilinx products in Critical
57 -- Applications, subject only to applicable laws and
58 -- regulations governing limitations on product liability.
60 -- THIS COPYRIGHT NOTICE AND DISCLAIMER MUST BE RETAINED AS
61 -- PART OF THIS FILE AT ALL TIMES.
65 use ieee.std_logic_1164.
all;
66 use ieee.numeric_std.
all;
68 use UNISIM.VCOMPONENTS.
ALL;
70 --***********************************Entity Declaration*******************************
80 SCRAMBLED_DATA_IN : in ((RX_DATA_WIDTH-1) downto 0);
81 UNSCRAMBLED_DATA_OUT : out ((RX_DATA_WIDTH-1) downto 0);
95 --***********************************Parameter Declarations********************
97 constant DLY : := 10 ps;
99 --***************************Internal Register Declarations********************
101 signal descrambler : (57 downto 0);
102 signal poly : (57 downto 0);
103 signal tempdata : ((RX_DATA_WIDTH-1) downto 0);
104 signal unscrambled_data_i : ((RX_DATA_WIDTH-1) downto 0);
106 --*********************************Main Body of Code***************************
110 process( descrambler,SCRAMBLED_DATA_IN )
111 variable poly_i : (57 downto 0);
112 variable tempData_i : ((RX_DATA_WIDTH-1) downto 0);
116 poly_i := descrambler;
117 for i in 0 to (RX_DATA_WIDTH-1) loop
118 xorBit := SCRAMBLED_DATA_IN(i) xor poly_i(38) xor poly_i(57);
119 poly_i := (poly_i(56 downto 0) & SCRAMBLED_DATA_IN(i));
120 tempData_i(i) := xorBit;
123 tempdata <= tempdata_i;
128 if(USER_CLK'event and USER_CLK = '1') then
129 if (SYSTEM_RESET = '1') then
130 unscrambled_data_i <= (others => '0') after DLY;
131 descrambler <= "0101010101010101010101010101010101010101010101010101010101" after DLY;
132 elsif (DATA_VALID_IN = '1') then
133 descrambler <= poly after DLY;
134 unscrambled_data_i <= tempdata after DLY;
139 --_______________ Unscrambled Data assignment to output port ______________
141 UNSCRAMBLED_DATA_OUT <= unscrambled_data_i;