crc32_dat120.v

来自「本電子檔為 verilog cookbook,包含了通訊,影像,DSP等重要常用」· Verilog 代码 · 共 1,134 行 · 第 1/5 页

V
1,134
字号
       x158, x157, x156, x155, x154, x153, x152, x151, 
       x150, x149, x148, x147, x146, x145, x144, x143, 
       x142, x141, x140, x139, x138, x137, x136, x135, 
       x134, x133, x132, x131, x130, x129, x128, x127, 
       x126, x125, x124, x123, x122, x121, x120, x119, 
       x118, x117, x116, x115, x114, x113, x112, x111, 
       x110, x109, x108, x107, x106, x105, x104, x103, 
       x102, x101, x100, x99, x98, x97, x96, x95, 
       x94, x93, x92, x91, x90, x89, x88, x87, 
       x86, x85, x84, x83, x82, x81, x80, x79, 
       x78, x77, x76, x75, x74, x72, x71, x70, 
       x69, x68, x67, x66, x65, x64, x63, x62, 
       x61, x60, x59, x58, x57, x56, x55, x54, 
       x53, x52, x51, x50, x49, x48, x47, x46, 
       x45, x44, x43, x42, x41, x40, x39, x38, 
       x37, x36, x35, x34, x33, x32, x23, x22, 
       x21, x20, x19, x18, x17, x16, x15, x14, 
       x13, x12, x11, x10, x9, x8, x7, x6, 
       x5, x4, x3, x2, x1, x0, x31, x30, 
       x29, x28, x27, x26, x25, x24;

assign crc_out = {x31,x30,x29,x28,x27,x26,x25,x24,x23,x22,x21,x20,x19,x18,x17,
        x16,x15,x14,x13,x12,x11,x10,x9,x8,x7,x6,x5,x4,x3,x2,x1,
        x0};

wire d0,d1,d2,d3,d4,d5,d6,d7,d8,d9,d10,d11,d12,d13,d14,
    d15,d16,d17,d18,d19,d20,d21,d22,d23,d24,d25,d26,d27,d28,d29,d30,
    d31,d32,d33,d34,d35,d36,d37,d38,d39,d40,d41,d42,d43,d44,d45,d46,
    d47,d48,d49,d50,d51,d52,d53,d54,d55,d56,d57,d58,d59,d60,d61,d62,
    d63,d64,d65,d66,d67,d68,d69,d70,d71,d72,d73,d74,d75,d76,d77,d78,
    d79,d80,d81,d82,d83,d84,d85,d86,d87,d88,d89,d90,d91,d92,d93,d94,
    d95,d96,d97,d98,d99,d100,d101,d102,d103,d104,d105,d106,d107,d108,d109,d110,
    d111,d112,d113,d114,d115,d116,d117,d118,d119;

assign { d119,d118,d117,d116,d115,d114,d113,d112,d111,d110,d109,d108,d107,d106,d105,
        d104,d103,d102,d101,d100,d99,d98,d97,d96,d95,d94,d93,d92,d91,d90,d89,
        d88,d87,d86,d85,d84,d83,d82,d81,d80,d79,d78,d77,d76,d75,d74,d73,
        d72,d71,d70,d69,d68,d67,d66,d65,d64,d63,d62,d61,d60,d59,d58,d57,
        d56,d55,d54,d53,d52,d51,d50,d49,d48,d47,d46,d45,d44,d43,d42,d41,
        d40,d39,d38,d37,d36,d35,d34,d33,d32,d31,d30,d29,d28,d27,d26,d25,
        d24,d23,d22,d21,d20,d19,d18,d17,d16,d15,d14,d13,d12,d11,d10,d9,
        d8,d7,d6,d5,d4,d3,d2,d1,d0} = dat_in [119:0];

wire c0,c1,c2,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,
    c15,c16,c17,c18,c19,c20,c21,c22,c23,c24,c25,c26,c27,c28,c29,c30,
    c31;

