LOGIN   :::   RECOVER PASS   :::   GET ACCOUNT    
Browse
  • Projects
  • Code (CVS)
  • Forums
  • News
  • Articles
  • Polls
  •  
    OpenCores
  • FAQ
  • CVS HowTo
  • Mission
  • Media
  • Tools
  • Advertise
  • Mirrors
  • Logos
  • Contact us
  • Job Opportunity
  •  
    Tools
  • Search
      
  • Download Cores (CVSGet)
  •  
    More
  • Wishbone
  • Perlilog
  • EDA tools
  • OpenTech CD
  •  
    Navigation: All forums > Usb > Message List > Message Post

    Message

    Reply | Reply all
    Date Prev | Date Next | Thread Prev | Thread Next Date Index | Thread Index

    From: "kw@nie" <kwanie@p...>
    Date: Thu, 21 Feb 2002 15:30:13 +0800
    Subject: Re: [usb] crc algorithm
    Top

    I took a closer look at what first sent out and realised i made a serious
    mistake with the diagram for the LFSR of the first method.
    
    Attached is the correct one.
    
    
    ----- Original Message -----
    From: "kw@nie" <kwanie@p...>
    To: <usb@o...>
    Sent: Thursday, February 21, 2002 10:33 AM
    Subject: Re: [usb] crc algorithm
    
    
    > Hi Bo,
    >
    > The 1st method take for x^5 xor x^2 xor x^0 and feedback into LSB. There
    is
    > only 1 feedback point for this method, which is the LSB. That's why it
    needs
    > 5 additional cycle after the last data bit to work, which is also why it
    is
    > never used in real design.
    >
    > cheers,
    > kwanie
    >
    >  ----- Original Message -----
    > From: "Bo" <bo_ye@y...>
    > To: <usb@o...>
    > Sent: Thursday, February 21, 2002 10:10 AM
    > Subject: Re: [usb] crc algorithm
    >
    >
    > > Hi Kwnie,
    > >     Actually, it doesn't mater what value
    > > you need to preset, as far as encode/decode
    > > are using the same seed. But people set it to
    > > 1's for some protocals, so everybody can
    > > communicate each other, either in transmit side
    > > or receive side. That's my understanding.
    > >    The result for the first diagram looks to me
    > > is y = 1 + x^3 + x^5, but the second one is
    > > y = 1 + x^2 + x^5. If you change the first one,
    > > feedback from Msb -> Lsb to Msb -> B[2], actually
    > > from 2-string feed back to single-string feedback,
    > > it would has the same result as the second one.
    > > Which is y = 1 + x^2 + x^5.
    > >
    > > regards
    > > bo
    > >
    > >
    > > --- "kw@nie" <kwanie@p...> wrote:
    > > > Bi Bo,
    > > >
    > > > You are right about pre-loading the register with
    > > > '1's. it's careless of me
    > > > to not have included it.
    > > >
    > > > >      The first part, looks like using two-string
    > > > > feed back instead. It will result in
    > > > > Y = 1 + X^3 + X^5 instead of Y = 1 + X^2 + X^5 in
    > > > > USB protocol for token packet checksum.
    > > >
    > > > The result is still Y = 1 + X^3 + X^5 => 2^0 + 2^3 +
    > > > 2^5, with 2^0 being the
    > > > data bit.
    > > >
    > > >
    > > > ----- Original Message -----
    > > > From: "Bo" <bo_ye@y...>
    > > > To: <usb@o...>
    > > > Sent: Thursday, February 21, 2002 7:33 AM
    > > > Subject: RE: [usb] crc algorithm
    > > >
    > > >
    > > > > Hi Kwanie,
    > > > >      Thanks for the diagram.
    > > > >      I agree on the second part. Xor the X0 with
    > > > > the MSB will yield the correct when the last bit
    > > > > is shifted in. But need to preset all the register
    > > > > to 1's. (correct me if I am wrong)
    > > > >      The first part, looks like using two-string
    > > > > feed back instead. It will result in
    > > > > Y = 1 + X^3 + X^5 instead of Y = 1 + X^2 + X^5 in
    > > > > USB protocol for token packet checksum.
    > > > >
    > > > > regards
    > > > > bo
    > > > >
    > > > >
    > > > > --- "kw@nie" <kwanie@p...> wrote:
    > > > > > I think I know why the binary representations,
    > > > in
    > > > > > the USB specification, are
    > > > > > different from the polynomials. Attached is a
    > > > brief
    > > > > > explanation based on the
    > > > > > 5-bit CRC but the principle applies for both CRC
    > > > > > generators.
    > > > > >
    > > > > > Cheers,
    > > > > > kwanie
    > > > > >
    > > > > >
    > > > > >
    > > > > >
    > > > > >  -----Original Message-----
    > > > > > From: owner-usb@o...
    > > > > > [mailto:owner-usb@o...]  On Behalf
    > > > > > Of kebloo@m...
    > > > > > Sent: 21 February 2002 08:34
    > > > > > To: usb@o...
    > > > > > Subject: [usb] crc algorithm
    > > > > >
    > > > > > Hello,
    > > > > >
    > > > > > Sorry for this beginner question, but I wish
    > > > some
    > > > > > one could
    > > > > > answer my curiosity...
    > > > > >
    > > > > > USB 1.1 specification defines generator
    > > > polynomial
    > > > > > of 5-bit crc
    > > > > > as G(x) = x^5+x^2+1 and binary pattern that
    > > > > > represent it as
    > > > > > 00101B and 16-bit crc as G(x) = x^16+x^15+x^2+1
    > > > and
    > > > > > binary pattern that represent it as
    > > > > > 1000000000000101B.
    > > > > > My question is why the binary pattern stated
    > > > like
    > > > > > that and
    > > > > > not 100101B for 5-bit crc and 11000000000000101B
    > > > ?
    > > > > > Thanks....
    > > > > >
    > > > > >
    > > > > >
    > > > > > Best Regard,
    > > > > >
    > > > > >
    > > > > > RE Tambunan
    > > > > > --
    > > > > > To unsubscribe from usb mailing list please
    > > > visit
    > > > > > http://www.opencores.org/mailinglists.shtml
    > > > > >
    > > > >
    > > > > > ATTACHMENT part 2 image/jpeg name=crc5.JPG
    > > > >
    > > > > 
    > > >
    > > > 
    > >
    > >
    > > 
    >
    > 
    

    crc5_revised.jpg

    ReferenceAuthor
    Re: [usb] crc algorithmBo
    Re: [usb] crc algorithmKw

     
    Copyright (c) 1999 OPENCORES.ORG. All rights reserved.