4

A question popped into my head today and after a quick few searches on google, I have no idea. When a device is sent a frame there is a layer 1 header/preamble saying the length and layer 2 protocol (I think please correct me if I'm wrong), but how does the NIC know where to start reading the data from? If it starts reading from the first 1 what happens if that 1 was just noise on the line? If any clarification is needed please ask. (Also no idea what tags to put for this.)

  • Do you mean for ethernet? Different layer-1 protocols do this differently. – Ron Maupin Aug 25 '17 at 17:41
  • I didn't know they do it differently I assumed there would be different identifiers for each protocol. Seeing as ethernet is the most popular yes how would it work for ethernet? – Daniel Prinsloo Aug 25 '17 at 17:42
  • Removed the off-topic request for resources. – Ron Maupin Aug 25 '17 at 17:43
  • Thank you for the edit I was searching for the tag as 'layer 1' instead of 'layer1' – Daniel Prinsloo Aug 25 '17 at 17:46
3

Ethernet sends seven octets of preamble (10101010) to synchronize, and then a one octet SoF (Start of Frame) delimiter (10101011). The next bit is the first bit of the frame. The frame has a four octet FCS (Frame Check Sequence) that is a CRC, and if the received CRC doesn't match the calculated CRC, then the frame is dropped as damaged.

| improve this answer | |
  • 1
    So the receiver locks on to the pattern of alternating ones and zeroes and then knows that the frame starts when it sees two ones in a row. It doesn't ever have to know which bit is the first in the preamble, just in the frame data. – David Schwartz Aug 25 '17 at 17:54
  • Ah ok and that first seven octets would be unique for each protocol? – Daniel Prinsloo Aug 25 '17 at 17:56
  • No. Some protocols do something completely different. For example, some, e.g. serial protocols, will use other wires for signalling when data is present. – Ron Maupin Aug 25 '17 at 18:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.