assign { c31,c30,c29,c28,c27,c26,c25,c24,c23,c22,c21,c20,c19,c18,c17,
        c16,c15,c14,c13,c12,c11,c10,c9,c8,c7,c6,c5,c4,c3,c2,c1,
        c0} = crc_in [31:0];

    xor6 x343i (.out(x343),.a(x335),.b(x45),.c(x341),.d(x42),.e(x46),.f(x340));  // 6 ins 1 outs level 2

    xor6 x342i (.out(x342),.a(x336),.b(x52),.c(x37),.d(x337),.e(x338),.f(x339));  // 6 ins 1 outs level 2

    xor6 x341i (.out(x341),.a(d40),.b(d28),.c(d90),.d(1'b0),.e(1'b0),.f(1'b0));  // 3 ins 1 outs level 1

    xor6 x340i (.out(x340),.a(d18),.b(d45),.c(c3),.d(d106),.e(d80),.f(d50));  // 6 ins 1 outs level 1

    xor6 x339i (.out(x339),.a(c11),.b(d99),.c(d6),.d(d63),.e(d10),.f(c26));  // 6 ins 1 outs level 1

    xor6 x338i (.out(x338),.a(d14),.b(c0),.c(d17),.d(c4),.e(d92),.f(d36));  // 6 ins 1 outs level 1

    xor6 x337i (.out(x337),.a(d48),.b(d88),.c(c18),.d(d39),.e(d94),.f(d61));  // 6 ins 1 outs level 1

    xor6 x336i (.out(x336),.a(d20),.b(d21),.c(d35),.d(d30),.e(d7),.f(d113));  // 6 ins 1 outs level 1

    xor6 x335i (.out(x335),.a(d0),.b(d27),.c(d16),.d(d86),.e(d95),.f(d85));  // 6 ins 1 outs level 1

    xor6 x334i (.out(x334),.a(x326),.b(x45),.c(x50),.d(x65),.e(x42),.f(1'b0));  // 5 ins 1 outs level 2

    xor6 x333i (.out(x333),.a(x331),.b(x49),.c(x40),.d(x38),.e(x33),.f(1'b0));  // 5 ins 1 outs level 2

    xor6 x332i (.out(x332),.a(d87),.b(x327),.c(x56),.d(x328),.e(x329),.f(x330));  // 6 ins 1 outs level 2

    xor6 x331i (.out(x331),.a(d76),.b(d105),.c(d81),.d(c27),.e(c14),.f(d11));  // 6 ins 1 outs level 1

    xor6 x330i (.out(x330),.a(d38),.b(d99),.c(d61),.d(d19),.e(d18),.f(d37));  // 6 ins 1 outs level 1

    xor6 x329i (.out(x329),.a(c12),.b(d111),.c(d8),.d(d33),.e(d62),.f(d21));  // 6 ins 1 outs level 1

    xor6 x328i (.out(x328),.a(c0),.b(c11),.c(d84),.d(d88),.e(d115),.f(d49));  // 6 ins 1 outs level 1

    xor6 x327i (.out(x327),.a(d15),.b(d106),.c(d44),.d(d29),.e(d78),.f(d71));  // 6 ins 1 outs level 1

    xor6 x326i (.out(x326),.a(d57),.b(d95),.c(d75),.d(d86),.e(d82),.f(d67));  // 6 ins 1 outs level 1

    xor6 x325i (.out(x325),.a(x323),.b(x70),.c(x32),.d(x48),.e(x52),.f(x50));  // 6 ins 1 outs level 2

    xor6 x324i (.out(x324),.a(x318),.b(x33),.c(x319),.d(x320),.e(x321),.f(x322));  // 6 ins 1 outs level 2

    xor6 x323i (.out(x323),.a(d60),.b(d59),.c(1'b0),.d(1'b0),.e(1'b0),.f(1'b0));  // 2 ins 1 outs level 1

    xor6 x322i (.out(x322),.a(d49),.b(d54),.c(d24),.d(d9),.e(d50),.f(d55));  // 6 ins 1 outs level 1

    xor6 x321i (.out(x321),.a(d42),.b(d111),.c(d57),.d(d102),.e(d23),.f(c7));  // 6 ins 1 outs level 1

    xor6 x320i (.out(x320),.a(d44),.b(d97),.c(d58),.d(d76),.e(d79),.f(d87));  // 6 ins 1 outs level 1

    xor6 x319i (.out(x319),.a(d26),.b(d75),.c(c19),.d(d95),.e(c5),.f(d40));  // 6 ins 1 outs level 1

    xor6 x318i (.out(x318),.a(d38),.b(d19),.c(d88),.d(c9),.e(d61),.f(d48));  // 6 ins 1 outs level 1

    xor6 x317i (.out(x317),.a(x309),.b(x68),.c(x56),.d(x33),.e(x315),.f(x314));  // 6 ins 1 outs level 2

    xor6 x316i (.out(x316),.a(x310),.b(x39),.c(x53),.d(x311),.e(x312),.f(x313));  // 6 ins 1 outs level 2

    xor6 x315i (.out(x315),.a(d98),.b(d29),.c(d78),.d(d39),.e(1'b0),.f(1'b0));  // 4 ins 1 outs level 1

    xor6 x314i (.out(x314),.a(d34),.b(d68),.c(d1),.d(c20),.e(c4),.f(d100));  // 6 ins 1 outs level 1

    xor6 x313i (.out(x313),.a(d92),.b(d108),.c(d99),.d(d5),.e(d4),.f(d55));  // 6 ins 1 outs level 1

    xor6 x312i (.out(x312),.a(c21),.b(c10),.c(c6),.d(c12),.e(d40),.f(d19));  // 6 ins 1 outs level 1

    xor6 x311i (.out(x311),.a(d43),.b(c26),.c(d114),.d(d105),.e(d118),.f(d32));  // 6 ins 1 outs level 1

    xor6 x310i (.out(x310),.a(c30),.b(d93),.c(d63),.d(d11),.e(d76),.f(d61));  // 6 ins 1 outs level 1

    xor6 x309i (.out(x309),.a(d49),.b(d109),.c(d94),.d(d74),.e(d56),.f(d82));  // 6 ins 1 outs level 1

    xor6 x308i (.out(x308),.a(x40),.b(x50),.c(x56),.d(x55),.e(x44),.f(x47));  // 6 ins 1 outs level 2

    xor6 x307i (.out(x307),.a(x302),.b(x42),.c(x306),.d(x303),.e(x304),.f(x305));  // 6 ins 1 outs level 2

    xor6 x306i (.out(x306),.a(d97),.b(d67),.c(d57),.d(c9),.e(1'b0),.f(1'b0));  // 4 ins 1 outs level 1

    xor6 x305i (.out(x305),.a(d99),.b(d81),.c(d29),.d(c22),.e(c2),.f(d26));  // 6 ins 1 outs level 1

    xor6 x304i (.out(x304),.a(d83),.b(d6),.c(d43),.d(c31),.e(d110),.f(c26));  // 6 ins 1 outs level 1

    xor6 x303i (.out(x303),.a(d15),.b(d41),.c(d61),.d(c6),.e(d84),.f(c19));  // 6 ins 1 outs level 1

    xor6 x302i (.out(x302),.a(c14),.b(c23),.c(d69),.d(d21),.e(c11),.f(d48));  // 6 ins 1 outs level 1

    xor6 x301i (.out(x301),.a(d64),.b(d3),.c(c15),.d(d74),.e(d95),.f(d119));  // 6 ins 1 outs level 1

    xor6 x300i (.out(x300),.a(x39),.b(x40),.c(x46),.d(x52),.e(x34),.f(x50));  // 6 ins 1 outs level 2

    xor6 x299i (.out(x299),.a(x294),.b(x298),.c(x68),.d(x295),.e(x296),.f(x297));  // 6 ins 1 outs level 2

    xor6 x298i (.out(x298),.a(d98),.b(c10),.c(d51),.d(1'b0),.e(1'b0),.f(1'b0));  // 3 ins 1 outs level 1

    xor6 x297i (.out(x297),.a(d50),.b(d102),.c(d65),.d(c27),.e(d63),.f(c3));  // 6 ins 1 outs level 1

    xor6 x296i (.out(x296),.a(d76),.b(d62),.c(d100),.d(d57),.e(c23),.f(d79));  // 6 ins 1 outs level 1

    xor6 x295i (.out(x295),.a(d9),.b(d69),.c(d13),.d(c12),.e(d40),.f(d111));  // 6 ins 1 outs level 1

    xor6 x294i (.out(x294),.a(d73),.b(d108),.c(d103),.d(c26),.e(d52),.f(d83));  // 6 ins 1 outs level 1

    xor6 x293i (.out(x293),.a(c22),.b(c19),.c(d36),.d(d64),.e(d80),.f(d31));  // 6 ins 1 outs level 1

    xor6 x292i (.out(x292),.a(x290),.b(x53),.c(x34),.d(x40),.e(x47),.f(x38));  // 6 ins 1 outs level 2

    xor6 x291i (.out(x291),.a(x285),.b(x45),.c(x286),.d(x287),.e(x288),.f(x289));  // 6 ins 1 outs level 2

    xor6 x290i (.out(x290),.a(d104),.b(d97),.c(d112),.d(d65),.e(c20),.f(1'b0));  // 5 ins 1 outs level 1

    xor6 x289i (.out(x289),.a(d52),.b(d43),.c(d28),.d(d31),.e(c23),.f(c14));  // 6 ins 1 outs level 1

    xor6 x288i (.out(x288),.a(d77),.b(d85),.c(d108),.d(d81),.e(c5),.f(d48));  // 6 ins 1 outs level 1

    xor6 x287i (.out(x287),.a(d84),.b(c6),.c(d70),.d(d60),.e(d32),.f(d64));  // 6 ins 1 outs level 1

    xor6 x286i (.out(x286),.a(d44),.b(d4),.c(c27),.d(c9),.e(d66),.f(d10));  // 6 ins 1 outs level 1

    xor6 x285i (.out(x285),.a(d63),.b(d59),.c(d23),.d(c7),.e(d35),.f(d61));  // 6 ins 1 outs level 1

    xor6 x284i (.out(x284),.a(d71),.b(d51),.c(d30),.d(d56),.e(d106),.f(c24));  // 6 ins 1 outs level 1

    xor6 x283i (.out(x283),.a(x47),.b(x36),.c(x34),.d(x39),.e(1'b0),.f(1'b0));  // 4 ins 1 outs level 2

    xor6 x282i (.out(x282),.a(c17),.b(d93),.c(x274),.d(x61),.e(x44),.f(x38));  // 6 ins 1 outs level 2

    xor6 x281i (.out(x281),.a(x275),.b(x55),.c(x276),.d(x277),.e(x278),.f(x279));  // 6 ins 1 outs level 2

    xor6 x279i (.out(x279),.a(c22),.b(d36),.c(d23),.d(c7),.e(c14),.f(d78));  // 6 ins 1 outs level 1

    xor6 x278i (.out(x278),.a(d60),.b(d30),.c(d81),.d(d5),.e(d47),.f(d11));  // 6 ins 1 outs level 1

    xor6 x277i (.out(x277),.a(d98),.b(d65),.c(d53),.d(c10),.e(d72),.f(d100));  // 6 ins 1 outs level 1

    xor6 x276i (.out(x276),.a(d20),.b(d80),.c(c6),.d(d96),.e(d75),.f(c8));  // 6 ins 1 outs level 1

    xor6 x275i (.out(x275),.a(d64),.b(d105),.c(d71),.d(d43),.e(d102),.f(c5));  // 6 ins 1 outs level 1

    xor6 x274i (.out(x274),.a(d110),.b(d63),.c(d24),.d(d28),.e(d9),.f(d86));  // 6 ins 1 outs level 1

    xor6 x273i (.out(x273),.a(x266),.b(x56),.c(x37),.d(x36),.e(x32),.f(1'b0));  // 5 ins 1 outs level 2

    xor6 x272i (.out(x272),.a(x270),.b(x66),.c(x34),.d(x46),.e(x64),.f(x38));  // 6 ins 1 outs level 2

    xor6 x271i (.out(x271),.a(x267),.b(d72),.c(x52),.d(x41),.e(x268),.f(x269));  // 6 ins 1 outs level 2

    xor6 x270i (.out(x270),.a(d67),.b(c25),.c(d99),.d(d85),.e(d28),.f(d105));  // 6 ins 1 outs level 1

    xor6 x269i (.out(x269),.a(d9),.b(d80),.c(d66),.d(d61),.e(d70),.f(d118));  // 6 ins 1 outs level 1

    xor6 x268i (.out(x268),.a(d37),.b(d63),.c(d96),.d(d16),.e(c23),.f(d50));  // 6 ins 1 outs level 1

    xor6 x267i (.out(x267),.a(d26),.b(d65),.c(c8),.d(d34),.e(d10),.f(d115));  // 6 ins 1 outs level 1

    xor6 x266i (.out(x266),.a(d54),.b(c20),.c(d52),.d(c26),.e(d5),.f(d32));  // 6 ins 1 outs level 1

    xor6 x265i (.out(x265),.a(x63),.b(x39),.c(x58),.d(x42),.e(x35),.f(x45));  // 6 ins 1 outs level 2

    xor6 x264i (.out(x264),.a(x258),.b(x263),.c(x259),.d(x260),.e(x261),.f(x262));  // 6 ins 1 outs level 2

    xor6 x263i (.out(x263),.a(d27),.b(d1),.c(d102),.d(1'b0),.e(1'b0),.f(1'b0));  // 3 ins 1 outs level 1

    xor6 x262i (.out(x262),.a(d46),.b(d88),.c(d107),.d(d6),.e(d100),.f(d9));  // 6 ins 1 outs level 1

    xor6 x261i (.out(x261),.a(d59),.b(d116),.c(d34),.d(c31),.e(c17),.f(d103));  // 6 ins 1 outs level 1

    xor6 x260i (.out(x260),.a(c19),.b(d64),.c(d31),.d(d94),.e(d53),.f(d85));  // 6 ins 1 outs level 1

    xor6 x259i (.out(x259),.a(c18),.b(d115),.c(d58),.d(d28),.e(d49),.f(d20));  // 6 ins 1 outs level 1

    xor6 x258i (.out(x258),.a(d81),.b(d7),.c(d44),.d(d72),.e(d110),.f(d45));  // 6 ins 1 outs level 1

    xor6 x257i (.out(x257),.a(c28),.b(d37),.c(c6),.d(d2),.e(d35),.f(d62));  // 6 ins 1 outs level 1

    xor6 x256i (.out(x256),.a(d119),.b(x54),.c(x48),.d(x71),.e(d102),.f(x36));  // 6 ins 1 outs level 2

    xor6 x255i (.out(x255),.a(x248),.b(x249),.c(x250),.d(x251),.e(x252),.f(x253));  // 6 ins 1 outs level 2

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?